18/09/2003
HESC-UPS Manual
Tri-M Engineering
Tel:
800.665.5600, 604.945.9565
1407 Kebet Way, Unit 100
Fax:
604.945.95
Port Coquitlam, BC, V3C 6L3
E-mail:
Canada
Web
site:
www.tri-m.com
7
Section 3 : HESC-SER SerBus Communications
A. Description:
The HESC-SER communicates with the Host through the asynchronous serial bus. Commands and data are sent and
received using a full duplex 8 bit, no parity, 9600 baud, and one stop bit format. The HESC-SER operates in a "slave"
mode where the Host initiates all the communications between the HESC-SER and the Host.
- Table 1 lists the commands the HESC supports.
To ensure reliable communication, an acknowledge byte is returned after each address, command or data byte
transmitted. The receiving device (HESC-SER or Host) must acknowledge receipt of each byte, unless the bus timer is
turned off. If an acknowledge byte doesn't match the acknowledge number expected then a "collision" is deemed to have
occurred. The transaction is aborted immediately and the result byte set accordingly.
An "enhanced" communication mode is available by adding an optional checksum value. If the HESC-SER receives a
Read command from the Host with the acknowledge set to 0x03 after sending [databyteR high], it will switch to enhanced
mode for all future communications. Communication will return to non-checksum mode when the Host CPU sends an
acknowledge 0xFF after [databyteR high].
B. Slave Mode:
1. Commands received from the Host and data sent to or received from the to Host CPU over the SerBus. The
transaction is invalid and commands/data are not to be used until:
-
the final acknowledge 0xFF is received
-
the checksum matches the transmitted data (checksum is optional, but if sent must be used)
2. Note: Read and Write is defined as the action the command places on the HESC-SER RAM and EEprom. Therefore,
Read and Write have the same meaning for Master and Slave modes:
3a. Write command without checksum acknowledge.
HOST: <addressW> <command> <databyteW low > <databyteW high >
HESC-SER: [0x00] [0x01] [0x02] [0xFF]
3b. Write command with checksum acknowledge.
HOST: <addressW> <command> <databyteW low > <databyteW high > <checksum>
HESC-SER: [0x00] [0x01] [0x02] [0x03] [0xFF]
3c. Write command without checksum acknowledge and without bus timer enabled.
HOST: <addressW> <command> <databyteW low > <databyteW high >
HESC-SER: [0x00]** [0x01]** [0x02]** [0xFF]**
4a. Read command without checksum acknowledge.
HOST: <addressR> <command> <0x02> <0xFF>
HESC-SER: [0x00] [databyteR low] [databyteR high]
4b. Read command with checksum acknowledge.
HOST: <addressR> <command> <0x02> <0x03> <0xFF>
HESC-SER: [0x00] [databyteR low] [databyteR high] [checksum]
4c. Read command without checksum acknowledge and without bus timer enabled.
HOST: <addressR> <command>
HESC-SER: [0x00]** [databyteR low] [databyteR high]
**{HOST does not need to wait for Ack from HESC-SER}