Navigation

    Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Search
    • Unsolved
    1. Home
    2. Tags
    3. tcpsocket
    Log in to post

    • SOLVED Working TCP client not connecting after upgrading to Qt creator 4.14.0 (based on Qt 5.15.2)
      General and Desktop • tcpsocket qt creator 4.14 • • Aditya Gour  

      4
      0
      Votes
      4
      Posts
      240
      Views

      @Aditya-Gour said in Working TCP client not connecting after upgrading to Qt creator 4.14.0 (based on Qt 5.15.2): before reading this reply i debugged using : Where did you put these lines? "My updated code I am attaching for reference" - what is updated there? Please connect a slot to https://doc.qt.io/qt-5/qabstractsocket.html#errorOccurred before calling connectToHost and print https://doc.qt.io/qt-5/qiodevice.html#errorString there.
    • UNSOLVED QTcpSocket : readRead() not being triggered when data is written on the socket
      General and Desktop • qtcpsocket qtcpserver tcp tcpsocket tcp server • • RBLL  

      11
      0
      Votes
      11
      Posts
      994
      Views

      The edited part of @JonB is important, you have to read the data.
    • SOLVED QTcpServer with wifi dongle
      General and Desktop • bluetooth socket tcpsocket tcpserver wifi • • LordMat  

      5
      0
      Votes
      5
      Posts
      173
      Views

      @jsulm Thanks a lot
    • SOLVED Optimize the reading of a client
      General and Desktop • tcpsocket • • Dooham  

      12
      0
      Votes
      12
      Posts
      505
      Views

      @Dooham OK, I just about understand :)
    • UNSOLVED Qt gui C++ to read other controllers memory location through ethernet tcp/ip address
      Mobile and Embedded • interface tcpsocket data transfer • • Prasad320  

      7
      0
      Votes
      7
      Posts
      2290
      Views

      @Belkacem said in Qt gui C++ to read other controllers memory location through ethernet tcp/ip address: Can you give more information on how to establish a communication between the PC and the PLC. Hi, and welcome! First, you must tell us what communication protocols are supported by your PLC.
    • SOLVED QObect::connect call does not compile
      General and Desktop • qobject connect socket tcpsocket • • CynaCons  

      5
      0
      Votes
      5
      Posts
      3742
      Views

      Adding the QObject constructor to my class's constructor and adding the pointer-to-member syntax suggested by Kshegunov fixed the issue. Thanks guys and good day.
    • UNSOLVED Database table transfer over TCP
      General and Desktop • database tcpsocket qt 5.7.0 data transfer • • DoughBoy  

      21
      0
      Votes
      21
      Posts
      7270
      Views

      @DoughBoy The following SQL, with the Chinook test database open will create a new file in the same directory named 'out.sqlite' holding all of the album information for artist 51 with the original table layout. A Qt model is totally unnecessary. Just run the query and it will create your file. From there you can compress it and ship it. ATTACH DATABASE 'out.sqlite' AS outdb; CREATE TABLE outdb.album AS SELECT * from album WHERE ArtistId = 51; DETACH DATABASE outdb; It does use SQLite specific sql. Note especially that the ATTACH DATABASE and DETACH DATABASE are sql to be sent to the database just like the CREATE TABLE.. BTW, I have never done this using Qt, only in batch files, but I see no reason for it not to work both ways. Mike
    • UNSOLVED 2-way network communication between 2 Qt programs
      General and Desktop • c++ qtnetwork networking tcpsocket tcpserver • • htmlboss  

      2
      0
      Votes
      2
      Posts
      901
      Views

      @htmlboss Hi, let's call them "node" and "controller" Let's not do that. Let's call them a server and a client - it's much better and easier to follow the accepted terminology. A server will serve the requests presented by the clients (see the analogy with a busy restaurant?). There can only be one "controller", but the number of "nodes" may vary (eg. different clients). So you have one server and a few clients. So far so good. I want to have the "controller" initiate the connection to each client such that arbitrary data is sent back and forth as it is ready (readyRead() signal? ). How data flows between the client and the server is completely independent of who initiated the connection. You can still have the server sending data to the clients (what http servers mostly do), and still the client initiates the connection (i.e. your browser). I have implemented the Fortune Client/Server example with the "controller" as the Client (since it would initially ask for a connection), and the Fortune Server as a test (eventually it would be a "node" sending data). This is where I'm stuck. Ignoring less-than-critical performance issues, how would I modify the Fortune example (or perhaps roll my own) to allow the Server to accept data from the "controller" without the use of any buttons/etc, but to get it as it is "ready"? Ideally, this needs to scale up to a max of 15 "nodes". Just write from the appropriate side (application). The server should stay the server, and the client should stay a client, don't switch their roles. Kind regards.
    • UNSOLVED Tcp/Ip client-server communication in qt c++
      General and Desktop • tcp tcpsocket tcp server • • karthik23  

      6
      0
      Votes
      6
      Posts
      3638
      Views

      @karthik23 said: where should i insert this code exactly? where you need it :) I mean u asked the question because you want to achieve something. Since it's still not very clear what you want as the final result, i can't help you. For testing you can add it in the line where your qDebug() calls is.
    • SOLVED C++ Multi-Client TCP Server with QList
      General and Desktop • signal & slot qlist tcp tcpsocket tcp server • • Hannes T  

      3
      0
      Votes
      3
      Posts
      2356
      Views

      @mrjj Thank you a lot, it works!!!
    • UNSOLVED Tcpsocket newbie
      General and Desktop • tcp tcpsocket tcpserver • • dflass  

      7
      0
      Votes
      7
      Posts
      2438
      Views

      @dflass Does the if else statement not prevent a the null pointer? Well, not really, no. QTcpServer::listen doesn't block, its return value just indicates whether or not your request to listen to a port was successful. This doesn't at all guarantee that you have pending connections for that server socket. As @koahnig pointed out, you should use signals and slots to connect to the interesting events generated by your server socket and handle them appropriately. Do follow his suggestion, and look at the server/client examples, which will give you a good overview on how to setup a TCP server/client application properly. Kind regards.
    • Wysyłanie maila za pomocą Qt, raportowanie stanu aplikacji
      Polish • qsslsocket tcpsocket smtp email mail gmail problem do rozw imtp • • Huragan  

      2
      0
      Votes
      2
      Posts
      1318
      Views

      @Huragan Witam. Widzę, że nie ma zbytniego zainteresowania tym postem, ale jakoś sobie radzę. :) Doszedłem do etapu w którym mailowy serwer google (gmail) odmawia mi połączenia się ze sobą z powodu niskiego poziomu bezpieczeństwa zapewnianego przez moją aplikację. Rozwiązanie tego problemu przyszło łatwo. Zezwoliłem na łączenie się z moją skrzynką mailową mniej bezpiecznym aplikacjom. [https://support.google.com/accounts/answer/6010255]