I am now at the point of connecting my accelerometer tilt sensor to a display wirelessly. My two most recent blog entries describe both elements of the project. Here is a link to the display blog (https://www.electro-tech-online.com...aracter-display-16f1519-nhd12864mz-mpasm.html).
I have a couple of XBee modules that will be used, at least initially (AT mode). Coding is in MPASM.
The accelerometer produces a square wave, the duty cycle of which correlates to tilt. I am measuring duty cycle by collecting high counts and total counts using the 16-bit TMR1 module of a 12F683.
My question is whether common practices would have me send the raw data (i.e., 4 bytes of data for each axis) and do all calculations in the display unit or pre-process in the 12F683 and send results (e.g., tilts) as ASCII character data to the display unit.
Data rate is fairly slow (100 Hz), the graphical display is not very complex, and I don't see the need for co-processing. Sending raw data could be faster (will probably use 9600 baud).
The concern I have with sending raw data is that an undetected error in transmission might be less likely to give an unreasonable result for display than if the error occurred in transmitting the calculated results in ASCII. Are modern links, like XBee, good enough that such errors are not really a concern. Is my assumption about error detection valid?
Any other comments or guidance on this question?
Regards,
John
I have a couple of XBee modules that will be used, at least initially (AT mode). Coding is in MPASM.
The accelerometer produces a square wave, the duty cycle of which correlates to tilt. I am measuring duty cycle by collecting high counts and total counts using the 16-bit TMR1 module of a 12F683.
My question is whether common practices would have me send the raw data (i.e., 4 bytes of data for each axis) and do all calculations in the display unit or pre-process in the 12F683 and send results (e.g., tilts) as ASCII character data to the display unit.
Data rate is fairly slow (100 Hz), the graphical display is not very complex, and I don't see the need for co-processing. Sending raw data could be faster (will probably use 9600 baud).
The concern I have with sending raw data is that an undetected error in transmission might be less likely to give an unreasonable result for display than if the error occurred in transmitting the calculated results in ASCII. Are modern links, like XBee, good enough that such errors are not really a concern. Is my assumption about error detection valid?
Any other comments or guidance on this question?
Regards,
John