Intelligent lighting and real-time solar tracking power management system

Publisher:EtherealLightLatest update time:2013-06-15 Source: eepwKeywords:Fusion  PWM Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere
Introduction

Solar energy is a resource-rich, pollution-free energy alternative. How to improve its utilization rate has gradually become the research focus of various countries. The utilization of solar energy has the following problems: First, although solar energy is rich in resources, its energy is dispersed, and the energy concentrated at a certain point is less. At the same time, the directionality of solar energy determines that it is impossible to obtain a large amount of energy in a fixed direction for a long time; second, solar energy is restricted by environmental conditions. Only when the sunlight is good during the day can stable solar energy be obtained; third, the conversion efficiency of solar panels is not high. At present, the highest conversion efficiency of solar panels in the world is only 30%, while the conversion efficiency used in China is mostly around 20%. This project mainly focuses on the problem of low utilization rate of solar energy. It uses the solar positioning algorithm and the photoresistor sensor feedback method, and coordinates the control of the motor through the Fusion series single-chip mixed analog and digital FPGA to drive the solar panel to track the sun in real time to improve the utilization rate of solar energy. Subsequently, the battery is intelligently charged and the power management is performed through the FPGA's PWM module. Finally, the weather and power status information are displayed in the LCD unit of the development board, and the relevant information is timely fed back to the PC through the serial port.

1 System Design

1.1 Overall System Design


This system is mainly composed of four parts: central processing unit, intelligent lighting, power management and host computer software. The system mainly realizes the improvement of solar energy utilization, solar energy conversion and storage, and UPS function. This design also provides detection and management of the system.

As shown in Figure 1, the system includes a control processing unit, a power management unit, a power supply and transmission unit (including solar panels, batteries, mains power, and power output interfaces), an interface unit, an LCD display unit, a button, an indication and alarm unit, a stepper motor drive unit and a lighting unit. Using FPGAAFS600 as the control processing unit, data acquisition, processing, motor drive control and power management unit control are mainly realized through Verilog HDL hardware logic and cote51 soft core. The lighting unit and the stepper motor drive unit mainly realize the functions of collecting light intensity data and controlling mechanical transmission to change the orientation of the solar panel. The power management unit and the power supply and transmission unit realize the battery charging/power supply switching, the mains power supply and battery power supply switching, the solar charging/power supply switching, and the power conversion output.


1.2 Design of intelligent lighting

The system provides two ways to track the sun's position: photoresistor array adaptive control algorithm and positioning tracking algorithm. The photoresistor array adaptive control algorithm is the core, and the positioning tracking algorithm is used as an auxiliary correction. These two methods are organically combined to enhance the robustness and anti-interference of the system, making it better suited to various environments.

1.2.1 Photoresistor array

Photoresistors are resistive sensors. When the intensity of the light they receive changes, their resistance value changes accordingly, and they can convert light signals into electrical signals.

(1) Array layout design

As shown on the right side of Figure 2, P1 to P8 are photoresistors, which are arranged in the east, south, west, and north directions inside and outside the cylinder respectively. P1~P4 are exposed, and the east-west symmetrical pair (P1, P3) is used to roughly detect the solar azimuth angle θA; the other pair (P2, P4) is used to roughly detect the solar incident angle θZ; P5~P8 are inside the cylinder, and the east-west symmetrical (P5, P7) is used to accurately detect the solar azimuth angle θA; the other pair (P6, P8) is used to accurately detect the solar incident angle θZ. The lighting board is equipped with a protective cylinder, which can largely shield the scattered light and other interfering light from the external environment, so that the influence of the external interfering light source on the tracking effect is reduced to a minimum, and the tracking accuracy is improved.

(2) Tracking Principle

The four photoresistors P1 to P4 arranged outside can reflect the current weather conditions, such as cloudy, sunny or dark, so as to determine whether the solar panel needs to be adjusted; the four photoresistors P5 to P8 arranged inside are used to finely adjust the orientation of the solar panel.

