Hello,
I've just bought T7 with a Mux80, and trying read 24 AIN (12 differential) channels and log to data file at maximum sample rate, resolution would be fine 0. So question would be what is maxim sample rate could be per channel ? Is it 100k/24=~4.1k?
I'm very big noob at programming, but I'm trying to write script in python to log data to file. Maybe there is some examples ?
Thank You in Advance.
You will need to use stream mode for the 100 k sample rate. The maximum scan rate for 24 channels is 4166 Hz which looks like the number you calculated, but it seems like you want 12 differential readings which is considered 12 channels if you specify the analog inputs negative channel to not be single ended. For 12 channels the max. scan rate is 8333 Hz. The AIN#_NEGATIVE_CH registers can be used to configure the negative channel for a differential reading, and is documented in the analog input section of the datasheet:
https://labjack.com/support/datasheets/t7/ain
For the max data rate of 100k samples/second with stream mode, the lowest resolution 1 (0 defaults to 1) and range +/-10 V need to be used. Stream mode data rates are discussed here:
https://labjack.com/support/datasheets/t7/appendix-a-1
Refer to the Mux80 datasheet for its documentation and help on analog input channel mapping:
https://labjack.com/support/datasheets/accessories/mux80
Regarding code, refer to the stream examples in the Python download:
https://labjack.com/support/software/examples/ljm/python
We don't have an example that logs to a file, but here is Python documentation on file I/O operations:
https://docs.python.org/2/tutorial/inputoutput.html#reading-and-writing-files
Thank You! It helped a lot.
But to be sure:
I have connected main signal to AIN48 and negative to AIN56. And If I will address to AIN48_NEGATIVE_CH through code so it will be already a differential reading?
Thank You in Advance!
Yes, AIN48-AIN56 is a valid differential pair. You want to write AIN48_NEGATIVE_CH=56, and then when you take a reading from AIN48 it will be taking a differential measurement. To test, jumper VS to both AIN48 and AIN56. If you read AIN48 single-ended it will read about 5V, but if you read AIN56 differentially it will read about 0V.
Note that most signals are naturally single-ended, and best measured single-ended, with the major exception being bridge circuits:
https://labjack.com/support/app-notes/differential-analog-inputs
Hello and thanks for your last reply,
The problem then setting differential reading: WriteNameOrDie(handle, "AIN72_NEGATIVE_CH" , 80); The return is:
LJM_eWriteName(Handle=1, Name=AIN72_NEGATIVE_CH, Value=80.000000) error: "AIN_NEGATIVE_CHANNEL_INVALID" (ErrorCode: 2373)
Works well with channels from 48 - 53.
Or it's wrong way to do it ?
Thank You in Advance!
72-80 is not a valid differential pair. Check out table 2 here: https://labjack.com/support/datasheets/accessories/mux80
72 can be the negative channel for 64. And 80 can be paired with 88.
Thanks, missed that fact.
Have a nice day.