I am adding ps3223 support to our scope application. The software uses block mode and ps3000_get_values. Single channel A is set and has voltage overflow on it. After ps3000_get_values returns, overflow output parameter is set to 2. This does not match ps3000_get_values specification that defines Bit 0 as an overflow flag for channel A. According to the specification the overflow parameter should be 1. All other channels are also shifted by one bit:
Bit1 -> Channel A
Bit2 -> Channel B
Bit3 -> Channel C
Bit4 -> Channel D
The same problem exists on ps3000_get_times_and_values.
Did anybody face the same issue?
- Code: Select all
// Applied signal: 1 KHz DC, +-10V.
nHandle = ps3000_open_unit();
ps3000_set_channel(nHandle, PS3000_CHANNEL_A, 1, 0, 2);
ps3000_set_channel(nHandle, PS3000_CHANNEL_B, 0, 0, 2);
ps3000_set_trigger(nHandle, PS3000_NONE, 0, 0, 0, 0);
ps3000_run_block(nHandle, 1000, 6, 1, &nTime);
while ((nReady = ps3000_ready(nHandle)) == 0);
if (nReady > 0)
ps3000_get_values(nHandle, aBuffer, NULL, NULL, NULL, &nOverflow, 1000);
// nOverflow is 2, must be 1 according to PS3000 specification.