When the sunlight deviates from the vertical direction by a small angle, the external photoresistors will not reflect the changes in sunlight due to the influence of ambient scattered light; while the internal photoresistors are shielded by the cylinder from ambient scattered light, and the illumination they receive will have a difference, that is, the deviation signal. When the sunlight deviates by a large angle (rainy days, after dark clouds, or alternation of day and night), the photoresistors inside the cylinder may not receive sunlight, and the photoresistors outside the cylinder can reflect the illumination difference. The control unit controls the adjustment of the angle of the sunlight receiving device by further judging and processing the signal until the solar panel is aligned with the sun. The detailed adaptive tracking process is shown in Section 2.2.

(3) Selection of design parameters

It is roughly assumed that the sun rotates 360° in 24 hours. The design index of this system is to track once every half an hour, so the tracking sensitivity is 7.5°, that is, when the sun deflects 7.5° (θ=7.5°), the photoresistor P5 is blocked, while P7 can be illuminated by light. At this time, the lighting board needs to be adjusted to track the direction of the sun.

According to the layout requirements of the actual object, the diameter of the barrel is set to D=5 cm and S=0.5 cm. Therefore, the distance between the internal sensors is L=(5-2×0.5)=4 cm. After the above parameters are selected, according to H=S/tan(θ), that is, H=S/tan(2 7c×7.5/360), S=0.5 cm is substituted, and finally H=3.79 cm is obtained. In practice, considering the scattering and interference of light, the height of the barrel is selected as 6 cm.

1.2.2 Positioning and tracking algorithm

Since the earth rotates once in 24 hours, it can be roughly assumed that the sun shifts 15° (360°/24) from east to west every hour. Let the hour angle be ω, the magnetic declination (declination angle) be э, the solar incidence angle (zenith angle) be θZ, the solar azimuth angle be θA, and φ be the local latitude. After calculation, it is obtained that:




According to formulas (1) and (2), considering that Nanjing's longitude is e118.77, latitude is n32.0, and the altitude is below 50 m, and referring to the large number estimation algorithm and related correction parameters, the solar azimuth and altitude angle are calculated in Matlab. Since this calculation is complex and huge, it will consume a lot of FPGA resources and is not conducive to running under the FPGA's 51 soft core. Considering that this system is only for Nanjing area, the changes in altitude and latitude are ignored in terrain, and the changes in time zone and minutes are ignored in time. The program is simplified again in Keil C, and the data obtained by the previous and subsequent algorithms and the actual measurement data are compared to draw curves, as shown in Figure 3.

 

Figure 3 is drawn based on the solar zenith angle θZ and azimuth angle θA of Nanjing every hour from 8:25 to 16:25 on February 19, 2008, and the corresponding values ​​actually measured. The left figure shows the trajectory of the solar azimuth angle (θA) deflecting from east to west over time; the right figure shows the trajectory of the solar altitude angle (90-θZ) over time. By comparison, it is proved that the simplification of Keil C does not bring obvious trajectory deviation, and the trajectory obtained by the positioning algorithm is basically consistent with the actual measurement trajectory. In this way, it is possible for the system to achieve sun tracking by calculating the solar azimuth by itself. The curve in the figure also shows that for the solar azimuth and altitude angle, the calculated values ​​are generally larger than the measured values, which is mainly caused by the refraction of sunlight by the atmosphere and the measurement error. In actual debugging, certain corrections can be made to improve the sun tracking effect.

2 System process design and simulation test

2.1 System process design


This system adopts the front-end and back-end system. The main program is an infinite loop, in which the corresponding operations are completed by calling the corresponding functions, and the key operations with a strong relationship with time are completed through interrupt processing. The main program software flow is shown in Figure 4.

The core51 core of the FPGA is used as the core of the control processing unit. The AD module with analog function is used to process and analyze the data of multiple AD samples. The gate driver core is configured by the core51 core to output the pulse signal of the motor drive to realize the mechanical drive of the system lighting, thereby adjusting the position of the solar panel. Since the change of sunlight is relatively slow, the main factors affecting the data acquisition accuracy of this system are the error of AD conversion itself and the instantaneous strong light interference. The system uses the 51 core to smooth the AD input data by software. The FPGA

