Jump to content

Welcome to Smart Home Forum by FIBARO

Dear Guest,

 

as you can notice parts of Smart Home Forum by FIBARO is not available for you. You have to register in order to view all content and post in our community. Don't worry! Registration is a simple free process that requires minimal information for you to sign up. Become a part of of Smart Home Forum by FIBARO by creating an account.

 

As a member you can:

  •     Start new topics and reply to others
  •     Follow topics and users to get email updates
  •     Get your own profile page and make new friends
  •     Send personal messages
  •     ... and learn a lot about our system!

 

Regards,

Smart Home Forum by FIBARO Team


Search the Community

Showing results for tags 'tcp connection'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • FIBARO Community
    • FIBARO Portal and Forum policy
    • FIBARO
    • Say hello!
    • Off-topics
  • FIBARO Update
    • FIBARO System Update
    • FIBARO Mobile Update
  • FIBARO Community Support
    • Scenes and Interface
    • FIBARO Products
    • FIBARO Mobile
    • FIBARO HomeKit
    • FIBARO Assistant Integrations
    • Other Devices / Third-party devices
    • Tutorials and Guides
    • Home Automation
    • Suggestions
  • FIBARO Społeczność
    • FIBARO
    • Przywitaj się!
    • Off-topic
  • FIBARO Aktualizacja
    • FIBARO System Aktualizacja
    • FIBARO Mobile Aktualizacja
  • FIBARO Wsparcie Społeczności
    • Sceny i Interfejs
    • FIBARO Urządzenia
    • FIBARO Mobilnie
    • FIBARO HomeKit
    • Integracja z Amazon Alexa i Google Home
    • Urządzenia Firm Trzecich
    • Poradniki
    • Automatyka Domowa
    • Sugestie

Categories

  • Scenes
  • Virtual Devices
  • Quick Apps
  • Icons

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Facebook


Google+


Skype


Website URL


WhatsApp


Country


Gateway/s


Interests

Found 1 result

  1. Hi there, I am facing such a problem as I can't send anything by using TCP connection from Fibaro to my Raspberry Pi using a C language's Socket Server. For more information, I am leaving my C's Socket Server as below. I can use telnet from my computer to send string to Raspberry Pi but I can't receive any string send from the Fibaro. I am using Raspberry's gpio to send Infrared code. #include <string.h> #include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <sys/types.h> #include <sys/socket.h> #include <netinet/in.h> int main(int argc, char *argv[]){ int sockfd = 0,forClientSockfd = 0; sockfd = socket(AF_INET, SOCK_STREAM,0); int port = 8982; if(sockfd == -1) printf("Failed to Open Socket.\n"); struct sockaddr_in serverInfo, clientInfo; int addrlen = sizeof(clientInfo); bzero(&serverInfo, sizeof(serverInfo)); serverInfo.sin_family = PF_INET; serverInfo.sin_addr.s_addr = INADDR_ANY; serverInfo.sin_port = htons(port); printf("Starting Server at Port %d", port); bind(sockfd,(struct sockaddr *)&serverInfo,sizeof(serverInfo)); listen(sockfd,5); char sock_message[] = {"Hello\n"}; forClientSockfd = accept(sockfd,(struct sockaddr*) &clientInfo, &addrlen); send(forClientSockfd,sock_message,sizeof(sock_message),0); char inputBuffer[256] = {}; while(1){ recv(forClientSockfd,inputBuffer,sizeof(inputBuffer),0); printf("Get:%s\n",inputBuffer); } } The Client Server's Code in Fibaro HC2 as below, and I am using a button to send String. if not (started == 'YES') then started = 'YES' tcpSocket = Net.FTcpSocket("192.168.0.205",8982) end Thanks
×
×
  • Create New...