
Department of Computer Science and Electronics
31
As mentioned before, the microcontroller being used is not fully exploited, and
taking into consideration the cost increment between the previous circuit and this one, it
would be a lucrative idea to take more advantage of it, using it in order to perform other
kind of tasks - in this case the interrupts would be useful in order not to miss ‘real time’
response.
In a first draft of the code, the MPCM (Multiprocessor communication mode)
by Atmega16 was used, which involves a 9
th
bits data frame. Finally it was removed
because a microcontroller refers just to the PPC and not to other microcontrollers
whereas it would be better if all devices in a network could communicate to each other.
Finally, comment that issues as errors and noise have not been investigated.
Therefore, this can be an improvement in a future work as well.
6. Summary and conclusions
An electronic circuit is designed to be implemented in a soccer playing robot.
The main objective of this work is to make the robot know whether or not it is
above a white line in the soccer field. In the bottom platform of the robot, there are 3
identical boards which have 8 infrared sensors and an Atmega16 microcontroller each.
When the sensors are above a white line, they send a signal because the infrared signal
will be reflected. On the other hand, weaker signals will be received when the sensors
are on a green colour field. The knowledge of those sensors’ values or states will help
the robot to specify where it is located.
As the cards have to send the sensors’ states digitally to the Power PC while they
are read in an analogue way, it is necessary to calculate each sensor’s threshold which
varies according to the field the robot is playing on.
Each board will have its own address. The PPC will be sending orders to the
network. Not only will the frame contain the address of the microcontroller which the
order is for, but also the task that the Atmega16 has to perform; calculate the sensors’
threshold or send data to the PPC.
The threshold calculation will take about two minutes; therefore the robot must
be running around the field and taking samples from the sensors.
The information is sent to the PPC using the USART serial communication, with
a start bit, 8 data, non-parity and one stop bit. The transmission is 9600 bps and the
microcontrollers’ connexion to the RS-485 network is been using a MAX489
transceiver.
All in all, this report explains how this work has been developed. The schematic
is generated using Eagle software. Then the programme to be implemented in the
microcontrollers is written in C language using the Win AVR compiler. The simulation
part and the tests have been executed using AVR Studio, STK500 and Hyper Terminal.
Komentáře k této Příručce