also provides users with a programmable pulse width modulation (PWM) core, that is, the period and duty cycle of the output pulse can be changed by software. The PWM module provides PWM_addr and PWM_data input signals for modifying the period and duty cycle of the PWM waveform. Through the configuration of the core51 core, the PWM core outputs the PWM control signal to realize the control of battery charging. Finally, the weather and battery status information are displayed in real time on the LCD and fed back to the PC through the serial port.

2.2 Adaptive lighting positioning process design

For the convenience of implementation, the detailed process of tracking the sun in the east-west direction of this system is shown in Figure 5 (the tracking principle in the north-south direction is the same). The system first collects the voltages of 4 external photoresistors and 2 internal photoresistors in the east-west direction through AD. The external 4 channels are compared with the set threshold to determine the current weather conditions. If the sampling value is lower than the threshold of the night for 3 consecutive times, it is considered to be night and the system will stop working. If it is judged to be cloudy, the system controls the solar panel to keep its position unchanged. If it is sunny, it is judged according to the difference in the voltage of the two internal photoresistors. When the difference is greater than the set threshold, it is considered that the position of the solar panel needs to be adjusted. The adjustment principle is: if the voltage value on the east side is greater than that on the west side, the solar panel will rotate 1.8° to the east; otherwise, it will rotate 1.8° to the west. After adjustment, return to data collection and repeat the above process. The system's calculation of the solar azimuth angle can be used as a backup and supplementary correction solution. That is, when the photoresistor is damaged or the light-collecting circuit fails, the collected data will be abnormal (for example, it will be 0 for a long time or the voltage is too high). The host computer can send commands and use the results of the positioning algorithm to adjust the azimuth of the solar panel.

Repeatedly tested and improved the shading effect in different environments, the thresholds of the internal resistance sampling voltage to distinguish sunny days, cloudy days and nights are 6.1 V, 5.8 V and 0.1 V respectively (powered by 6.2 V power supply); when the sunlight deviates from a certain angle, the voltage difference generated by the internal resistance due to the shading tube is about 1 V; during the day, the external resistance sampling voltage fluctuation caused by the sudden strong light is about 0.2 V. By changing the threshold of the internal resistance sampling voltage difference, it is found that if the threshold voltage is too low, the motor will rotate too sensitively and waste electricity; if the threshold voltage is too high, it will not be able to track the sun in real time. Finally, the threshold is set to 0.8 V to achieve the best effect.

2.3 AD simulation

Since AFS600 has 16 12-bit ADs, 5 bits are used to represent the channel number and 12 bits are used to represent the corresponding data. In the design of data exchange between AD data and core51, a 3-byte transmission method is adopted to divide the 17-bit data into high, middle and low bytes and transmit them to core51 respectively. The test stimulus and simulation results are shown in Figure 6.


av_0 is channel 1, r_clk is the read command port of core51, and 3 bytes of data are read at a time when data is valid (DATAVALID generates a pulse). First, convert the hexadecimal sampled data into decimal, divide it by 4 095 and multiply it by 8, ([D(0x9 c4)/4 095]×8), and the calculated result is 4.88 V, while the actual value is 5 V, with an error of 2.4%. av_1 is channel 4, and the conversion result is 2.91 V in the same way, while the actual value is 3 V, with an error of 3%.

2.4 Host computer software

The host computer software includes two modules: the display module, which is responsible for refreshing the status and data on the interface; the communication module, which communicates with the MCU, and puts the communication results into the host computer memory, and calls the display module to refresh the interface. After the host computer software is connected to the MCU through the serial port, if there is no command to transmit the latitude, longitude and time information, the host computer requests data from the single-chip computer once every 3 seconds; if there is a command to transmit the latitude, longitude and time information, the command will be sent first. After any command is sent to the MCU, if there is no response from the MCU within 1 second, it is judged that the connection has been disconnected.

Conclusion

Although the design and debugging of this system are only in the experimental stage, it can basically achieve the predetermined functions, and the obtained data and debugging results will provide valuable experience for related research. At present, there are still areas that need to be improved: first, considering that the system can still work normally in rainy weather, the protection of the light tube needs to be improved; second, the design of the solar tracking mechanical device should be improved to improve the accuracy, stability and energy saving of the device; third, this system only realizes the tracking of the sun in the east-west direction, and the tracking in the north-south direction needs further improvement.

