A Simple, Cost-Effective Approach to Home Automation

Von Emmanuel T. Nana

Zur Verfügung gestellt von Convergence Promotions LLC


Homeowners have several energy management technologies to choose from, but the simplest, most cost-effective approach is to use the home’s existing wiring to create the control network.


For most homeowners, nothing could be simpler or less expensive than using their home’s existing wiring to create a control network. There’s no need for extensive renovations or new wires for the control network, and there’s no special hardware or software tools to install. For these reasons, powerline solutions are emerging as a popular approach for in-home energy monitoring and control.

Once the control system is in place, the homeowner gets to enjoy several benefits. The system can deliver considerable cost savings in terms of energy bills, with precise control of lights, fans, and home appliances, and by allowing appliances on the same network to share data communications. Plus, with a system that includes automated functions, events can be initiated and appliances can be turned on and off automatically, without user intervention. This lets homeowners take advantage of lower utility pricing during off hours, and gives greater control over the home environment when the homeowner isn’t there. Lights can be programmed to turn on and off at specific times, and appliances can be configured to track their own operating data to monitor energy usage.

The TDA5051A from NXP Semiconductors, a highly integrated modem for in-home control applications, gives developers a simple, convenient way to meet consumer demands for low-cost, energy-saving networks for home automation. Optimized for Amplitude Shift Keying (ASK) data transmission and reception over a home power network, the TDA5051A can be used in a range of home-control applications, such as lighting, home appliances, energy monitors and meters, and heating and cooling systems.

NXP ASK powerline modem TDA5051A

The NXP TDA5051A transmits and receives digital signals on standard powerlines or any two-wire AC or DC network. It is a cost-effective solution that transmits at a rate of 600 (typ) or 1200 (max) baud, operates from a single +5 V DC supply, and enables easy connection to standard microcontrollers, including NXP’s LPC11xx series of low-power ARM-based microcontrollers. The carrier frequency is set by an input reference clock or an on-chip oscillator.
TDA5051A block
Figure 1:TDA5051A block diagram.

Figure 1 gives a block diagram of the TDA5051A circuit. The IC includes a high-sensitivity input amplifier with Automatic Gain Control (AGC) for secure detection of small signals on noisy ma ins. It also has a digital narrowband filter with an 8-bit ADC for accurate, sharp filtering of the incoming signals, and a variable-threshold digital demodulator for optimum recovery of the baseband data signal. The data pins are TTL/CMOS compatible for direct connection with a microcontroller, and the circuit supports operating frequencies from 95 to 148.5 kHz.

The IC is designed for worldwide use and complies with industry standard regulations. It is compliant with US Federal Communication Commission (FCC), Industry Canada, Japan MPT, and European CENELEC EN50065-1 regulations for signaling in the 125 to 140 kHz and the 95 to 125 kHz frequency bands.

The transmission and reception stages are controlled either by an external reference clock, from the system’s microcontroller, for example, or by the on-chip reference oscillator connected to a crystal. This ensures the accuracy of the transmission carrier and the exact trimming of the digital filter, thus making the performance independent of application disturbances such as component spread, temperature, and supply drift.

The device includes a power output stage that feeds a 120 dBμV (RMS) signal on a typical 30 Ω load. To reduce power consumption, the IC is disabled by a power-down (PD) input pin. In this mode, the on-chip oscillator remains active and the clock continues to be supplied at the CLK_OUT pin. For low-power operation in reception mode, this pin can be dynamically controlled by the microcontroller.

Features Benefits
ASK powerline modem operating at up to 1200 bps. Easy to implement, simple to modulate/demodulate and requires little bandwidth.
Carrier frequency set by clock from microcontroller or on-chip oscillator. Flexibility in choosing clock source.
AGC receiver input. Improved noise performance and adjustment of signal level. Ensures maximum sensitivity of ADC.
Easy compliance with EN50065-1 with simple powerline coupling networks. Used with powerlines worldwide and complies with industry standard regulations.
SO16 plastic package. Low-cost solution with easy assembly.

Table 1: TDA5051A highlights.


