@AWI - looking at parallel so I can process data faster ... I can't save to pc at a rate fast enough to keep up with sampling rate.
ny51sens
@ny51sens
Best posts made by ny51sens
Latest posts made by ny51sens
-
RE: Any parallel interface accellerometers ?
-
Any parallel interface accellerometers ?
I have built a few projects using a few different 3 axis accelerometers, such as the LSM303DLHC. All of them used the i2c interface.
I'm wondering if anyone knows of a somewhat similar device that can be connected to a microcontroller via a parallel (eg: 8 bit) interface ?
-
RE: How would I read from a BMP280 sensor at the fastest possible rate ?
I've now tried various algorithms.
In all of these I set the oversampling of both temperature and pressure to 1 (no oversampling).
-
Forced mode, with fixed 5mS delay between reads,
-
Forced mode, with fixed 4mS delay between reads,
-
Forced mode, with fixed 3mS delay between reads,
-
Forced mode, with fixed 1mS delay between reads,
-
Normal mode, set t_sb = 0.5 mS, waiting until status bit 3 = 0, read data, repeat
-
Normal mode, set t_sb = 0.5 mS, waiting until status bit 3 = 0, read data, wait until status bit 3 = 1, repeat
With each algorithm, I'd do 2000 reads.
As I went through the above scenarios, the minimum and maximum readings (for both values) got farther and farter apart - ie: the range of values got larger.
That was until #5, where it was slightly better then #1. The range with #6 was the least of all - in other words, algorithm 6 gave the most consistent readings (I should say the sensor is laying still throughout these tests).
In #5, it took 6 seconds to make 2000 readings - or an ODR of about 333 hz. In #6, it took 12 seconds to make 2000 readings - or an ODR of 166 hz. Just what the datasheet said would be the maximum ODR.
I have to assume with #5, about half the readings were done before the registers were updated. In other words, it was a waste of cpu time to make the reading.
-
-
How would I read from a BMP280 sensor at the fastest possible rate ?
I am using a BMP280 module. I am very confident my system setup and software are working fine. Readings of temperature and pressure I receive seem valid.
I wish to implement a design, based around an 8051 microcontroller, where the pressure reading is continually read from the device and sent out a serial port onto my PC where it is date stamped and saved to a log file.
I want to run this as fast as possible. I do not wish to use the IIR filer, as I actually want to see any spikes that might appear.
I'd be just reading the 3 or 6 bytes (either just pressure or pressure and temperature) and transmitting the raw values to my PC (converting later on). I've had my circuit reading 11 bytes from a different I2C sensor, and transmitting those values, at 800 hz without problems. So I know I can handle the fastest ODR the device claims to achieve.
I understand I can either run in "forced mode" or "normal mode".
It is not exactly clear to me which to use.
Also, regardless of the mode I use, how would I know when to read from the device ?
If I run in forced mode, can I simply write my code to run a tight loop of just reading from the device, transmitting the data to my PC, over and over ??? It would seem I would be trying to read at a rate that is much faster then the device can actually handle. Is there a problem with that ... as in ... would I risk reading invalid data ?
If I run in normal mode, there is some sort of standby time. Would I need to determine that time, and write my code to wait AT LEAST that amount of time before seeking another reading ?
Your help would be greatly appreciated.
-
Getting the HC-SR501 to function first time
I have a few HC-SR501 sensors and have not seen any of them function. I connect 5v and gnd to the 3 pin connector, and monitor the output via multiple means. I point the sensor in various directions, and never see it change. I vary the pots, the jumper. Nothing changes.
Please trust I have not been sitting at a bench with the sensor pointing at me all the time I am not using any other circuit at this point, just 5 Vdc, logic probe, scope, etc.
Can someone suggest how to initially set up the HC-SR501 ?