Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. IOT sending data to remote server
Forum Updated to NodeBB v4.3 + New Features

IOT sending data to remote server

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
5 Posts 2 Posters 490 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • V Offline
    V Offline
    viju45
    wrote on 4 Dec 2019, 10:14 last edited by
    #1

    hi everyone

    i am new to IOT ..i want to send data to remote server using Raspberry pi and Qt...pls seggest me how to do it ....
    i am able to send data to local host using Qtcpsoket and Qtcpserver ......

    thanks in advance

    J 1 Reply Last reply 4 Dec 2019, 12:40
    0
    • V viju45
      4 Dec 2019, 10:14

      hi everyone

      i am new to IOT ..i want to send data to remote server using Raspberry pi and Qt...pls seggest me how to do it ....
      i am able to send data to local host using Qtcpsoket and Qtcpserver ......

      thanks in advance

      J Offline
      J Offline
      jsulm
      Lifetime Qt Champion
      wrote on 4 Dec 2019, 12:40 last edited by
      #2

      @viju45 If you're able to send to local host then you should be able to send to other hosts.
      What exactly is the problem?

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      3
      • V Offline
        V Offline
        viju45
        wrote on 5 Dec 2019, 04:36 last edited by
        #3

        @jsulm actually today i understood that my respbeery pi was server and the other computer was client ....i tested the code with Putty at receiver side .....and i an new to IOT concept ....i am not able to understand how to send it to server now.

        server = new QTcpServer(this);
        socket = new QTcpSocket(this);

         connect(server, SIGNAL(newConnection()), this, SLOT(newConnection()));
        
         if(!server->listen(QHostAddress::AnyIPv4, 1234))
            ui->lineEdit_2->setText("ERROR");
        

        this is how i am use to setup connection

        now i want to establish connection with remote server.

        J 1 Reply Last reply 5 Dec 2019, 06:12
        0
        • V viju45
          5 Dec 2019, 04:36

          @jsulm actually today i understood that my respbeery pi was server and the other computer was client ....i tested the code with Putty at receiver side .....and i an new to IOT concept ....i am not able to understand how to send it to server now.

          server = new QTcpServer(this);
          socket = new QTcpSocket(this);

           connect(server, SIGNAL(newConnection()), this, SLOT(newConnection()));
          
           if(!server->listen(QHostAddress::AnyIPv4, 1234))
              ui->lineEdit_2->setText("ERROR");
          

          this is how i am use to setup connection

          now i want to establish connection with remote server.

          J Offline
          J Offline
          jsulm
          Lifetime Qt Champion
          wrote on 5 Dec 2019, 06:12 last edited by
          #4

          @viju45 Please read documentation https://doc.qt.io/qt-5/qtcpsocket.html
          And take a look at examples: https://doc.qt.io/qt-5/qtnetwork-fortuneclient-example.html

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          2
          • V Offline
            V Offline
            viju45
            wrote on 5 Dec 2019, 07:28 last edited by
            #5

            @jsulm thanks for replay ...

            1 Reply Last reply
            0

            1/5

            4 Dec 2019, 10:14

            • Login

            • Login or register to search.
            1 out of 5
            • First post
              1/5
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved