The cumulative counter of the packaging line made using a single-chip microcomputer has the function of saving the count value after shutdown and controlling the start/stop of the conveyor belt motor. The circuit is simple, reliable and practical.
The microcontroller AT89C51 is the core of the circuit. It is responsible for counting, controlling motor operation and driving the 8-bit digital tube to display the count value. In the circuit, S1 is the motor start/stop button during normal operation. Clicking it can cause the relay to engage/release, thereby driving the packaging line conveyor belt motor to run/stop. S2 is the count value clearing key. Although the counting length of this circuit is up to 8 digits, some items may not be able to count this length in a year when packaging. However, setting the clearing key here can clear the counting value in time when needed. When shutting down, the 5V voltage output by IC2 drops rapidly, causing P3.2 to be low level. The microcontroller enters an interrupt, turns off the display and stops the motor in the interrupt service subroutine, and enters a power-down state at the same time. At this time, the on-chip oscillator is blocked, all functions are stopped, only the contents of the 00H~7FH units of the on-chip RAM are retained, and the output status of the port is saved in the corresponding SFR. In power-down mode, the Vcc of the microcontroller can be reduced to 2V, and the power consumption is only 50μA. The only way to exit power-down mode is a hardware reset. In order to improve the anti-interference ability, the two sets of power supplies V1 and V2 are obtained from the two windings of the secondary side of the transformer and then rectified and filtered, achieving complete electrical isolation. In addition, the output signal of P3.7 is isolated by the optocoupler U1 and then drives the relay KJ to act, also to prevent the interference signal at the output end from being reversely connected to the microcontroller.
When this circuit is used, the distance between the counting input terminal K1 and the microcontroller is less than 1m, so the input signal is directly sent to P3.1 after C9 filters out stray electromagnetic field interference. If the distance is longer, it can also be photoelectrically isolated. Then send it in later, the effect will be better. The source of the counting signal can be a micro switch, photointerrupter or proximity switch, etc.
The 3.6V/60mAH nickel-chromium battery in the circuit is used for data retention after shutdown. The power consumption is only 50μA. When the system is working, the 5V power supply is trickle charged through R3.
All reference designs on this site are sourced from major semiconductor manufacturers or collected online for learning and research. The copyright belongs to the semiconductor manufacturer or the original author. If you believe that the reference design of this site infringes upon your relevant rights and interests, please send us a rights notice. As a neutral platform service provider, we will take measures to delete the relevant content in accordance with relevant laws after receiving the relevant notice from the rights holder. Please send relevant notifications to email: bbs_service@eeworld.com.cn.
It is your responsibility to test the circuit yourself and determine its suitability for you. EEWorld will not be liable for direct, indirect, special, incidental, consequential or punitive damages arising from any cause or anything connected to any reference design used.
Supported by EEWorld Datasheet