Jump to content

Cannot get responses to TCP/IP requests


Recommended Posts

Posted

Hi all,

 

For reasons I won't go into just now, I need to use the TCP/IP API for my TinkerForge project. I'm using Java as my programming language to create and send the UDP packets to the Master Brick. The Brick/Bricklets are all live and can be viewed in the TF viewer. I have checked to make sure that the Master Brick can be pinged (it can), and that my byte sequences (for the UID) are correctly orderred (little-Endian). I'm only sending the simplest of 8-byte commands (without payload), i.e. asking the Master Brick for its Ethernet status, or asking a Temperature bricklet for its current temperature, but I'm just not getting any responses at all on the socket receive() call.

 

Can anyone suggest what else I can try, or some other way of debugging or making progress ? Please ?

 

Thanks !

 

Posted

You wrote

send the UDP packets to the Master Brick
, but you mean: you send TCP/IP packets to the brickd service or directly to a master with an ethernet extension?

 

You'll need a TCP socket, not an UPD socket.

 

You followed this instruction: http://www.tinkerforge.com/de/doc/Low_Level_Protocols/TCPIP.html#llproto-tcpip?

You should dump your data packet in your code first, then you can compare which bytes sequence you're sending.

Posted

My fault, and I apologise! I get involved in developing drivers for many different projects and I get so used to assuming UDP that I didn't read properly and just went ahead in creating a DatagramSocket.

 

Everything working now - great product!

 

Thanks

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...