Moderator: RevPiModIO

 
mdr
Topic Author
Posts: 2
Joined: 21 Apr 2021, 10:30

AIO module scale

21 Apr 2021, 11:36

Hello,

I have a question regarding the scale of data received from AIO module using RevPiModIO2. I have a sensor connected to the AIO module but no way to test the full scale of the sensor(no physical access to the sensor and the pi).
In pictory Input 1 is set as follow:
-Range: -10V/+10V
- Multiplier:1
-Divisor:1
-Offset:0
-ADC_DataRate:640Hz
And in python I am reading the value using rpi.io.InputValue_1() in cycleloop(100ms).
How the rpi.io.InputValue_1() is scaled exactly (8 bit,16bit,24bit) it really not clear for me? from what i understand, Its a 24bits ADC so it should give me the following result;
-10V->0
0V->2^23(8388608)
10V->2^24(16777216)
but that doesn't match with the data that I have...
Could somebody help me,please ,to better understand ?

Best regards,
Martin
 
User avatar
RevPiModIO
Posts: 249
Joined: 20 Jan 2017, 08:44
Contact:

Re: AIO module scale

26 Apr 2021, 08:05

Hi Martin!

The AIO module will process the data internally and gives us the "real" value. So if you configure the Input for -10 to 10 V you will get the value in mV directly from the AIO module. So the range is -10000 - 10000.

So in the piControl bus is already a processed value from the AIO module and all programs (piTest, RevPiModIO and so on) will show the real, processed value.

Regards
Sven
python3-RevPiModIO - https://revpimodio.org/ || Der RevPi ist das Beste, was passieren konnte!
 
mdr
Topic Author
Posts: 2
Joined: 21 Apr 2021, 10:30

Re: AIO module scale

26 Apr 2021, 08:54

Thank you very much for your answer! It's a shame that I figured out the answer just before you reply! That is what happens when you don't read properly the manual...:
The initial values always lie in the unit mV or µA respectively.
Best Regards
Martin

Who is online

Users browsing this forum: No registered users and 2 guests