当前位置:网站首页>Solar insect killing system based on single chip microcomputer
Solar insect killing system based on single chip microcomputer
2022-07-04 05:20:00 【biyezuopinvip】
Resource download address :https://download.csdn.net/download/sheziqiong/85881842
Resource download address :https://download.csdn.net/download/sheziqiong/85881842
【 pick want 】 With the development of vegetable and fruit planting , Some new pests are also emerging rapidly , Seriously affect the yield and quality of vegetables and fruits . Pest control , Promote agricultural production . however , The indiscriminate use and abuse of pesticides have caused pesticide residues in agricultural products to seriously exceed the standard , Greatly affect human health , Cause environmental pollution and damage .
The system adopts AT89S52 Single chip microcomputer as the main control chip of the system , Realize the charging control of solar panel to battery . meanwhile , The working state of the insecticidal lamp system is controlled by the temperature and humidity sensor , In low ambient temperature and rainy days , The system stops working , After the rain stopped , A rise in temperature , The system will return to work . Photoreceptors control insect killing lamps . During the day, you can turn on and off the lights to charge the battery , Discharge the light at night and turn on the light to kill insects .
【 key word 】 Single chip microcomputer ; The solar energy ; Insecticidal system ; Pest control system ;AT89S52
【Abstract】With the development of vegetable and fruit planting industry, some new diseases and pests have also developed rapidly, which seriously affects the yield and quality of vegetables and fruits; the rapid development of chemical industry, greatly meet the needs of farmers to control diseases and insects, promote the development of agricultural production.However, the indiscriminate use and abuse of pesticides lead to the serious excessive pesticide residues in agricultural products, which greatly affects human health and causes environmental pollution and damage. At the same time, the pests produce anti-drug resistance characteristics.
The system uses AT89S52 as the main control chip of the system to realize the charging control of the battery by solar panels.Meanwhile, the working state of the insecticide lamp system is controlled through the temperature and humidity sensor. Realize the function of the system stopping working with low ambient temperature and rainy days, the temperature recovery and the system recovery after the rain stops. And the use of photosensitive mistor to control the insecticide lamp light, to achieve the battery charging during the day, night battery discharge to make the lamp light insecticide.
【Key words】single-chip machine; solar energy; insecticide system; insect control system; AT89S52
Objective record
1. The introduction 1
1.1 Background and significance of the topic 1
1.2 Development status at home and abroad 1
1.2.1 Development status of insecticidal systems at home and abroad 1
1.2.2 Development status of solar photovoltaic at home and abroad 2
1.2.3 Development status and existing problems of solar insecticidal systems at home and abroad 3
1.3 The main contents of the study are 3
2. System structure and component selection 4
2.1 The solar insecticidal system consists of 4
2.2 Photovoltaic module selection 4
2.2.1 Working principle of photovoltaic power generation 4
2.2.2 Volt ampere characteristics of photovoltaic cells 5
2.3 Battery selection 6
2.3.1 Working principle of battery 6
2.3.2 Battery charging and discharging characteristics 6
2.3.3 Selection of battery 7
2.4 Capacity design of photovoltaic power generation system 8
2.4.1 Factors affecting capacity design 8
2.4.2 Battery capacity design 8
2.4.3 Photovoltaic array capacity design 8
3. Design of the controller of the solar insect killing lamp 10
3.1 The working principle of the solar insect killing lamp controller 10
3.1.1 Series charging and discharging controller 10
3.1.2 Parallel charging and discharging controller 11
3.2 AT89S52 Controller composed of single chip microcomputer 11
3.2.1 AT89S52 Introduction to the single chip microcomputer system 12
3.2.2 AT89S52 The minimum system design of single chip microcomputer 13
3.2.3 Charge discharge circuit 15
3.2.4 Voltage acquisition circuit 16
3.2.5 A/D Conversion circuit 17
3.2.6 Display circuit 18
3.2.7 Temperature and humidity acquisition module 20
3.2.8 Schematic diagram of the overall circuit of the controller 22
3.3 Software design of charge and discharge controller of solar insect killing lamp 22
3.3.1 The overall design idea of the controller 23
3.3.2 Daytime control process 24
3.3.3 Night control process 26
4. summary 27
reference 28
Appendix source code 29
name : Solar insecticidal system
IOT_Insecticidal_LampV4
note1:Make by MikeXUE
note2:20190411
note3: Module size :90mmX96mm Adopted standards 3mm Screw hole installation
note4:《! Open source hardware !》----- Buy finished motherboards in batches , It can provide customized source code modification services .
note5: Green agriculture Smart agriculture Wind suction insect killing lamp Frequency vibrating insect killing lamp Self cleaning insects Insecticidal count
One 、 Function Overview
◆ On board 12V Solar charging function , use “ Lithium battery solar charging management module ”
◆4G Communication capability
◆GPS/BD Positioning function
◆ Onboard air temperature and humidity detection function
◆ On board RTC Real time clock
◆ On board overcurrent protection function
◆ With raindrop detection and tilt detection
◆ With insect cleaning motor drive and limit detection function , And support current detection
◆ With high-pressure package or fan drive function , And support current detection ( Under the high-pressure package, insect cleaning and counting can be realized )
◆ It has the drive function of insect trap lamp , And support current detection
◆ Has a set 485 communication interface , It can be connected to an external screen or sensor
Two 、 Circuit Overview
1. The solar lithium battery management circuit adopts “ Lithium battery solar charging management module ”, Buckle to the motherboard . mandatory 3.3V The output unit is used for SCM 、RTC circuit 、485 Chip powered , controllable 3.3V The power supply is controlled by MCU , Supply power to external sensing devices , controllable 5V Corona is controlled by MCU , by 4G/ Positioning module power supply ;
2.485 Bus interface adopts SP3485E Combined with external protection circuit , Serial port with MCU 3, Default bit connection ;
3.4G Communications / The positioning adopts yinerda Core-N58 module ,UART Communications , Serial port with MCU 4,2 Sign connection ;
4. Tilt switch and light detection circuit adopt LM393 Comparison circuit composition , Among them, the light sensing detection cooperates with the adjustable resistance to adjust the light sensing sensitivity ;
5. Rain detection and bin door detection circuits are composed of dry contact circuits composed of optocoupler circuits ;
6. The air temperature and humidity sensor adopts DHT11 Single bus sensor ;
7.RTC Real time clock adopts PCF8563 constitute ;
8. Two hall sensor interfaces , use LM393 Comparison circuit composition , Adjust the induction sensitivity through adjustable resistance , The 2 A group of Hall sensors are used for the forward and reverse limit of the motor ;
9. The motor is driven by RZ Integrate mos Chip composition , The biggest support 3A Output , Support positive and negative . Its current sampling circuit adopts INA Series chip composition ;
10. High voltage package or fan drive circuit adopts PMOS+NMOS constitute , Its current sampling circuit adopts INA Series chip composition ;
11. The drive circuit of the insect trap lamp adopts PMOS+NMOS constitute , Its current sampling circuit adopts INA Series chip composition ;
12.LED1 Used for equipment work instructions ;
13.R47 Set the resistance for the mode , Enable after welding “ Self cleaning function ”, No welding, no “ Clear insect ” function ;
14.MCU Choose domestic low-end chips STC8A8K64S4A12_LQFP64S
15. Battery voltage 、 Panel voltage 、 The detection voltage of the driving working current is directly connected to MCU Of ADC port ;
16.KEY1 It is the power control button of single chip microcomputer , Press power off , Otherwise, the power supply is turned on , Used for resetting or burning programs ;
3、 ... and 、 Instructions
1.MD1 by “ Lithium battery solar charging management module ”, Directly buckle ,P13 Connect the solar panel (12V/100W),P14 Lithium battery interface ;
2.FUSE1 Pluggable fuse , choice 3A,FUSE1_1 by PPTC Patch self-healing fuse ,FUSE1、FUSE1_1 Weld any one of them ;
3.P9 It is the upper limit Hall sensor interface of the motor ;
4.P10 It is the lower limit Hall sensor interface of the motor ;
5.P8 For motor interface (12V), Don't answer ;
6.P7 High pressure package or fan interface (12V);
7.P6 It is the interface of insect trap lamp (12V);
8.P2 Interface for door proximity switch ( Don't answer );
9.P3 Is the raindrop detection port ;
10.P12 It is a photosensitive resistor interface ( Don't answer );
11.P11 Interface for tilt sensor ( Don't answer );
12.P4 by 485 Bus interface ( Don't use );
13.P1 Write interface for program ;
14.KEY1 To reset / Programming keys ;
int main(void)
{
/* Reset all peripherals , initialization Flash Interface and system tick timer */
HAL_Init();
/* Configure the system clock */
SystemClock_Config();
/* On board LED initialization */
LED_GPIO_Init();
/* Board key initialization */
KEY_GPIO_Init();
/* Infinite loop */
while (1)
{
if(KEY1_StateRead()==KEY_DOWN)
{
LED1_ON;
}
if(KEY2_StateRead()==KEY_DOWN)
{
LED2_ON;
}
if(KEY3_StateRead()==KEY_DOWN)
{
LED1_OFF;
LED2_OFF;
}
}
}
/** * The functionality : System clock configuration * Input parameters : nothing * return return value : nothing * say bright : nothing */
void SystemClock_Config(void)
{
RCC_OscInitTypeDef RCC_OscInitStruct;
RCC_ClkInitTypeDef RCC_ClkInitStruct;
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSE; // External crystal oscillator ,8MHz
RCC_OscInitStruct.HSEState = RCC_HSE_ON;
RCC_OscInitStruct.HSEPredivValue = RCC_HSE_PREDIV_DIV1;
RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSE;
RCC_OscInitStruct.PLL.PLLMUL = RCC_PLL_MUL9; // 9 frequency doubling , obtain 72MHz Master clock
HAL_RCC_OscConfig(&RCC_OscInitStruct);
RCC_ClkInitStruct.ClockType = RCC_CLOCKTYPE_HCLK|RCC_CLOCKTYPE_SYSCLK
|RCC_CLOCKTYPE_PCLK1|RCC_CLOCKTYPE_PCLK2;
RCC_ClkInitStruct.SYSCLKSource = RCC_SYSCLKSOURCE_PLLCLK; // The system clock :72MHz
RCC_ClkInitStruct.AHBCLKDivider = RCC_SYSCLK_DIV1; // AHB The clock :72MHz
RCC_ClkInitStruct.APB1CLKDivider = RCC_HCLK_DIV2; // APB1 The clock :36MHz
RCC_ClkInitStruct.APB2CLKDivider = RCC_HCLK_DIV1; // APB2 The clock :72MHz
HAL_RCC_ClockConfig(&RCC_ClkInitStruct, FLASH_LATENCY_2);
// HAL_RCC_GetHCLKFreq()/1000 1ms Break once
// HAL_RCC_GetHCLKFreq()/100000 10us Break once
// HAL_RCC_GetHCLKFreq()/1000000 1us Break once
HAL_SYSTICK_Config(HAL_RCC_GetHCLKFreq()/1000); // Configure and start the system tick timer
/* System tick timer clock source */
HAL_SYSTICK_CLKSourceConfig(SYSTICK_CLKSOURCE_HCLK);
/* System tick timer interrupt priority configuration */
HAL_NVIC_SetPriority(SysTick_IRQn, 0, 0);
}






Resource download address :https://download.csdn.net/download/sheziqiong/85881842
Resource download address :https://download.csdn.net/download/sheziqiong/85881842
边栏推荐
- 简单g++和gdb调试
- Zhongke Panyun - module a infrastructure setting and safety reinforcement scoring standard
- Zkevm (12) state proof of appliedzkp
- Roles of rollup components
- 2022 question bank and answers for safety management personnel of hazardous chemical business units
- Zzulioj:1201: mode problem
- 2022年T电梯修理操作证考试题库及模拟考试
- 中科磐云—2022广东木马信息获取解析
- [technology development -25]: integration technology of radio and television network, Internet, telecommunication network and power grid
- 定制一个自己项目里需要的分页器
猜你喜欢

The data mark is a piece of fat meat, and it is not only China Manfu technology that focuses on this meat
![[QT] timer](/img/df/5db6af851ef19f33fd7e7a7ed46586.png)
[QT] timer

Programming example of stm32f1 and stm32subeide -74hc595 drives 4-bit 7-segment nixie tube

C语言简易学生管理系统(含源码)

空洞卷积、可变形卷积、可变形ROI Pooling

2022 question bank and answers for safety management personnel of hazardous chemical business units

Customize a pager needed in your project

National vocational college skills competition (secondary vocational group) network security competition questions - Analysis

Secondary vocational group network security - memory Forensics

Useful plug-ins for vscode
随机推荐
基于单片机的太阳能杀虫系统
Graduation design of small programs -- small programs of food and recipes
Annex II: confidentiality agreement for offensive and defensive drills docx
Thread pool: use thread pool to optimize query speed
模拟小根堆
Headache delayed double deletion
Nodejs learning document
ping端口神器psping
Electronic components mall and data manual download website summary
2022 t elevator repair operation certificate examination question bank and simulation examination
Trie数-字典树
TCP state transition diagram
How to build your own knowledge engine? Community open application
Li Kou's 300th weekly match
Enterprise level log analysis system elk (if things backfire, there must be other arrangements)
[matlab] communication signal modulation general function interpolation function
NTFS security permissions
力扣 第 300 场周赛
[matlab] matlab simulation of modulation system - power spectrum and coherent demodulation of AM modulated signal
拓扑排序和关键路径的图形化显示