Home/Support/Support Forum/Minimal data length to send over the serial port
Welcome to Digi Forum, where you can ask questions and receive answers from other members of the community.

Minimal data length to send over the serial port

0 votes
Hello,

I have datas to send over the serial port. These datas have several length, and sometime the data length is quite short (9 bytes).
It seems that the digiconnect ME sends these datas but add other datas (the datas of the last communication, when the length is more long), and finally instead of a 9 datas length packet, I have a 18 datas length packet (without the IP header which I don't care).

Is it a minimal in the length of the datas when I use the UDP or TCP serial port ?

Thank for your support.

Thomas
asked Jun 18, 2007 in NET+OS by Thomas_Bernard New to the Community (9 points)
recategorized Dec 18, 2013 by tuxembb

Please log in or register to answer this question.

7 Answers

0 votes
Are you using the -S or -C modules? Are you using the plug and play firmware or NET+OS? Which version?
answered Jun 18, 2007 by charliek Veteran of the Digi Community (408 points)
0 votes
I am using standard (-S) modules with digiconnect's firmware

Firmware : 2.4.5 (Version 82001116_H 10/18/2006)
POST : 1.1.3 (release_82000867_G)

In fact the problem appears only when the serial port sends data by UDP protocol. I think that this problem of data minimal length include the TCP or UDP header, and as the UDP header is shorter than the TCP one, the problem appears only with UDP.
answered Jun 19, 2007 by Thomas_Bernard New to the Community (9 points)
0 votes
You can control this with the UDP send settings on the Serial Settings page (Web UI -> Serial Port 1). The same goes for TCP.
answered Jun 19, 2007 by charliek Veteran of the Digi Community (408 points)
0 votes
Yes I know, and my parameters are :

Send after following number of idle milliseconds : 2 ms
Send after the following number of bytes : 1024 bytes

But if I send 9 bytes on the serial port and I wait 2 ms, the Standard ConnectME send it with 18 bytes in the data field of the IP message, and if the 9 first bytes are by bytes, the other are random or sometimes previous datas.
answered Jun 20, 2007 by Thomas_Bernard New to the Community (9 points)
0 votes
Keep in mind that the conditions you've specified mean that whichever is hit first will trigger sending data up. I.E. if there's less than two milliseconds or delay between when the last byte was recieved (after the last bitgap timeout) to when the next byte was recieved, data will continue to be buffered. If you send 9 bytes of data to the serial interface, wait 5 ms, send 9 bytes of data to the serial interface, (repeating), you should see 9 bytes show up every time for UDP (or not show up at all).
answered Jun 20, 2007 by charliek Veteran of the Digi Community (408 points)
0 votes
I have understand that, and if I send 9 bytes on the serial port and I wait 5 ms, I have always 18 bytes in the data field of the IP message !
answered Jun 21, 2007 by Thomas_Bernard New to the Community (9 points)
0 votes
Please attach your config and let me take a look at it.
answered Jun 21, 2007 by charliek Veteran of the Digi Community (408 points)
...