Difference between revisions of "Firmware-820 Function-109"

From I-CubeX Wiki
Jump to: navigation, search
(VOLTD (109, 6Dh))
Line 141: Line 141:
 
|-
 
|-
 
|}
 
|}
 +
 +
The method can set the gain, where the VoltD range is halved each time the gain is doubled.
  
 
Example:
 
Example:
  
In order to enable the VOLTD function to get the voltage data from an VoltD sensor with I2C device address 104 (default AngleD I2C device address) connected to the 7th I2C port, the following message is sent:
+
In order to enable the VOLTD function to get the 12-bit voltage data in the 0..5.12 Volt range (ie. gain = 1) from a VoltD sensor with I2C device address 104 (default VoltD I2C device address) connected to the 7th I2C port, the following message is sent:
  
:240, 125, 0 {DEV}, 8 {FUNCTION}, 6 {port}, 104 {device address}, 109 {VOLTD function}, 0 {voltage}, 247 (F0h, 7Dh, 00h, 08h, 06h, 68h, 6Dh, 00h, F7h)
+
:240, 125, 0 {DEV}, 8 {FUNCTION}, 6 {port}, 104 {device address}, 109 {VOLTD function}, 0 {12-bit voltage, gain = 1}, 247 (F0h, 7Dh, 00h, 08h, 06h, 68h, 6Dh, 00h, F7h)
 
 
 
In host mode raw sensor data will be output immediately in I2C DATA messages. In stand-alone mode a suitable configuration has to be set using the EDIT CONFIG command before any MIDI messages will be output.
 
In host mode raw sensor data will be output immediately in I2C DATA messages. In stand-alone mode a suitable configuration has to be set using the EDIT CONFIG command before any MIDI messages will be output.

Revision as of 18:19, 23 February 2022

VOLTD (109, 6Dh)

The VOLTD function enables output of the VoltD sensor data in both host and stand-alone mode. In host mode the sensor data is output in I2C DATA messages. In stand-alone mode the sensor data is output according to the stand-alone mode settings of the input number that equals the I2C port number. The following methods can be selected using the FUNCTION command’s method/parameter FP:

