stc89c52 pin diagram and stc89c52 microcontroller pin function description
Source: InternetPublisher:通通 Updated: 2021/03/31
stc89c52rc is a low-power, high-performance CMOS 8-bit microcontroller produced by STC Company. It has an 8K-byte system programmable and erasable read-only memory. Let's take a look at the stc89c52 pin diagram and the pin functions of the stc89c52 microcontroller .
stc89c52 pin diagram
stc89c52 pin function description
1. Main power supply pins VCC and VSS
The power supply VCC is connected to +5V, and VSS is connected to the ground terminal, which is the common reference ground.
2. Clock circuit pins XTAL1 and XTAL2
There is an inverting amplifier inside the STC89C52 chip. XTAL1 is the input terminal of the amplifier; XTAL2 is the output terminal of the amplifier and the input terminal of the internal clock generator.
When using the self-oscillation mode, XTAL1 and XTAL2 are externally connected to a quartz crystal oscillator , and the internal oscillator oscillates according to the crystal oscillator frequency to generate a clock signal.
3.Control signal pin
(1)RST——Reset input. When the oscillator is working, a high level on the RST pin for more than two machine cycles will reset the microcontroller.
(2) ALE/PROG - When accessing external program memory or data memory, the ALE (address latch enable) output pulse is used to latch the lower 8-bit byte of the address. Under normal circumstances, ALE still outputs a fixed pulse signal at 1/6 of the clock oscillation frequency, so it can output a clock externally or be used for timing purposes. Note: An ALE pulse will be skipped whenever external data memory is accessed. (generally not used)
(3) PSEN - Program storage enable (PSEN) output is the read strobe signal of the external program memory. When the STC89C52 fetches instructions (or data) from the external program memory, PSEN is valid twice per machine cycle, that is, two outputs are pulse, during which the PSEN signal will be skipped twice when accessing external data memory.
(4) EA/VPP - External access is allowed. To enable the CPU to only access the external program memory (address 0000H-FFFFH), the EA terminal must remain low (grounded). It should be noted that if the encryption bit LB1 is programmed, the EA terminal status will be latched internally during reset. If the EA terminal is high level (connected to the Vcc terminal), the CPU executes the instructions in the internal program memory. When programming FLASH memory, add +12V programming permission power Vpp to this pin. Of course, this must be that the device uses 12V programming voltage Vpp.
(5) Parallel I/O port P0~P3 pins
①P0 port (P0.0~P0.7) 8-bit drain switching bidirectional I/O port. It can be used as a general-purpose I/O port, but a pull-up resistor must be added.
②P1 port (P1.0~P1.7) is an 8-bit quasi-bidirectional I/O port with internal pull-up resistor.
③P2 port (P2.0~P2.7) is an 8-bit quasi-bidirectional I/O port with internal pull-up resistor.
④P3 port (P3.0~P3.7) is an 8-bit multi-functional bidirectional I/O port with internal pull-up resistor.
The above is the stc89c52 pin diagram and stc89c52 pin function description. I hope it will be helpful to everyone.
- Car ice warning circuit sharing
- What are the challenges in designing a permanent magnet linear generator?
- How to set up a cheap beam break sensor control distance scene using a reflector
- Squirrel cage asynchronous motor reverse braking control circuit
- Using P110C to control 6 DC motors simultaneously
- Design and analysis of the principle of automatic power-off switch during power outage
- Hydraulic control circuit design and analysis
- Electric vehicle battery charging protection circuit
- Bicycle anti-theft alarm
- Vibration anti-theft alarm circuit
- fire smoke control circuit
- Mobile phone camera flash control circuit
- Switching regulated power supply circuit
- Water dispenser double sheet control circuit
- Assembly line outage monitoring circuit
- 24h automatic switching capacitor control circuit
- Digital current loop control circuit
- Relay control circuitb
- Forward and reverse control circuit of micro DC motor a
- Power supply circuit with multiple outputs (MAX1902)