Dear all,
This is the summary of replies to our question concerning Flock of Bird
sampling rate and duplicate data.
We would like to thank all those who took the time to help us. We received
very useful information.
Thanks again,
Veronique and Patrick
_________________________________
Laboratory for Functional Anatomy
ULB (CP 619)
808, route de Lennik
B-1070 Brussels, Belgium
Tel: ++ 32 2 555 63 29
Fax: ++ 32 2 555 63 78
Email: vfeipel@ulb.ac.be
salviap@ulb.ac.be
_________________________________
Joshua Swamidas (joshua@tera.engr.mun.ca) told us that this problem is just
a limitation of the hardware. The sampling rate depends on the number of
receivers, the type of data sampled, the baud rate (RS232 is slower than RS485.
---------------------------------------------
David L. Churchill (churchil@salus.med.uvm.edu) insisted upon the fact that
if the baud rate of the communication link (Bird-computer) is not high
enough, duplicate data can be sampled. So the baud rate has to be adjusted
on the FOB and in the software. Different data types (more or less
characters) change the adjustments to be made. David also confirmed our
finding that the technical support staff at Ascension is very useful.
---------------------------------------------
Ian Kremenic (ian@nismat.org) wrote that the data transmission rate is
faster than the FOB sampling rate, which results in duplicate data. Ian
thinks that this problem can only be solved by writing one's own software to
eliminate the duplicates from the data set. He also insisted upon the
importance of checking data for distortions if the distance between
receivers and transmitter varies too much during sampling.
---------------------------------------------
Lee E. Johnson (innsport@mcs.net) and Steve Works from Ascension
(techsupport@vtweb.com) suggested that our problem could be related to the
use of continuous point requests, not STREAM.
---------------------------------------------
Mark Evans (mjevans@umich.edu) encountered the same problem than we did.
Duplicate data are sampled because the computer is receiving data more
frequently than new data is being collected. Mark solved the problem by
making the software wait to receive the "data ready character" from the
serial port before collecting data, using the construction "
while(wait_for_char not equal to '0x2c'), return " at the beginning of the
data collection loop. This enabled him to collect a data set after the
'0x2c' character (hex for a comma, default data ready character) was received.
----------------------------------------------------
Wolfgang Birkfellner (wbirk@mamba.bmtp.akh-wien.ac.at) also uses one RS232
for communication with the bird. He did not use de Cbird programm, as it was
too difficult to adapt to his needs. Many of those "press akey when
ready..." messages can't be deleted due to runtime problems (the
microprocessor in the bird is not that fast). With his own program, he can
poll data from the bird, and the result seems to be reasonable. Wolfgang
uses an Internet library ("Async Tools") for serial communcation. He works
in group data mode and sends a point (ASCII 'B') command with a time
interval of 7 ms and checks the size of the buffer of the serial port.
Wolfgang thinks that the stream mode option "stinks" (sic). According to
Wolfgang, it would have been interesting if Ascension had set up a library
(an API...) instead of the Cbird program. Concerning the comminication card
choice, Wolfgang says that the best should be the ISA-card, but that it
works also with RS232. Multiple serial ports means duplicating the problems
that appear with fast data aquisition over one serial port. Wolfgang sent us
a portion of his code, that we will try to use.
----------------------------------------------------
With the Ascension Tech-support group (Steve Works and Joseph Durfee,
techsupport@ascension-tech.com) we had numerous contacts and received
several interesting answers. One of the important factors was that the
configuration with Multiple RS232 communicate can not be done with the cbird
code presently available, unless multiple copys are run at the same time.
You need a program that does the following:
1. Opens comport to Master (ERC)
2. Asks the Master what units are in the Flock (use Examine Value, Flock
System Status)
3. Configure all units to RUN (Use the change Value, FBB Autoconfig command
to Master.)
4. Specify Measurement Rate for system (send change value, measurement rate
command to master.)
5. For each receiver, Open a comport to that electronics unit.
6. For each receiver send format command (example, POS/ANGLES) send other
commands such as Hemisphere, see user manual.
7. data can be taken from the electronic units now in a number of ways. Some
may be set to Stream Mode, and some used with Point command. Communicate
directly to the electronic unit by it's comport.
According to Steve and Joseph, CBIRD does not support the Data Ready char.,
which is a limitation of CBIRD. Best to use stream if you follow the above,
although data ready character works fine - just not with cbird.
This is the summary of replies to our question concerning Flock of Bird
sampling rate and duplicate data.
We would like to thank all those who took the time to help us. We received
very useful information.
Thanks again,
Veronique and Patrick
_________________________________
Laboratory for Functional Anatomy
ULB (CP 619)
808, route de Lennik
B-1070 Brussels, Belgium
Tel: ++ 32 2 555 63 29
Fax: ++ 32 2 555 63 78
Email: vfeipel@ulb.ac.be
salviap@ulb.ac.be
_________________________________
Joshua Swamidas (joshua@tera.engr.mun.ca) told us that this problem is just
a limitation of the hardware. The sampling rate depends on the number of
receivers, the type of data sampled, the baud rate (RS232 is slower than RS485.
---------------------------------------------
David L. Churchill (churchil@salus.med.uvm.edu) insisted upon the fact that
if the baud rate of the communication link (Bird-computer) is not high
enough, duplicate data can be sampled. So the baud rate has to be adjusted
on the FOB and in the software. Different data types (more or less
characters) change the adjustments to be made. David also confirmed our
finding that the technical support staff at Ascension is very useful.
---------------------------------------------
Ian Kremenic (ian@nismat.org) wrote that the data transmission rate is
faster than the FOB sampling rate, which results in duplicate data. Ian
thinks that this problem can only be solved by writing one's own software to
eliminate the duplicates from the data set. He also insisted upon the
importance of checking data for distortions if the distance between
receivers and transmitter varies too much during sampling.
---------------------------------------------
Lee E. Johnson (innsport@mcs.net) and Steve Works from Ascension
(techsupport@vtweb.com) suggested that our problem could be related to the
use of continuous point requests, not STREAM.
---------------------------------------------
Mark Evans (mjevans@umich.edu) encountered the same problem than we did.
Duplicate data are sampled because the computer is receiving data more
frequently than new data is being collected. Mark solved the problem by
making the software wait to receive the "data ready character" from the
serial port before collecting data, using the construction "
while(wait_for_char not equal to '0x2c'), return " at the beginning of the
data collection loop. This enabled him to collect a data set after the
'0x2c' character (hex for a comma, default data ready character) was received.
----------------------------------------------------
Wolfgang Birkfellner (wbirk@mamba.bmtp.akh-wien.ac.at) also uses one RS232
for communication with the bird. He did not use de Cbird programm, as it was
too difficult to adapt to his needs. Many of those "press akey when
ready..." messages can't be deleted due to runtime problems (the
microprocessor in the bird is not that fast). With his own program, he can
poll data from the bird, and the result seems to be reasonable. Wolfgang
uses an Internet library ("Async Tools") for serial communcation. He works
in group data mode and sends a point (ASCII 'B') command with a time
interval of 7 ms and checks the size of the buffer of the serial port.
Wolfgang thinks that the stream mode option "stinks" (sic). According to
Wolfgang, it would have been interesting if Ascension had set up a library
(an API...) instead of the Cbird program. Concerning the comminication card
choice, Wolfgang says that the best should be the ISA-card, but that it
works also with RS232. Multiple serial ports means duplicating the problems
that appear with fast data aquisition over one serial port. Wolfgang sent us
a portion of his code, that we will try to use.
----------------------------------------------------
With the Ascension Tech-support group (Steve Works and Joseph Durfee,
techsupport@ascension-tech.com) we had numerous contacts and received
several interesting answers. One of the important factors was that the
configuration with Multiple RS232 communicate can not be done with the cbird
code presently available, unless multiple copys are run at the same time.
You need a program that does the following:
1. Opens comport to Master (ERC)
2. Asks the Master what units are in the Flock (use Examine Value, Flock
System Status)
3. Configure all units to RUN (Use the change Value, FBB Autoconfig command
to Master.)
4. Specify Measurement Rate for system (send change value, measurement rate
command to master.)
5. For each receiver, Open a comport to that electronics unit.
6. For each receiver send format command (example, POS/ANGLES) send other
commands such as Hemisphere, see user manual.
7. data can be taken from the electronic units now in a number of ways. Some
may be set to Stream Mode, and some used with Point command. Communicate
directly to the electronic unit by it's comport.
According to Steve and Joseph, CBIRD does not support the Data Ready char.,
which is a limitation of CBIRD. Best to use stream if you follow the above,
although data ready character works fine - just not with cbird.