Get information about Test Input channel parameters of the CMSIS-DAP Debug Unit.
More...
Get information about Test Input channel parameters of the CMSIS-DAP Debug Unit.
The DAP_TI_Info Command provides information about additional Test Inputs that are possible to capture with the CMSIS-DAP Debug Unit.
DAP_TI_Info Request:
| BYTE | BYTE | BYTE ***|
> 0x1D | ID | Channel |
|******|******|*********|
- ID: Request Identifier to obtain information in the Response:
- 0x00 = Get general Test Input channel parameters (Channel value not used).
- 0x01 = Get parameters of a specific Test Input Channel.
- 0x02 = Get possible data capturing frequencies.
- Channel: channel number.
DAP_TI_Info Response for ID=0x00: Get general Test Input channel parameters
| BYTE | BYTE ****|
< 0x1D | Channels |
|******|**********|
- Channels: number of channels available in the Debug Unit.
DAP_TI_Info Response for ID=0x01: Get parameters of a specific Channel
| BYTE | BYTE ***| BYTE ******| BYTE ***| LWORD ***| LWORD *****| BYTE ****| FLOAT *| FLOAT *|
< 0x1D | Channel | Attributes | NumBits | IdString | UnitString | Compress | MinVal | MaxVal |
|******|*********|************|*********|**********|************|**********|++++++++|++++++++|
- Channel: channel number that information belongs to.
- Attributes: attributes of the data channel
- Bit 0..1: DataSize: number of bytes recorded (0=BYTE, 1=SHORT, 2=WORD)
- Bit 2..3: NumRanges: channel data provides additional range bits (see below)
- Bit 4: DT_TimeStamp: 1= channel provides time stamp based on Test Domain Timer
- NumBits: resolution of the channel in bits
- IdString: is a up to 8 character 8-bit US ASCII string that identifies the channel
- UnitString: is a up to 8 character 8-bit US ASCII string that identifies the measurement unit of the channel (V, mA, kHz)
- Compress: describes the difference communication that is optionally available (see below)
- MinVal: minimum data value (= 0) represents the MinVal. Repeated for each range.
- MaxVal: maximum data value result represents the MaxVal. Repeated for each range.
- Note
- NoRanges: specifies if the channel data has data ranges; possible values are:
- 0 = 1 range (1 MinVal/MaxVal value pair in the response).
- 1 = 2 ranges (2 MinVal/MaxVal value pairs are provided in the response)
- 2 = 4 ranges (4 MinVal/MaxVal value pairs are provided in the response)
-
Compress specifies a method for data differences by this channel.
- 0 = no data differences can be communicated. Only Contiguous Value Format is transmitted in DAP_TI_TransferBlock Response.
- 1 = data differences are transmitted when a single bit is different.
- 2 = new data are transmitted when a value has a significant difference. The least significant 3-bits are ignored. This is useful for A/D values.
- 3 = new data are transmitted when a value has a significant dynamic difference. Only the uppermost 8-bits are considered. This is useful for dynamic A/D values such as the currency consumption of a device.
-
Data Value Scaling: the information NoBits, MinVal, MaxVal is used to convert the binary data value into a floating data value for displaying purposes. If both MinVal and MinMax are 0 no scaling formula is provided and raw data may be displayed instead. Scaling considers the NoBits value, for example at 12-bit resolution the maximum data value is 0x3FF.
-
Data Ranges: the information NoRanges, NoBits allows scaled data value based on range information. The range information is provided in the upper data bits. For example a data channel with NoBits=12 and NRanges=2 provides in bit 0..11 the data value and in bit 12..13 the range value.
Example 1: parameters for a channel that supports voltage measurement
IdString = 'U0'
UnitString = 'V';
NoBits = 10;
NoRanges = 0;
Compress = 2;
MinVal = 2.5;
MaxVal = 6.0;
Example 2: parameters for a channel that supports current measurement with two ranges
IdString = 'I';
UnitString = 'mA';
NoBits = 12;
NoRanges = 1;
Compress = 3;
MinVal[0] = 0;
MaxVal[0] = 1.0;
MinVal[1] = 4.0;
MaxVal[1] = 20.0;
For a channel that reports MinVal = MaxVal = 0 the formula needs to be provided by the debugger as the debug unit is using perhaps an external shunt resistor.
DAP_TI_Info Response for ID=0x02: Get possible data capturing frequencies for recording of a specific channel
| BYTE | BYTE ***| BYTE ********|DWORD ++++|
< 0x1D | Channel | NoSelections |Frequency |
|******|*********|**************|++++++++++|
- Channel: channel number that information belongs to.
- Channel = 0..0xF: information of the selected channel
- Channel = 0xFF: information for common channel data capturing
- NoSelections: number of possible capture frequencies
- NoSelections = 0: channel does not support data recording
- NoSelections = 1..15: channel allows selection of individual data capture frequencies.
- NoSelections = 0xFF: channel allows selection of a common data capture frequency.
- Frequency: capture frequencies (repeated as indicated by NoSelection = 1..15)
- Frequency[0] capture frequency for CapSelect=0 (see DAP_TI_Capture)
- Frequency[1] capture frequency for CapSelect=1 (see DAP_TI_Capture)
- Frequency[n] capture frequency for CapSelect=n (see DAP_TI_Capture)