introduction
Photovoltaic power generation, as the main way to utilize solar energy, has been widely used. Photovoltaic lighting is an independent photovoltaic power generation system, mainly used in the construction and renovation of urban and building lighting systems. At present, wired networks are mostly used in lighting control systems, which are relatively complicated to maintain. How to simplify construction, reduce costs and achieve remote control is a problem worth exploring. This article introduces a solution for remote monitoring of photovoltaic lighting systems using ZigBee wireless sensor network technology, and gives detailed software and hardware design.
1 Composition and working principle of photovoltaic lighting control system
The photovoltaic lighting control system consists of three parts: photovoltaic power generation system, wireless communication system and monitoring computer.
The photovoltaic power generation system consists of solar panels, lead-acid batteries and photovoltaic chargers on the top of the building. Solar cells are the input power source of the lighting system, providing the lighting system with the required electrical energy for lighting and control. During the day, under sufficient light conditions, the received light energy is converted into electrical energy, and the photovoltaic charger charges the battery pack; at night, the battery pack switches the stored electrical energy to the street light load through the photovoltaic charger. When the photovoltaic charger charges the battery pack, in order to extend the battery life, it is necessary to avoid the battery being in an overcharged or over-discharged state. Therefore, it is necessary to monitor and save the data such as the charging current, voltage and power generation of the photovoltaic charger in real time, and it is also required to be able to independently control the switch of the street light.
Since the solar panels in this system are located on the top of the library, and the monitoring computer is in another building 200 m away, separated by a pool, if wired communication is used, it will need to be rewired, which is complex and costly. Therefore, a wireless communication network is used. Wireless communication is not only simple and flexible, without considering wiring issues, but also can be combined with other bus communication methods to achieve long-distance data transmission and street light control. The ZigBee wireless sensor network technology can be used to transmit charger status data; at the same time, the monitoring computer can control the switch status of the street light through the wireless network, realizing real-time monitoring of the charger status and lighting control effects. The control range is within 300 m, and it can be extended to a farther range if a router is added.
ZigBee is a short-distance, low-rate, low-power, low-cost and low-complexity wireless transmission technology, which is very suitable for short-distance wireless transmission with low power consumption and low data volume. The low power consumption of ZigBee limits the communication distance between nodes (usually 70 m). In this system, the distance between nodes exceeds its normal communication distance. There are two solutions: one is to expand the coverage by adding router nodes, but the disadvantage is that the hardware cost is increased; the other is to use PA (Power Amplification) to increase the transmission power, which is relatively simple and low-cost. The latter is used in this design to expand the network coverage.
ZigBee devices can be divided into full-function devices (FFD) and reduced-function devices (RFD). FFD can communicate with RFD or FFD, while RFD can only communicate with FFD; FFD can be used as a network coordinator, router or terminal device, while RFD can only be used as a terminal device. In this system, the network coordinator and the monitoring computer are connected through the RS485 bus, which is responsible for establishing, managing and maintaining the network, controlling other nodes to receive data and other functions. The router is connected to the photovoltaic charger through the RS485 bus to collect and control its data, and the terminal node receives the command from the monitoring computer to control the switch of the street lamp power supply. The ZigBee network topology supports star, tree and mesh. To simplify the design, the wireless network adopts a tree network topology, and the system composition is shown in Figure 1.
The monitoring computer is responsible for photovoltaic data collection and system management, and communicates with the network coordinator installed outdoors through the RS485 bus. The photovoltaic charger data is transmitted to the router node through the RS485 bus, and then forwarded to the monitoring computer by the coordinator. The router also serves to extend the transmission distance of the ZigBee network. The monitoring computer sends commands to the router through the network coordinator to realize the switching control of the charger power switch. After the street lamp power supply cable is powered on, the terminal node joins the ZigBee network. The network coordinator checks the terminal node and transmits the node status to the monitoring computer. The monitoring computer sends commands to each terminal node through the network coordinator to control the power switch of each node street lamp to turn on or off, thereby realizing the individual or segmented lighting control of the street lamp. When it is necessary to achieve the landscape lighting effect, the corresponding control commands can be sent to each terminal node through the monitoring software design.
2 Hardware Node Design
Considering that the functions of each node in the wireless communication system are not exactly the same, the hardware part is modularized to facilitate hardware design and reduce costs. The core part of the node is the ZigBee communication module, which is designed to be responsible for RF transmission and reception only. The other parts are composed of street light switch module, power supply and RS485 communication module. The wireless communication module uses the ultra-low power SoC chip CC2430 that supports the ZigBee protocol. The chip integrates ZigBee RF front end, memory and microcontroller, with an 8-bit enhanced 8051 MCU, 128KB programmable flash memory and 8 KB RAM. It also contains A/D converter, timer, AESl28 coprocessor, watchdog timer, sleep mode timer, power-on reset circuit, power-off detection circuit and 21 programmable I/O pins. TI provides free ZigBee protocol stack, which can easily complete the hardware and software design of the system.
2.1 ZigBee communication module hardware design
Figure 2 is the schematic diagram of the ZigBee communication module. Field tests have shown that due to the long distance between the network coordinator and other nodes, network data transmission is unstable when only CC2430 is used. In order to extend the communication distance of the wireless communication module, TI's high-performance RF front-end CC2591 is used. CC2591 can provide 22 dBm output power and can be seamlessly connected to CC2430. No additional matching network is required between the RF input/output. For simplicity, the power supply and decoupling circuit, GPIO, JTAG and other parts are not shown in the figure. The spare pins are led out through the socket to connect with other modules.
The HGM pin of CC2591 is gain control. When it is high, it is in high gain mode. When EN and PAEN are high, CC2591 works in normal mode, and enters low power mode when they are low. R1 and R2 are bias resistors, which provide appropriate working current for the crystal oscillator. The antenna uses a 50 Ω whip antenna. Since the ZigBee module works in the 2.4 GHz frequency band, it has high requirements for PCB design. The PCB board, component packaging, layout and wiring must refer to the reference design of TI. In particular, the antenna impedance matching part should directly use the GERBER file provided by TI in the wiring, and copy its PCB wiring method to ensure the high performance and stability of CC2591. In addition, the power decoupling and grounding treatment of PCB are also very important. The decoupling capacitor should be as close to the power pin as possible. The spare part of the PCB needs to be copper-clad and grounded, and the top and bottom copper clads should be connected with vias at a certain interval.
2.2 Coordinator and router hardware design
Since both the coordinator and the router need to communicate over long distances with other devices via the RS485 bus, it is necessary to design an RS485 communication module to connect to the ZigBee communication module. The communication module is implemented using MAX485 and an optocoupler. MAX485 completes RS485 transceiver control through the PO.5 pin of CC2430. The CC2430 power supply is powered by chips such as LTlll7-3.3. In the ZigBee protocol, the network coordinator is responsible for establishing the network and implementing functions such as routing control, so it must remain in working condition to ensure the reliability and stability of data acquisition. In this system, the network coordinator and router are powered by an external AC power supply when they are working normally. When the external AC power supply is powered off, the power supply is switched through the microprocessor monitoring chip ADM690, and the battery pack is used to power it to ensure the stable operation of the network. ADM690 has the characteristics of low power consumption, low on-resistance and large current output, which is very suitable for realizing the battery backup function of the microprocessor. The circuit design is shown in Figure 3. Among them, R1 is a charging current limiting resistor, which can trickle charge the battery when the external power supply is normal.
2.3 Terminal Node Hardware Design
The function of the terminal node is to receive the command sent by the coordinator to control the street light switch. Its power supply is provided after the monitoring computer sends a command to the photovoltaic charger to power the street light power supply cable. Therefore, the hardware part does not need a battery backup function. The power supply voltage in the photovoltaic lighting system is 220 V DC. The terminal node power supply part uses a DC-DC switching power supply to generate a 5 V DC power supply. The street light switch control is realized through the GPIO and transistor control relay of CC2430. Since only pins P1.0 and P1.1 of CC2430 have a driving capability of 20 mA, and the maximum driving current of other pins is 4 mA, SN74HC04D is used as an output buffer. Its schematic diagram is shown in Figure 4.
3 System Software Design
The system software mainly includes ZigBee coordinator node program, router node program, terminal node program and monitoring computer program. The monitoring computer program realizes the monitoring and data processing of the photovoltaic lighting system, the on-off control of LED street lights, and the data collection and monitoring of another photovoltaic power generation system and environmental monitoring system connected to it. The monitoring computer communicates with the coordinator node in binary coding, sending a collection command every 5 seconds. The data packet format is as follows:
Among them, the data packet header (HEADER) occupies 2 bytes and can be set to 0x81 or 0x82 to distinguish whether it is a computer data packet output or data packet input; the data length (LENGTH) is 1 byte; the command type includes charger data collection, street light switch status collection, environmental parameter collection, etc.; the number of data bytes is specified by LENGTH; the data CRC check occupies 1 byte.
The ZigBee node program is written based on the ZStack-1.4.3-1.2.1 protocol stack provided by TI, which can realize network establishment, node joining and exiting, data transmission and other functions. The protocol stack separates the application layer and the stack layer, and provides an operating mechanism similar to the operating system (OSAL) (mainly including task registration, initialization, startup, message exchange between tasks, task synchronization, interrupt processing, time management and memory allocation, etc.), which has good portability.
The node program flow is shown in Figure 5. After the hardware and each layer of the protocol stack are initialized, the finite state machine is used to process the events in an event polling manner. If several events occur at the same time, they are processed one by one after judging the event priority. The protocol stack provides a wealth of API functions for users to call, and this software architecture can easily construct user applications. Since the power supply to the terminal node is controlled by the photovoltaic charger according to the command of the monitoring computer, under normal circumstances, the terminal node will add people and leave the network every day.
There are two addressing methods for communication between ZigBee nodes, one is to find network devices through a fixed 64-bit IEEE address and the other is to find network devices through a 16-bit network address. When a node joins a ZigBee network, it can randomly obtain a unique 16-bit network address through the coordinator. The photovoltaic lighting system requires that the street lamps can be turned on or off according to their numbers, and the IEEE address must be used to communicate with specific nodes. Therefore, the 64-bit IEEE address of the ZigBee node is manually allocated using the SmartRF software provided by TI. The coordinator uses the AF_DataReqt-lest() function to transmit data to the terminal node. This function requires the node's network address as a parameter. The function of obtaining the 16-bit network address through the IEEE address is implemented by the NLME_GetShortAddr() function. In the program design, the tasks required by the user are added to the application layer to process the received events. The node needs to complete the following tasks when starting up: initialize CC2430 and protocol stack; help the coordinator node to establish the ZigBee network, set the network PAN ID, and wait for other nodes to join the network; parse and forward the commands sent by the monitoring computer; read the status data sent by the router and each terminal node, and forward it to the monitoring computer for processing.
When configuring the ZigBee device object (ZD0) endpoint, the endpoint ID and endpoint descriptor of all nodes in the network must be the same, otherwise the nodes cannot communicate with each other. The program flow in Figure 5 is mainly for user event processing (including serial port events, data transmission events, timer events, etc.). The program design flow of the router and the terminal node is similar. In the user event, they complete the charger status data collection and return, and the street light switch control according to the command type sent by the coordinator.
Conclusion
The ZigBee wireless network is used for photovoltaic lighting system control, which has the advantages of long communication distance, low cost, and easy maintenance. The total number of street lights controlled can reach 64, with a coverage range of more than 300 m, and can be further expanded. The system has been successfully applied to the Ministry of Construction's solar building application demonstration project and has passed the Ministry of Construction's acceptance.
Previous article:Application of Intelligent LED Control and Interface in Decorative Lighting
Next article:Practical LED desk lamp design
Recommended ReadingLatest update time:2024-11-16 17:56
- Popular Resources
- Popular amplifiers
- Wireless Sensor Network Technology and Applications (Edited by Mou Si, Yin Hong, and Su Xing)
- A review of learning-based camera and lidar simulation methods for autonomous driving systems
- Detailed explanation and engineering practice of unmanned monitoring technology (Xie Jianbin, Li Peiqin, Yan Wei, Liu Tong, Lin Chenglong, Hong Quanyi, Zhou Hongfei, Cui Yibing)
- Introduction to Wireless Sensor Networks (Edited by Ma Sasa et al.)
- MathWorks and NXP Collaborate to Launch Model-Based Design Toolbox for Battery Management Systems
- STMicroelectronics' advanced galvanically isolated gate driver STGAP3S provides flexible protection for IGBTs and SiC MOSFETs
- New diaphragm-free solid-state lithium battery technology is launched: the distance between the positive and negative electrodes is less than 0.000001 meters
- [“Source” Observe the Autumn Series] Application and testing of the next generation of semiconductor gallium oxide device photodetectors
- 采用自主设计封装,绝缘电阻显著提高!ROHM开发出更高电压xEV系统的SiC肖特基势垒二极管
- Will GaN replace SiC? PI's disruptive 1700V InnoMux2 is here to demonstrate
- From Isolation to the Third and a Half Generation: Understanding Naxinwei's Gate Driver IC in One Article
- The appeal of 48 V technology: importance, benefits and key factors in system-level applications
- Important breakthrough in recycling of used lithium-ion batteries
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- 2. Evaluation starts with lighting
- Slope compensation issues
- Controlled by "Playpad" + Siri + Shortcut Command + ESP8266
- Share the OS transplantation and application of Lingdong Micro MCU based on MM32 MCU-AMetal SPI operation
- Do you still buy electronic components offline? It’s Double 11, what goodies are in your shopping cart?
- 【TI Recommended Course】#Amplifier Protection Series#
- Battery and System Health Monitoring Reference Design for Battery-Powered Smart Flow Meters
- Who has used the voltage-to-PWM chip GP9101?
- Analog Multiplexer and Switch Configuration
- Build a "core" building together: front-line engineers talk about national chips, valid all year round (11 floors have been built)