【正文】
”Turn VCC power offChip Erase: The entire PEROM array (2K bytes) and thetwo Lock Bits are erased electrically by using the properbination of control signals and by holding low for10 ms. The code array is written with all “1”s in the ChipErase operation and must be executed before any nonblankmemory byte can be reprogrammed.Reading the Signature Bytes: The signature bytes areread by the same procedure as a normal verification oflocations 000H, 001H, and 002H, except that and must be pulled to a logic low. The values returned areas follows.(000H) = 1EH indicates manufactured by Atmel(001H) = 21H indicates 89C2051Programming InterfaceEvery code byte in the Flash array can be written and theentire array can be erased by using the appropriate binationof control signals. The write operation cycle is selftimedand once initiated, will automatically time itself topletion.All major programming vendors offer worldwide support forthe Atmel microcontroller series. Please contact your localprogramming vendor for the appropriate software revision.Flash Programming and Verification CharacteristicsTA = 0176。C to 70176。C, VCC = 177。 10%Note: 1. Only used in 12volt programming mode.Flash Programming and Verification WaveformsAbsolute Maximum Ratings*External Clock Drive WaveformsExternal Clock DriveSerial Port Timing: Shift Register Mode Test ConditionsVCC = 177。 20%。 Load Capacitance = 80 pFShift Register Mode Timing WaveformsAC Testing Input/Output Waveforms(1)Note: 1. AC Inputs during testing are driven at VCC for alogic 1 and for a logic 0. Timing measurementsare made at VIH min. for a logic 1 and VIL max. for a logic 0.Float Waveforms(1)Ordering InformationPackaging Information1. IMP813L8bit Microcontroller with 2K Bytes Flash AT89C2051Features? Compatible with MCS51? Products? 2K Bytes of Reprogrammable Flash Memory– Endurance: 1,000 Write/Erase Cycles? to 6V Operating Range? Fully Static Operation: 0 Hz to 24 MHz? Twolevel Program Memory Lock? 128 x 8bit Internal RAM? 15 Programmable I/O Lines? Two 16bit Timer/Counters? Six Interrupt Sources? Programmable Serial UART Channel? Direct LED Drive Outputs? Onchip Analog Comparator? Lowpower Idle and Powerdown ModesDescriptionThe AT89C2051 is a lowvoltage, highperformance CMOS 8bit microputer with2K bytes of Flash programmable and erasable read only memory (PEROM). Thedevice is manufactured using Atmel’s highdensity nonvolatile memory technologyand is patible with the industrystandard MCS51 instruction set. By bining aversatile 8bit CPU with Flash on a monolithic chip, the Atmel AT89C2051 is a powerfulmicroputer which provides a highlyflexible and costeffective solution to manyembedded control applications.The AT89C2051 provides the following standard features: 2K bytes of Flash, 128bytes of RAM, 15 I/O lines, two 16bit timer/counters, a five vector twolevel interruptarchitecture, a full duplex serial port, a precision analog parator, onchip oscillatorand clock circuitry. In addition, the AT89C2051 is designed with static logic for operationdown to zero frequency and supports two software selectable power savingmodes. The Idle Mode stops the CPU while allowing the RAM, timer/counters, serialport and interrupt system to continue functioning. The powerdown mode saves theRAM contents but freezes the oscillator disabling all other chip functions until the nexthardware reset.Pin ConfigurationPin DescriptionPort 1 Port 1 is an 8bit biirectional I/O port. Port pins to provide internal pullups. and require externalpullups. and also serve as the positive input(AIN0) and the negative input (AIN1), respectively, of theonchip precision analog parator. The Port 1 outputbuffers can sink 20 mA and can drive LED displays directly.When 1s are written to Port 1 pins, they can be used asinputs. When pins to are used as inputs and areexternally pulled low, they will source current (IIL) becauseof the internal pullups.Port 1 also receives code data during Flash programmingand verification.Port 3Port 3 pins to , are seven biirectional I/Opins with internal pullups. is hardwired as an input tothe output of the onchip parator and is not accessibleas a general purpose I/O pin. The Port 3 output buffers cansink 20 mA. When 1s are written to Port 3 pins they arepulled high by the internal pullups and can be used asinputs. As inputs, Port 3 pins that are externally beingpulled low will source current (IIL) because of the pullups.Port 3 also serves the functions of various special featuresof the AT89C2051 as listed below:Port 3 also receives some control signals for Flash programmingand verification.RSTReset input. All I/O pins are reset to 1s as soon as RSTgoes high. Holding the RST pin high for two machinecycles while the oscillator is running resets the device.Each machine cycle takes 12 oscillator or clock cycles.Oscillator CharacteristicsXTAL1 and XTAL2 are the input and output, respectively,of an inverting amplifier which can be configured for use asan onchip oscillator, as shown in Figure 1. Either a quartzcrystal or ceramic resonator may be used. To drive thedevice from an external clock source, XTAL2 should be leftunconnected while XTAL1 is driven as shown in Figure 2.There are no requirements on the duty cycle of the externalclock signal, since the input to the internal clocking circuitryis through a dividebytwo flipflop, but minimum and maximumvoltage high and low time specifications must be observed.Note: C1, C2 = 30 pF 177。 10 pF for Crystals= 40 pF 177。 10 pF for Ceramic ResonatorsFigure 2. External Clock Drive ConfigurationRestrictions on Certain InstructionsThe AT89C2051 and is an economical and costeffectivemember of Atmel’s growing family of microcontr