Command '1' executed randomly (other number command probably as well)

3 views
Skip to first unread message

Marcin_GUmeR

unread,
May 19, 2011, 6:42:14 PM5/19/11
to ArduPirates
Hi all

I have a bug report here:

In file GCS.pde in functions readSerialCommand() and
sendSerialTelemetry we have different cases for receive/send messages,
like 'A', 'B', 'C', 'U', '1', '2' etc. Sometimes when I send lot's of
messages quickly I can see command '1' (update channel slopes and
offsets) is executed with no reason. The result is slopes and offsets
are updated with ridiculous values (between 0-2000). Obviously if that
would happen before or mid flight it would immediately crash the
vehicle.

My theory is that previous message was not read completely and the
next message starts from the middle of old one. Example: send
"M1234;1234;1234;1234;1", but enter readSerialCommand when read buffer
contains only second half "1234;1234;1". What will happen, we will
execute command '1' with parameter "234;1234;1", which is very bad.

I will fix this when I get access to the repository.

Also: what is the status on the protocol? Do you want to implement
Mavlink at some point?

Marcin
Reply all
Reply to author
Forward
0 new messages