Public Member Functions
- bool check ()
- void loop (uint8_t a_rx, uint8_t a_tx, uint8_t b_rx, uint8_t b_tx)
Detailed Description
An implementation of a software bridge between two series of Rx/Tx pins, that enables routing of the hardware serial port (connected to the PC) to digital I/O pins used as a software serial port (connected to the EasyVR).
Member Function Documentation
Tests if bridge mode has been requested
- Return values:
-
| is | true if bridge mode should be started |
- Note:
- The first two EEPROM locations (bytes 0-1) are used for discovery and request of bridge mode from the EasyVR Commander software. Do not use the same locations for other programa data.
void loop |
( |
uint8_t |
a_rx, |
|
|
uint8_t |
a_tx, |
|
|
uint8_t |
b_rx, |
|
|
uint8_t |
b_tx | |
|
) |
| | |
Performs bridge mode between port A and B in an endless loop
- Parameters:
-
| a_rx | is the Rx pin of port A |
| a_tx | is the Tx pin of port A |
| b_rx | is the Rx pin of port B |
| b_tx | is the Tx pin of port B |
- Note:
- Bridge mode internally connects Rx:A to Tx:B and Rx:B to Tx:A. This is done by reading from a pin and writing to the other in a fast loop, that runs until the microcontroller is reset.