0
Beantwoord

EVENT_RECEIVE_TEXT INFO MISSING

Ander Gabilondo 8 jaar geleden in Products / AV & Custom Systems bijgewerkt door Ekaterina (head of support) 8 jaar geleden 4

Helo,

I’m having some problem with a new Driver. I have to control a device with Telnet. I lose some information when I send a command to the device and thee devices answers to this command. Instead, if I send this command with Putty, I see the information I need. As you can see, the last line is lost, and I need it for the feedback information.


With the Iridium Log I get the following messages:

[02-02-2017 13:23:19.651] INFO SCRIPT text =

[02-02-2017 13:23:19.699] INFO SCRIPT text = Preset 1 2 // Received from the bus (Line 1)

OK // Received from the bus (Line 2)

// ------------- MISSING INFORMATION (Line 3)

But with the Putty in Telnet I get the following:

p 1 2 // Received from the bus (Line 1)

OK // Received from the bus (Line 2)

Preset 1, Area 2, Fade 2000, Join 0xff // Received from the bus (Line 3)


Thanks for your support.

+1

thats tcp/ip, a message came within one, two or more packets. you have to sum the messages up in a string-variable in the EVENT_RECEIVE_TEXT function. than you have to look at a EOM (end of message) byte or text.

than you have to strip the part of the string-variable that you decoded, because maybe you have also another messages appended to the first one, etc...


iridium doesn't know when the message from a tcp/ip device is "done", so most of the times it works with one packet and one message, but i have for example a heating control here that sends out a xml-message that comes within 10 packets.

Helo Martin,


Thanks for your reply. The problem was a NUL character in the middle of the string that RECEIVE_TEXT is unable to convert.

you can use receive_data...

Yes,I did it with receive_data and is working now. Thanks