Documente Academic
Documente Profesional
Documente Cultură
Lab 2 Assignment
Christopher Assi
The goal of this lab assignment was to make acquainted with the use
of TinyOS 2.x in a Linux Environment. A toolbox of software templates
was built for the remaining of the lab activities.
For the Output application, first the template application from the lab 1
assignment had to be copied. Instead of just sensing, the mote had to
interact with the environment with an output command.
Component: OutputAppC
a) MicaZ
For the MicaZ platform, every time the Counter equals “000”, a digital
output port is set to HIGH; otherwise, it is set to LOW.
The MDA100 sensor board was used for the MicaZ for the tests.
b) TelosB
For the TelosB platform, every time the Counter equals “000”, a digital
output port is set to HIGH; otherwise, it is set to LOW.
TelosB directly was connected to the U2 connector.
The pin D6 (CCA) was used. The low voltage was around 1mV and the
high was only
at 1.8V. (The low fluctuated when the LEDs changed too). The pin
D6(CCA) was set
as output before setting it.
Below was the result recorded after the command was properly
executed.
Figure1: Screenshot showing when the port output is set to HIGH and LOW
For the Flash application, first the template application from the
previous problem had to be copied. A counter called CountFlash was
incremented every 5 seconds and its value was stored in the Flash
memory.
Component: FlashAppC
1. Tutorial.
Need xml file to indicate what we are calling each part of memory:
MicaZ: volumes-at45db.xml
TelosB: volumes-stm25p.xml
The micaz was completed with much complexity. The problems faced
were understood.
2. TelosB
The XML file was copied, but still had some other problems. The
tutorial code for both TelosB and MicaZ were being compile without
problems.
On the other hand, my code had some errors. The difference was the
use of the PrintF. Beside that file, the *AppC.nc files are identical.
Moreover the blocks need to be of size
multiple of 2^16 and cannot monitor the serial while you program the
TelosB.
It also takes longer to write to the TELOSB memory.
1. CountTX
CountTX realized the counting with the variable Counter (0 to 7). The
values of the Counter were sent to the LEDs of Node B, in addition to
the local LEDs.
a) Tutorial
b) TelosB:
Test TX with TelosB and put down RX with MicaZ to see if they still
communicate.
2. CountRX
CountRX did not have its own counter or any timer. It allowed the Node
B to receive the counting value from the Node A and displayed it in
the local LEDs.
a) Tutorial
V. Conclusion
The lab experiment gave an overview on the use of an output port, the
use of Flash memory, and the use of the radio communication stack.
On the output, the application had to interact with the environment
with an output command. The MDA100 sensor board was used for the
MicaZ for the tests and theTelosB directly was connected to the U2
connector. On the Flash memory application, A counter called
CountFlash was incremented every 5 seconds and its value was stored
in the Flash memory. The blocks needed to be of size multiple of 2^16
and could not monitor the serial while you program the TelosB. It also
took longer to write to the TelosB memory. On the CountToRadio
application, a CountTX and a CountRX directory had to be created.
BlinkToRadio had to be executed before proceeding with PrintF,
otherwise it would not compile.