Housed in an SO16 plastic package, the TDA5051A requires just a few external components for full operation. To complete a home automation application, a low-cost mains coupling network, a 5 V power supply, a microcontroller (which can use the same supply), and a standard quartz crystal, which is used with the on-chip clock circuit to set the modem’s operating frequency, are required. For added simplicity, the CLK_OUT output signal can be used to clock the microcontroller.

Transmission, reception, and data formats

The TDA5051A has been optimized for performance in applications requiring data communication over any two-wire AC or DC network. During transmission, to provide strict stability with respect to environmental conditions, the carrier frequency is generated by dividing the reference clock by 64, using a prescaler divider in the device. High frequency clocking rejects the aliasing components to such an extent that they are filtered by the coupling LC network and do not cause any significant disturbance. The data modulation is applied through the DATA_IN pin and smoothly applied by specific digital circuits to the carrier (shaping). Harmonic components are limited in this process, thus avoiding unacceptable disturbance of the transmission channel (according to CISPR16 and EN50065-1 recommendations). A -55 dB Total Harmonic Distortion (THD) is reached when the typical LC coupling network (or an equivalent filter) is used.

The DAC and the power stage are set in order to provide a maximum signal level of 122 dBμV (RMS) at the output. The output of the power stage (TX_OUT) must always be connected to a decoupling capacitor, because of a DC level of 0.5VDD at this pin, which is present even when the device is not transmitting. This pin must also be protected against overvoltage and negative transient signals. The DC level of TX_OUT can be used to bias a unipolar transient suppressor. Direct connection to the mains is done through an LC network for low-cost applications. However, an HF signal transformer can be used when powerline isolation must be performed.

In reception mode, the input signal received by the modem is applied to a wide range input amplifier with AGC (-6 dB to +30 dB). This is basically to improve noise performance and adjust the signal level, so as to ensure maximum sensitivity in the ADC. An 8-bit conversion is then performed, followed by digital band-pass filtering, to meet the CISPR16 normalization and to comply with some additional limitations met in current applications. After digital demodulation, the baseband data signal is made available after pulse shaping. The RX_IN signal pin is a high-impedance input which has to be protected and DC decoupled for the same reasons as with TX_OUT pin. The high sensitivity (82 dBμV) of this input requires an efficient 50 Hz rejection filter (realized by the LC coupling network), which also acts as an anti-aliasing filter for the internal digital processing.

In transmission mode, the data input (DATA_IN) is active LOW: this means that a burst is generated on the line (TX_OUT pin) when the DATA_IN pin is LOW. The TX_OUT pin is in a high-impedance state as long as the device is not transmitting. Successive logic 1s are treated in a Non-Return-to-Zero (NRZ) mode. In reception mode, the data output (DATA_OUT) pin is active LOW; this means that the data output is LOW when a burst is received. The DATA_OUT pin remains LOW as long as a burst is received.

Powerline isolation

Since the TDA5051A connects to the powerline, it needs to be isolated from current spikes and noise. Figure 2 shows a schematic of the TDA5051A featuring powerline isolation. The IC has unique features for a digital powerline communication system. The powerline isolation circuitry and the receive/transmit (Rx/Tx) data interface to the powerline are provided by a specialized converter transformer. A series power inductor and a high-voltage coupling capacitor afford powerline filtering. The powerline isolation circuitry and the AC-to-DC power supply circuit provide the +5 V DC supply for the TDA5051A.

Powerline isolation

Figure 2: The TDA5051A with powerline isolation.

In the configuration shown, the reference clock is generated by a low-cost, fundamental crystal oscillator. The reference clock can also be provided by an external clock source, such as from the microcontroller clock, or the clock output (CLK_OUT) of the TDA5051A can be used as the clock for the microcontroller. The CLK_OUT, DATA_IN, DATA_OUT and PD (power-down) pins provide easy interface with the microcontroller.

ASK redundancy software protocol

ASK transmission is relatively inexpensive, easy to implement, simple to modulate/demodulate, and requires little bandwidth compared to other formats, such as Frequency Shift Keying (FSK). One drawback of ASK, however, is that it can be difficult to use in noisy environments.

