Implement auto-addressing capabilities for Bluetooth car access systems

Article By : Donovan Porter and David Lara

These wired and wireless methods allow designers to implement auto-addressing capabilities for Bluetooth car access systems.

Car access systems that use Bluetooth Low Energy typically have a central module and multiple satellite modules/nodes, which communicate through either a controller area network (CAN) bus or local interconnect network (LIN) buses. The satellite modules are physically distributed around the car to improve the Bluetooth communication range.

System designers would like to improve satellite module manufacturability by designing one PCB with identical software so that installation in the car is agnostic of the position of the Bluetooth node. However, since the hardware and software of each satellite node at installation time is identical, a scheme is needed to allow the central module to assign a unique CAN or LIN address to each satellite node after the modules are installed in the vehicle.

One option is to use a dedicated LIN daisy-chain network to share CAN IDs to the modules during manufacturing. In this scenario, the central module uses the LIN interface to address each satellite module, but the LIN interface will not be used again for the life of the vehicle. Another option replaces the dedicated LIN bus with a discrete implementation that reduces bill of materials (BOM) costs. To further trim the system costs, a true wireless option using Bluetooth only, and no extra hardware, repurposes the Bluetooth infrastructure already available on the nodes to address the modules.

Ultimately, the wireless method reduces BOM, system wiring, and the cost of stocking, managing, and assembling the now-unnecessary components. This article presents an overview of wired auto-addressing methods before taking a more in-depth look at the wireless method.

Automotive car access systems have been trending toward using Bluetooth Low Energy for phone-as-a-key or other digital-key capabilities. These systems operate similarly to passive-entry passive-start systems but add the ability to use the driver’s smartphone as the key, thus replacing traditional key fobs. Phone-as-a-key-compatible vehicles implement a central module or smart key module and multiple satellite modules, each capable of receiving a Bluetooth signal from a smartphone or key fob. A typical system might have between six and 12 satellite modules, in addition to the central module (Figure 1).

diagram of Bluetooth satellite module distributionFigure 1 This diagram shows where Bluetooth satellite modules could be distributed throughout the car.

Consumers need the phone-as-a-key system to be able to determine when the phone or key fob is within the unlocking zone of the vehicle. To approximate the location of the smartphone or key fob, the system triangulates the signals received by various satellite modules, which are distributed throughout the car in places such as the passenger side door, rocker panel, trunk, or bumpers.

The vehicle’s central module communicates with the satellite modules using a communication interface such as CAN bus or LIN bus. The central module uses the data received from each satellite module to triangulate the location of the smartphone or key fob and then determines whether to grant entry access to the car. Figure 2 illustrates how a CAN bus can be used as the main communication network between the central and satellite modules.

diagram of CAN bus as the main communication networkFigure 2 A CAN bus can be assumed as the main communication network between the central and satellite modules in a Bluetooth car access system network.

The satellite modules’ CAN bus address enables the central module to determine which satellite module it is receiving data from. The central module associates the unique CAN ID or address with the location of each specific satellite module, determined by the overall system design. Rather than having a unique PCB for each satellite module, with the bus address hard-wired or hard-coded in, it would be advantageous to have a single PCB design running a single version of firmware for all satellite modules. This avoids the added cost and logistics issues involved with manufacturing and inventory management of six, eight, or more nearly-identical units. A single design also simplifies manufacturing by enabling the installation of the same satellite module anywhere in the vehicle.

Since the hardware and software of the satellite nodes are all identical and unaddressed at the time of installation, a scheme is required that enables the central module to assign a unique CAN ID or address to each satellite module after installation in the automobile.

Wired auto-addressing: LIN daisy-chain method

At present, assigning CAN bus addresses to satellite modules in automobiles is accomplished using a separate communication network (such as LIN) with the satellites daisy-chained on the bus (Figure 3). The central module sends a CAN bus network address to the first satellite node over the LIN bus. Once complete, the first satellite node will send the next address received from the central module to the second satellite using the LIN bus. This process continues until all satellites have received their unique CAN addresses.

wired auto-addressing architecture using LINFigure 3 This auto-addressing architecture uses a LIN daisy-chain for sending the unique CAN IDs to the satellites.

