Table of Contents
Roomba Digital Output
Controls the state of the 3 digital output pins.
Library
MATLAB Command Line
Click to copy the following command line to the clipboard. Then paste it in the MATLAB Command Window:
qc_open_library('quarc_library/Devices/Third-Party/iRobot/Roomba/Interfacing')Description
The Roomba Digital Output block controls the state of the 3 digital output pins on the 25 pin Cargo Bay Connector. The digital outputs can provide up to 20 mA of current. Note that when the robot is switched on, the digital outputs are high for the first 3 seconds during the initialization of the bootloader.
This command is available in Safe, or Full operating mode of Roomba (see Roomba Modes block). Execution of this command does not change current Roomba operating mode.
Important Notes
Use System Timebase block in Normal simulation.
Input Ports
rmb
A reference to the Roomba stream (see Roomba Initialize block).
bits
Use the following bit pattern to activate the digital outputs:
Bit |
Output |
---|---|
7 |
- |
6 |
- |
5 |
- |
4 |
- |
3 |
- |
2 |
digital-out-3(pin 20) |
1 |
digital-out-2(pin 7) |
0 |
digital-out-1(pin 19) |
Use 1, 2, and 4 to activate pin 19 (digital output 1), pin 7 (digital output 2), and pin 20 (digital output 3), respectively. Other values (3, 5, 6, and 7) activate combinations of different pins.
Output Ports
rmb
A reference to the Roomba stream, which is the same as input Roomba stream reference. It helps creating a daisy chain of Roomba blocks.
err
This signal returns a negative value in case of memory allocation error or data communication error through Roomba serial port.
Parameters and Dialog Box
Sample time
The sample time of the block. A sample time of 0 indicates that the block will be treated as a continuous time block. A positive sample time indicates that the block is a discrete time block with the given sample time. A sample time of -1 indicates that the block inherits its sample time.
Targets
Target Name |
Compatible* |
Model Referencing |
Comments |
---|---|---|---|
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
||
Yes |
Yes |
Last fully supported in QUARC 2018. |
|
Rapid Simulation (RSIM) Target |
Yes |
Yes |
|
S-Function Target |
No |
N/A |
Old technology. Use model referencing instead. |
Normal simulation |
Yes |
Yes |
Use System Timebase. |
Copyright ©2024 Quanser Inc. This page was generated 2024-10-17. Submit feedback to Quanser about this page.
Link to this page.