« Close

Datasheets and User Guides

App Notes

Software & Driver

 

5.3.17 - AsynchConfig

Control command configures the UE9 UART for asynchronous communication.

The UE9 has a UART available that supports asynchronous serial communication. Currently, the UART connects to the PIN2/PIN20 (TX0/RX0) pins on the DB37 connector. On a future UE9 hardware revision, it is expected that the UART will appear on FIO/EIO lines after any timers and counters.

Communication is in the common 8/n/1 format. Similar to RS232, except that the logic is normal CMOS/TTL. Connection to an RS232 device will require a converter chip such as the MAX233, which inverts the logic and shifts the voltage levels.

This serial link is not an alternative to the USB connection. Rather, the host application will write/read data to/from the UE9 over USB, and the UE9 communicates with some other device using the serial protocol. Using this serial protocol is considered an advanced topic. A good knowledge of the protocol is recommended, and a logic analyzer or oscilloscope might be needed for troubleshooting.

Table 5.3.17-1. AsynchConfig Command Response

Command:    
Byte    
0 Checksum8  
1 0xF8  
2 0×02  
3 0×14  
4 Checksum16 (LSB)  
5 Checksum16 (MSB)  
6 0×00  
7 AsynchOptions  
    Bit 7: Update
    Bit 6: UARTEnable
    Bit 5: Reserved
8-9 BaudFactor16  
     
     
Response:    
Byte    
0 Checksum8  
1 0xF8  
2 0×02  
3 0×14  
4 Checksum16 (LSB)  
5 Checksum16 (MSB)  
6 Errorcode  
7 AsynchOptions  
8-9 BaudFactor16  
  • AsynchOptions: If Update is true, the new parameters are written (otherwise just a read is done). If UARTEnable is true, the UART is enabled and the RX line will start buffering any incoming bytes.
  • BaudFactor16: A 16-bit value that sets the baud rate according the following formula: BaudFactor = 216-3000000/(Desired Baud). For example, use a BaudFactor of 65224 to get a baud rate of 9615 bps (compatible with 9600 bps).