This scheme requires two LIN physical layers (PHYs) per module, one for receiving data and another for transmitting data. The LIN PHYs are only used during the auto-addressing operation. Once the satellites are programmed, all standard data communications are accomplished via the car access CAN bus. A typical automobile may have six to 12 satellite modules, which means that it will require anywhere from 14 to 26 LIN PHYs to support the one-time auto-addressing operation, adding significantly to the vehicle’s PCB BOM, system cost, and complexity.

Wired auto-addressing: Single-wire method

Texas Instruments has developed an alternate method to reduce the BOM cost of each module by replacing the dedicated auto-addressing LIN PHYs with a MOSFET and a few resistors. The primary difference in this scheme’s auto-addressing software is that all satellite modules are programmed for the Bluetooth system of chip (SoC) to ignore the CAN bus until a wake signal is received on the P_IN line. Figure 4 shows the block diagram.

single wire auto-addressing block diagramFigure 4 The single wire auto-addressing method replaces the LIN PHYs with a MOSFET and a few resistors.

The central module initiates the auto-addressing process by sending a pulse-width modulation (PWM) signal on the P_IN1 line using field-effect transistor Q1. Through a voltage divider, the first satellite module receives the battery-level wake signal, P_IN1, signaling the Bluetooth MCU to “listen” to the CAN bus. In parallel, the central module begins constantly transmitting the first satellite module CAN ID on the CAN bus. Once the first satellite module receives the CAN ID message, it sends an acknowledge message back to the central module to acknowledge proper reception of the address. After sending the acknowledge message, the first satellite module sends the PWM wake signal to the second satellite module, signaling that module to begin listening to the CAN bus and receive its new CAN ID. After the central module receives the acknowledge message from the first satellite module, the CAN bus will constantly transmit the second satellite module’s CAN ID message until it receives an acknowledge message from the second satellite module.

In summary, each satellite module, one by one, wakes the next to receive the CAN ID from the CAN bus. The central module increments the next CAN ID transmitted after receiving an acknowledge message from the addressed satellite module until all modules are addressed*.

While it is an improvement, this implementation still requires wiring between the central module and each of the satellite modules as shown in Figure 5.

single wire auto-addressing car diagramFigure 5 The single wire auto-addressing architecture still requires wiring between the central and satellite modules.

Wireless auto-addressing/cable replacement

Texas Instruments has also developed an auto-addressing method that uses Bluetooth localization techniques. These techniques enable the Bluetooth satellite modules to be assigned a CAN address from the central module during manufacturing and after a module is replaced. The module addressing process begins with the module determined to be closest to the central module and continues in order of closest to farthest distance until the farthest module is addressed. The actual location is not necessary, since the placement of the modules, measurement technique, and module surroundings will determine the measured distance. Distance dn represents the measured distance (from the Bluetooth received signal strength indication [RSSI]), ideally:

d1 < d6 < d5 < d2 < d4 < d3

For example, Figure 6 shows the block diagram and the distance between each module and the central module.

wireless auto-addressing module distance diagramFigure 6 This diagram shows the distances between each module in the wireless auto-addressing method from the central module.

In practice, the actual distance can vary from the measured distance due to the radio-frequency (RF) propagation characteristics of the space between the particular satellite and the central module. But, as long as the measured distance from each satellite module is repeatedly consistent, and there is no overlap between measured distances from multiple modules, the central module can properly address them without knowing their exact location around the vehicle because the distances measured will always be in the same order from shortest to farthest. Therefore, the central module will know, from prior testing, that the first module is always the driver side door (CAN address 1), the second module is always the front bumper (CAN address 2), and so on.

In order to ensure the auto-addressing scheme will work reliably, careful testing must be used to understand the characteristics of each vehicle model, making it possible to identify and resolve any potential issues. For example, if the central module distance measurements between two or more unaddressed satellite modules are similar or equal, a previously addressed satellite module can be used to localize those unaddressed modules that were not distinguishable by the central, as shown in Figure 7. This can be done using multiple satellite modules as well.

wireless auto-addressing localize unaddressed modules diagramFigure 7 A previously addressed satellite module can be used to localize unaddressed modules that were not distinguishable by the master.

