Description of GM’s Entertainment and Comfort Serial Bus

Stuart Schmitt, 22 April 2016
E&C bus table of contents

Introduction

The Entertainment and Comfort (E&C) serial bus is a low-speed data bus used for communication between various modules in certain GM vehicles made prior to 2005. This page describes its operation from the electrical level up through the construction of a valid packet.

Physical signaling

Image of E&C bits on an oscilloscope

The E&C bus operates on a single wire with two voltage states, near-ground and near-battery. The high-voltage state is the idle condition, and it is achieved by the a pull-up resistor between the battery and the bus. The pull-up resistance is on the order of 22 kΩ. During the bus’s active state, it is pulled low. It is effective to pull it directly to ground with an NPN transistor, but it is equally effective to include a 1 kΩ pulldown resistor in order to protect the circuit in case of a short to battery. See the microcontroller interface page for more information.

Bits are pulse-width modulated at a rate of 1000 bps, so the total duration of each bit symbol is 1000 μs. A logical 0 is given by a 111 μs LOW pulse followed by a 889 μs return to the idle HIGH state. A logical 1 is given by a 667 μs LOW pulse followed by a 333 μs return to HIGH. Note that the frequency divisor for the pulse durations is 9. The image to the right is an oscilloscope view of both bit types.

Message framing

The E&C bus is an asynchronous transmission medium; there is no master clock and modules send messages at any time they are ready. Modules wait for the bus to clear before sending messages. In other words, the media access control method is carrier sense multiple access. The required quiet time is at most 15 ms based on observed time intervals between bus messages.

Each message frame is composed of a variable but always even number of bits. According to the Delphi SAINT manual, the maximum length of an E&C packet is 32 bits plus the start and parity bits (34 total). The first bit is a start bit, which is always a logical 1. An even number of datagram bits follows. If the datagram only requires an odd number of bits to encode, a 0 is appended. Finally, the frame ends with a parity bit that is even-valued depending on the datagram bits. That is, the parity bit is determined such that there are always an even number of 1s that follow the start bit. Since the start bit is always a 1, there are always an odd number of 1s in a frame.

Since it is permissible to append zeros to the end of a datagram, it is therefore logical to parse E&C messages as least significant bit (LSB) first, or “little endian.” Modules will indeed ignore extra zeros if they are sent, as long as there is an even number of bits.

The most common data link error is for a receiving module to miss a start bit and to trigger reading the bus on a subsequent bit. The combination of the requirement of an even number of data bits and the presence of a parity bit allows for some error correction. For reasons discussed below, a further constraint on a frame is that the first two bits of the datagram cannot both be 0. With that in mind, error correction becomes fairly robust. Here is a sample error-correction algorithm:

If the number of datagram bits is even,

if parity mismatches,

prepend 10 to the data;

return—datagram is error-free;

else if data starts with 00,

prepend 11 to the data;

return—datagram is error-free;

else,

return—datagram is error-free;

else,

prepend a 0 or a 1 to the data according to the parity bit;

recurse to the beginning of this algorithm;

end.

Addressing

The first byte of the datagram in a message frame contains information about the message priority and a module address. The first two bits indicate the message priority. The third through eighth bits contain the address of the module. For priority 1 and 2 messages, the address is the sender, while for priority 3 messages, the address is that of the receiving module.

PriorityAddress typeMessage type
00 (0)Not permitted
10 (1)senderLow priority; information only
01 (2)senderMedium priority; typically information that will be presented on a display
11 (3)recipientHigh priority; a command that must be followed by an action by the receiving module

The fifth bit (third bit of the address) appears to be significant, but its meaning is unclear. It appears that addresses with either a 0 or 1 in that position are related. For example, commands from the radio to the CD changer have address 30 (011110), while responses from the CD changer have address 26 (010110). However, not all command-response pairs have that relationship—personalization commands from the IPM (integration and personalization module) have priority 3 and address 57 (100111), and the radio’s response has priority 1 and address 57. It appears to be true that priority 3 messages may have the third address bit (fifth header bit) set to either 0 or 1, but that it is always 0 for priority 1 and 2 messages. That observation may be contradicted by additional observations.

Some observed message headers are shown in the following table. Command-response address pairs with a 1 in the third bit are shown together. Address 41 is an anomaly; all messages with that address appear to be sent by the radio. Some are priority 3 commands, but are not all directed toward the same module. Others are priority 1 information messages that are relevant for yet different modules. Perhaps address 41 is a “broadcast” address, or perhaps some other meaning will become clearer with observations from other cars. Address 44 is also an anomaly; some priority 3 messages are actually statements from the radio about what audio source is selected, while others are instructions to the radio from other modules.

PriorityAddressesModule
1 19 OnStar (session status)
1, 3 24, 28 Cassette player
1, 2, 3 26, 30 CD changer
1, 2, 3 40, 44 Radio (power, clock, and source selection)
1, 3 41 From radio to miscellaneous receivers
1, 3 48, 52 OnStar (cellular communication)
3 51 OnStar (module presence)
1, 3 57 IPM (personalization)

Constructing a packet

Following the structure defined above, it is now possible to construct an E&C packet. The format used here to write out a packet is

[priority]-[address]-[first byte of data]-[second byte of data, if present]-[third byte of data, if present]

For example, consider the message 1-40-63-5, which is a power status message from the radio indicating that the car’s accessory power is on and that the audio system is turned on. Converted to LSB-first binary, the contents of the datagram are

PartValueLSB-first binaryCumulative 1s
priority1101
address400001013
data63111111009
51010000011

The final four 0s are grayed out to indicate that they are not necessary to send. It is, however, required to send the 0 that follows the last 1 in order to satisfy the requirement of an even number of bits. Since there are an odd number (11) of 1 bits in the datagram, the parity bit is 1. Putting it all together, the fully framed packet looks like this:

idle one onezero zerozerozeroonezeroone oneoneoneoneoneonezerozeroonezeroonezero one idle
idle
start
priority
address data
parity
idle
datagram
frame

Message meanings

See the separate page tabulating known E&C messages.