This system can significantly improve the conversion and utilization performance of solar energy with a little cost, and has good scalability; it can also be widely used in the fields of automobiles, homes, public places and industrial sites in combination with specific backgrounds.

Keywords:Fusion  PWM Reference address:Intelligent lighting and real-time solar tracking power management system

Previous article:Research on Fully Digital DC-DC Converter
Next article:Design of a multifunctional engine speed simulator

Recommended ReadingLatest update time:2024-11-16 22:36

PIC PWM module learning experience
Today we are making an ultrasonic distance measurement module, using SONY's CX20106A to process the received signal, which requires a standard 40KHz square wave. We plan to use the PIC's built-in PWM module to make a 40KHz square wave. PWM has been used before, but it was just a common PWM output signal to control var
[Microcontroller]
Embedded ARM Learning Summary (V) --RTC-TIME-PWM-Watchdog-AD-TP
RTC Commonly used RTC modules: PCF8563 IIC Interface DS302 SPI Interface DS87887 has many functions but is more expensive BCD code: Decimal number Compressed BCD code, a BCD code from 0 to 9 requires 4 bits of binary storage For example, 0X59 means 59 seconds (directly the BCD value, i.e. decimal number) Tim
[Microcontroller]
STM32 receives serial port data and outputs PWM
#include #include "sys.h" #include "usart.h" #include "delay.h" #include "led.h"  #include "key.h" #include "exti.h" #include "wdg.h" #include "timer.h" #include "string.h"   //Mini STM32 development board example code 8 //PWM output experiment //Atom on point @ALIENTEK //Technical forum: www.openedv.com    //#def
[Microcontroller]
Diodes Corporation launches boost/SEPIC controller to achieve 50kHz LED wide PWM dimming in automotive lighting product applications
Diodes Corporation (Diodes) has launched a boost/single-ended primary inductor converter (SEPIC) controller suitable for various automotive LED product applications. The AL8853AQ is an automotive-qualified, highly integrated boost/SEPIC controller that reduces the bill of materials (BOM) of automotive LED product app
[Automotive Electronics]
Diodes Corporation launches boost/SEPIC controller to achieve 50kHz LED wide PWM dimming in automotive lighting product applications
msp430 PWM period calculation
example:   P4DIR |= BIT1+BIT2+BIT3;                  // P4.1 - P4.3 output   P4SEL |= BIT1+BIT2+BIT3;                  // P4.1 - P4.3 TBx options      TBCCR0 = 512-1;                           // PWM Period   TBCCTL1 = OUTMOD_7;                       // CCR1 reset/set   TBCCR1 = LightCDPM;                       // CCR
[Microcontroller]
Inventory: Detailed explanation of five switching power supply PWM feedback control modes
  The basic working principle of PWM switching voltage or current stabilization power supply is that when the input voltage changes, the internal parameters change, and the external load changes, the control circuit performs closed-loop feedback through the difference between the controlled signal and the reference
[Power Management]
Inventory: Detailed explanation of five switching power supply PWM feedback control modes
11.STC15W408AS MCU CCP/PCA/PWM Application
The STC15W408AS MCU integrates 3-way programmable counter array (CCP/PCA) modules that can be used for software timer, external pulse capture, high-speed pulse output and pulse width modulation (PWM) output. 1. Special function registers related to CCP/PWM/PCA applications STC15 Series 1T 8051 MCU CCP/PCA/PWM Specia
[Microcontroller]
11.STC15W408AS MCU CCP/PCA/PWM Application
Cascading of Buck-Boost PWM DC/DC Converters
Using the three most basic PWM converters, in addition to deriving new converters using an evolutionary approach, new converters can also be derived using a cascade approach. After combining the two Buck-Boost circuits, a single-switch Buck-Boost cascade can be obtained, and its evolution process is shown in th
[Power Management]
Cascading of Buck-Boost PWM DC/DC Converters
Latest Power Management Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号