When the central module is able to localize satellites 1, 2, and 6, but not 3, 4, and 5, satellite module 2 is then used to measure the distances for satellite modules 3, 4, and 5. Again, as long as the distance measurements are consistent and there is no overlap on distance measurements between modules, the satellite modules can be addressed properly and will always be addressed in the same order.

Implementation

In order to be consistent with the generic access profile (GAP) layer of the Bluetooth Low Energy protocol, we shall refer to the central module as a “scanner” and the satellite modules as “advertisers.” The GAP layer handles the access modes and procedures of the device, including device discovery, link establishment, link termination, initiation of security features, and device configuration. The two states of the device relevant to auto-addressing are:

  • Advertiser: The device is advertising with specific data letting any initiating devices know that it is a connectable device (Note: this advertisement contains the device address and can contain some additional data such as the device name).
  • Scanner: When receiving the advertisement, the scanning device sends a scan request to the advertiser.

 

The advertiser responds with a scan response; this process is called device discovery. The scanning device is aware of the advertising device and can initiate a connection with it. Figure 8 shows the advertiser and scanner flow below.

BLE software flow diagramFigure 8 This Bluetooth Low Energy software diagram shows the advertiser and scanner flow.

Looking at Figure 8, all of the advertisers will be advertising with specific data, they will generate a true random number to be used as part of their advertising data. This guarantees no node duplication.

The scanner will scan multiple times and read the RSSI values from each of the advertisers; it will then average the RSSI values to determine the advertiser closest to it.

The scanner will send a SCAN request to the closest advertiser; it will then transmit the auto-address CAN message and wait for the advertiser CAN message acknowledgement.

The advertiser will use SCAN_REQ to enable the CAN auto-address. When the advertiser receives the auto-address CAN message, it will send the CAN acknowledge message and stop advertising.

These steps repeat until all advertisers have been auto-addressed.

Results

Testing was done using the car access Bluetooth Low Energy + CAN satellite module reference design, along with a 12-ft harness. The separation between each connector was around 6 ft (Figure 9).

TI hardware setup for testingFigure 9 The hardware setup for testing includes the TIDA-020032 reference design.

And the boards were placed as shown in Figure 10 (where d1 ~4 ft and d2 ~8 ft):

diagram of hardware placement for testingFigure 10 This diagram shows the hardware placement for testing.

The Bluetooth Low Energy parameters for the scanner were a 1-s scan duration and a 250-ms scan window and interval. The advertisers’ Bluetooth Low Energy parameters for the advertisers were advertised during a 100-ms interval. During each measurement period, the scanner took 10 RSSI samples per node, and averaged each set of measurements to produce each advertiser’s measured distance value.

Comparing three auto-addressing schemes

The results of the previous test are summarized Table 1, which compares the relative delay, reliability, and implementation costs of each of the three auto-addressing techniques discussed in this article.

Table 1 Comparison of auto-addressing techniques

table comparing auto-addressing techniques

Table 1 compares the results of our wireless Bluetooth Low Energy addressing test with the two wired auto-addressing techniques discussed earlier. From these results, it looks as if the wireless technique takes approximately 5 times longer than the wired techniques. A better, faster response may be achieved by further refinement of the Bluetooth Low Energy network’s parameters; there is room for improvement. This will require further testing because the actual distance may vary from the measured distance due to the RF propagation characteristics associated with each node’s particular location in the vehicle (i.e. non-line-of-sight challenges).

Wireless auto-addressing is the most cost-optimized solution from a materials perspective, requiring no extra hardware and no extra wiring between modules. However, in order to enjoy these advantages, system designers will need to perform testing to provide the RF performance to optimize the software and account for inaccuracies. If you prefer a wired approach, TI’s wired auto-addressing method requires the addition of a few small and low-cost components to the BOM, along with wires connected between each module. Together, they provide a set of options when choosing a method to implement auto-addressing capabilities for Bluetooth car access systems.

* For additional details and test results on the single-wire auto-addressing method, consult the Texas Instruments car access Bluetooth Low Energy + CAN satellite module reference design guide.

This article was originally published on EDN.

Donovan Porter is a systems engineer on the automotive body electronics and lighting team at Texas Instruments.

David Lara is an applications engineer for connectivity at Texas Instruments.

References

  1. Bluetooth core specifications
  2. The Standard for Connection Sets New Standards in Safety, Bluetooth SIG

Related articles:

Leave a comment