To help address this, NXP has developed a special ASK protocol for use with the Cortex-M0 microcontroller LPC1114. The software provides robust control via powerline communication for home automation of lighting, appliances, and security systems. The protocol used for the ASK modem calculates and checks the parity on each byte and the checksum on each message. A slave that receives a proper framing byte, the correct number of bytes in the message, and no parity or checksum errors, will transmit a successful acknowledge message and act on the command embedded in the message. If the acknowledge message is not received within a preset time, the master re-transmits the message up to ten times until a successful acknowledge message is sent. The dedicated ASK protocol includes redundancy and improves the robustness of the TDA5051A, even in environments that are comparatively noisy.

TDA5051A in a home-control network

Figure 3: The TDA5051A in a home-control network.

Sample application: home-control network

Figure 3 shows the TDA5051A in a home-control network. The network includes a single control unit and several appliance units. The control unit sits on a 220 V powerline and is connected to appliance units located throughout the house. Each appliance unit is associated with an electrical appliance — a lamp, a fan, or a refrigerator — just about anything with an on/off switch can be put on the network.

The control unit includes a microcontroller, such as the LPC1114, and supports an interactive interface that the homeowner uses to configure and control the network. Each appliance unit is equipped with a low-cost microcontroller to process data received from and transmitted to the powerline.

The microcontroller in the control unit writes data to the TDA5051A. The TDA5051A encodes the data and sends it over the powerline. The TDA5051A in the appliance unit receives the data from the powerline and decodes it for the low-cost microcontroller, which uses the data to perform the function requested by the control unit.

This in-home control network is designed to support a wide variety of commands. In addition to simple on/off commands, it can support incremental commands such as bulb dimming or adjusting window blinds up or down. The network can control appliance operation, too, such as turning on a DVD player and then playing a DVD. The set-up can also transfer data across the network, to monitor energy usage or send notifications, such as when a refrigerator has been opened.

Lighting-control network

Figure 4: The TDA5051A in a lighting-control network (demonstration kit).


Sample application: lighting control

Figure 4 shows the TDA5051A modem and the LPC1114 microcontroller configured for a lighting-control application. NXP makes this configuration available in an evaluation/demonstration kit. The kit consists of a master controller and a slave lighting controller, each housed in a separate plastic box. The master controller consists of three boards: a TDA5051A board, an LPC1114 board, and a power-management demonstration board, which provides the +5 V DC and +3.3 V DC power supplies. The master controller board has four push-button switches to provide dim-up and dim-down, as well as on/off and color-mixing lighting control with a remote slave controller. Similar to the master controller, the slave controller also consists of three boards: a TDA5051A board, an LPC1114 board, and an LED driver/power supply board that controls a remote LED lighting array.

The slave controller is an addressable lighting controller capable of receiving commands over the powerline from the master control unit. The slave controller’s command set includes functions such as on/off, brightness level, color mixing and luminary status. A high-brightness (HB) LED is used to indicate a slave fault. It blinks once a second to indicate normal operation. If the controller fails, it will not blink. An NXP PCA9632 is used for RGB color-mixing applications. The 4-bit, PWM0 to PMW3 outputs of the PCA9632 control the four HB LEDs and the 0 to 10 V Boost MOSFET. These outputs are compatible with applications relating to methods used by the lighting industry.

The demonstration kit uses a modular design that makes it easy to support other applications besides lighting. Simply replace the application block with circuitry for the target application; the TDA5051A and LPC1114 configurations remain the same. Other benefits of the kit include software support, zero cross detection, and redundancy support.

Summary

To meet the growing demand for cost-effective in-home control networks, NXP offers the TDA5051A, a highly integrated ASK modem that uses the existing mains network as the communication channel. Offering easy power isolation and supported by dedicated ASK protocol software, the TDA5051A delivers robust performance, even in noisy environments. When combined with the NXP Cortex-M0 microcontroller LPC1114, the TDA5051A enables a wide range of home-control applications. NXP supports the TDA5051A with a lighting-control demo kit that can easily be configured for other home-control applications.
Convergence Logo

Haftungsausschluss: Die Meinungen, Überzeugungen und Standpunkte der verschiedenen Autoren und/oder Forumsteilnehmer dieser Website spiegeln nicht notwendigerweise die Meinungen, Überzeugungen und Standpunkte der DigiKey oder offiziellen Politik der DigiKey wider.

Über den Autor

Emmanuel T. Nana

Article authored by Emmanuel T. Nana of NXP Semiconductors.

Über den Verlag

Convergence Promotions LLC