FP Data output in host mode Data output in stand-alone mode
0 Voltage [0..4095]; an unsigned 16-bit value representing [0..5.12] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..5.12] Volt sent as one or two bytes (LSB, MSB)
1 Voltage [0..4095]; an unsigned 16-bit value representing [0..2.56] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..2.56] Volt sent as one or two bytes (LSB, MSB)
2 Voltage [0..4095]; an unsigned 16-bit value representing [0..1.28] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..1.28] Volt sent as one or two bytes (LSB, MSB)
3 Voltage [0..4095]; an unsigned 16-bit value representing [0..0.64] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..0.64] Volt sent as one or two bytes (LSB, MSB)
4 Voltage [0..16383]; an unsigned 16-bit value representing [0..5.12] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..5.12] Volt sent as one or two bytes (LSB, MSB)
5 Voltage [0..16383]; an unsigned 16-bit value representing [0..2.56] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..2.56] Volt sent as one or two bytes (LSB, MSB)
6 Voltage [0..16383]; an unsigned 16-bit value representing [0..1.28] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..1.28] Volt sent as one or two bytes (LSB, MSB)
7 Voltage [0..16383]; an unsigned 16-bit value representing [0..0.64] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..0.64] Volt sent as one or two bytes (LSB, MSB)
8 Voltage [0.. 65535]; an unsigned 16-bit value representing [0..5.12] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..5.12] Volt sent as one or two bytes (LSB, MSB)
9 Voltage [0.. 65535]; an unsigned 16-bit value representing [0..2.56] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..2.56] Volt sent as one or two bytes (LSB, MSB)
10 Voltage [0.. 65535]; an unsigned 16-bit value representing [0..1.28] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..1.28] Volt sent as one or two bytes (LSB, MSB)
11 Voltage [0.. 65535]; an unsigned 16-bit value representing [0..0.64] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..0.64] Volt sent as one or two bytes (LSB, MSB)
12 Voltage [0.. 262144]; an unsigned 32-bit value representing [0..5.12] Volt sent in 5 bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..5.12] Volt sent as one or two bytes (LSB, MSB)
13 Voltage [0.. 262144]; an unsigned 32-bit value representing [0..2.56] Volt sent in 5 bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..2.56] Volt sent as one or two bytes (LSB, MSB)
14 Voltage [0.. 262144]; an unsigned 32-bit value representing [0..1.28] Volt sent in 5 bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..1.28] Volt sent as one or two bytes (LSB, MSB)
15 Voltage [0.. 262144]; a 32-bit IEEE-754 float value representing [0..0.64] Volt sent in 5 bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..0.64] Volt sent as one or two bytes (LSB, MSB)
16 Voltage [0..5.12]; a 32-bit IEEE-754 float value representing [0..5.12] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..5.12] Volt sent as one or two bytes (LSB, MSB)
17 Voltage [0..4095]; a 32-bit IEEE-754 float value representing [0..2.56] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..2.56] Volt sent as one or two bytes (LSB, MSB)
18 Voltage [0..4095]; a 32-bit IEEE-754 float value representing [0..1.28] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..1.28] Volt sent as one or two bytes (LSB, MSB)
19 Voltage [0..0.64]; a 32-bit IEEE-754 float value representing [0..0.64] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..0.64] Volt sent as one or two bytes (LSB, MSB)
20 Voltage [0..5.12]; a 32-bit IEEE-754 float value representing [0..5.12] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..5.12] Volt sent as one or two bytes (LSB, MSB)
21 Voltage [0..2.56]; a 32-bit IEEE-754 float value representing [0..2.56] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..2.56] Volt sent as one or two bytes (LSB, MSB)
22 Voltage [0..1.28]; a 32-bit IEEE-754 float value representing [0..1.28] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..1.28] Volt sent as one or two bytes (LSB, MSB)
23 Voltage [0..0.64]; a 32-bit IEEE-754 float value representing [0..0.64] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..0.64] Volt sent as one or two bytes (LSB, MSB)
24 Voltage [0.. 5.12]; a 32-bit IEEE-754 float value representing [0..5.12] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..5.12] Volt sent as one or two bytes (LSB, MSB)
25 Voltage [0.. 2.56]; a 32-bit IEEE-754 float value representing [0..2.56] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..2.56] Volt sent as one or two bytes (LSB, MSB)
26 Voltage [0.. 1.28]; a 32-bit IEEE-754 float value representing [0..1.28] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..1.28] Volt sent as one or two bytes (LSB, MSB)
27 Voltage [0.. 0.64]; a 32-bit IEEE-754 float value representing [0..0.64] Volt sent as nibbles in four bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..0.64] Volt sent as one or two bytes (LSB, MSB)
28 Voltage [0.. 5.12]; a 32-bit IEEE-754 float value representing [0..5.12] Volt sent in 5 bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..5.12] Volt sent as one or two bytes (LSB, MSB)
29 Voltage [0.. 2.56]; a 32-bit IEEE-754 float value representing [0..2.56] Volt sent in 5 bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..2.56] Volt sent as one or two bytes (LSB, MSB)
30 Voltage [0.. 1.28]; a 32-bit IEEE-754 float value representing [0..1.28] Volt sent in 5 bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..1.28] Volt sent as one or two bytes (LSB, MSB)
31 Voltage [0.. 0.64]; a 32-bit IEEE-754 float value representing [0..0.64] Volt sent in 5 bytes (MSB .. LSB) Voltage [0..127] or [0..16383]; an unsigned 7-bit or 14-bit value representing [0..0.64] Volt sent as one or two bytes (LSB, MSB)
32..127 No data No data

The method can set the gain, where the VoltD range is halved each time the gain is doubled.

Example:

In order to enable the VOLTD function to get the 12-bit voltage data in the 0..5.12 Volt range (ie. gain = 1) from a VoltD sensor with I2C device address 104 (default VoltD I2C device address) connected to the 7th I2C port, the following message is sent:

240, 125, 0 {DEV}, 8 {FUNCTION}, 6 {port}, 104 {device address}, 109 {VOLTD function}, 0 {12-bit voltage, gain = 1}, 247 (F0h, 7Dh, 00h, 08h, 06h, 68h, 6Dh, 00h, F7h)

In host mode raw sensor data will be output immediately in I2C DATA messages. In stand-alone mode a suitable configuration has to be set using the EDIT CONFIG command before any MIDI messages will be output.