• 3-axis gyroscope
• 1 Z-axis angle measurement (heading)
• 1 battery voltage sensor
The analog, digital, and robot and DAQ I/O listed above is accessed using the QUARC
r
HIL blockset. The
UART, SPI, and I
2
C communication channels are accessed through the QUARC
r
Stream blockset. For more
information on accessing communication stream data see the QUARC
r
help under QUARC Targets | User's Guide
| Communications. Table 2.2 lists the HIL blocks used to communicate with the QBot 2's data acquisition hardware.
Block Description
The HIL Initialize block selects the DAQ board and configures the board
parameters. The
HIL Initialize
block is named via the
Board name
parameter,
and all other HIL blocks reference the corresponding HIL Initialize through its
name. The HIL blocks will interface to the DAQ specified in the HIL Initialize
Board type parameter qbot2.
The HIL Read Write block is used to read sensor measurements from the DAQ
and robot and write motor commands to the QBot 2 motors. The inputs and
outputs are specified with numeric channel numbers given in Table 2.4 and
Table 2.3, respectively.
The HIL Watchdog block is used to set the timeout limit for the watchdog timer.
For the QBot 2 DAQ board, if there is no motor output command received for
a consecutive period of time exceeding the watchdog timeout value then the
watchdog will trigger, forcing the motor outputs to 0. The default timeout value
for the watchdog is 50 ms unless specified otherwise with this block. This block
can be used to change the timeout value if 50 ms is not suitable.
Table 2.2: HIL blocks
QBOT 2 - User Manual 14