Swarm Robots: my progress (Architecture of Software)

3 views
Skip to first unread message

Leo Yan

unread,
Aug 29, 2012, 2:08:23 AM8/29/12
to xinch...@googlegroups.com

My progress:

  1. made a robot prototype based on Arduino UNO board.

  2. designed the architecture of software.

  3. Coding the class of Sensor.


Architecture of Software:

  1. Four kind of object: Sensor, Motor, Messager, Action.

  2. Two thread: 'main process' and 'timer interrupt process'

Attachments in detail:

  • Class diagram:
  • Data of Class:
  • Interaction diagram:


Message format for communicating:

baud rate: 2k bit/s( it depends on: 1.the min signal pulse width, here I take 500us. Constraint: must be less than the half of 38k.)

start bit: 3 bits of 0 (using the low output of IR-receiver as the 0 bit)

data:

typedef struct{

uint8_t ReceiverID; // send from LSB

uint8_t SenderID;

uint8_t MessageID;

uint8_t Para;

uint8_t VerifyFirst; // Verify bytes, the value should be equal to the value of ReceiverID

uint8_t VerifyLast; // Verify bytes, the value should be equal to the value of the l Para

}TxRxBuf_stru;

verification: using repeating data as above.

Stop bit: null.

Message transfer rate: 2K bits/51 bits=39, 39 messages per second.

collision detecting: thinking:)

Problem:

1. about emitting infrared of prototype robot : when change signal from 0 to 1 on the 38k PWM, there is a very strong infrared at the start of changing that can enable all four IR-receivers. I'll go to Xinchejian and to solve the problem tonight.

Class.png
Data.png
Interaction.png

hao jiang

unread,
Aug 29, 2012, 3:09:45 AM8/29/12
to xinch...@googlegroups.com
This is too professional!

Great job leo!

spanner888

unread,
Aug 29, 2012, 3:15:40 AM8/29/12
to xinch...@googlegroups.com
Hi Leo

your work is really interesting and you are progressing fast!

About the "very strong infrared at the start" - my first thought is that this might actually be the other way around - the signal starts with a normal (higher) strength, then the strength fades rapidly - most likely due to power supply drain (or droop) due to the relatively high peak current.

Things to try are a local capacitor to supply current over a longer period, or reducing the output - eg series resistor (although this may depend on your driver circuit).

One of the links I sent you a few days back also discusses constant current driver to help control the output.
Reply all
Reply to author
Forward
0 new messages