3.4.12 AVR Printf Queue Sampler

Used to read out data from a queue on a AVR device.

The printf queue is a circular buffer stored in the AVR device's SRAM space along with some administrative functions. It consists of:
  1. 1 byte token.
  2. 1 bytes size.
  3. 1 byte write index.
  4. 1 byte read index.
  5. (2^size)-4 bytes circular buffer.

The printf queue sampler reads available bytes from the read index and sends data to the host computer.

Table 3-60. AVR Printf Queue Sampler
FieldSizeDescription
DATA_SAMPLER1 byte0x8A
SAMPLE_PRINTF_QUEUE_AVR1 byte0x0D
ENABLE1 byte

0x00: disable

0x01: enable

ADDRESS2 bytesStart address of queue structure to poll, MSB first
FLAGS4 byte
Bits 1:0: destination:
  • b00: send to DGI as data
  • b01: send to HID (reserved)
  • b10: send to DGI as print
  • b11: reserved

Response:

Table 3-61. AVR Printf Queue Sampler Response
FieldSizeDescription
DATA_SAMPLER1 byte0x8A
SAMPLE_PRINTF_QUEUE_AVR1 byte0x0D
Status1 byte

Status code

0x00: OK

0xFF: Error

Note: This feature is in a beta stage and should be used with caution.