Skip to main content

Intel 8253/54 Programmable Interval Timer

Necessity of Programmable Interval Timer

The 8253/54 solves one of most common problem in any microcomputer system, the generation of accurate time delays under software control. Instead of setting up timing loops in system software, the programmer configures the 8253/54 to match his requirements, initializes one of the counters of the 8253/54 with the desired quantity, then upon command the 8253/54 will count out the delay and interrupt the CPU when it has completed its tasks. It is easy to see that the software overhead is minimum and that multiple delays can be easily be maintained by assignment of priority levels.

Also there is one more important problem. If the processor is busy in time delays using software control, we can't use the processor for performing any other action without the help of Interrupts. It is tedious job for a programmer. Also in the timing loops processor looses important time. So it is better to go for an Programmable Interval Timer.

The 8253/54 includes three identical 16 bit counters that can operate independently. To operate a counter, a 16-bit count is loaded in its register and, on command, it begins to decrement the count until it reaches 0. At the end of the count, it generates a pulse that can be used to interrupt the CPU. The counter can count either in binary or BCD. In addition, a count can be read by the CPU while the counter is decrementing. The 8254 is a superset of 8253. The functioning of these two ICs are almost similar along with the pin configuration. Only the differences are :
8253 8254
Operating frequency 0 - 2.6 MHz. Operating frequency 0 - 10 MHz.
Uses N-MOS technology. Uses H-MOS technology.
Read-Back command not available. Read-Back command available.
Reads and writes of the same counter can not be interleaved. Reads and writes of the same counter can be interleaved

Comments

Popular posts from this blog

8051 Simple Programs

Sum of 8-bit Numbers Stored in Memory Here  we will discuss about 8051 programs but we can't discuss about all of the 8051 instructions. For programming 8051 we should know about assembler directives as well as instruction set. Click  here to download Atmel c51 user guide that will discuss about 8051(c51 family microcontroller) instruction set, assembler directives, c51 cross assembler from Atmel.  Program ORG 00H MOV R0,#50H   ; get memory location in memory pointer R0 MOV R1,#51H   ; get memory location on memory pointer register R1 MOV A,@R0       ; get content of memory location 50H to accumulator ADD A,@R1        ; add content of A with content of memory location 51H and store result in A MOV R0,#52H    ; get 52H to memory pointer R0 MOV@R0,A         ; copy content of A to memory location 52H END Add 16-bit Numbers ...

Even and Odd Memory Banks

The 8086 microprocessor uses a 20-bit address to access memory. With 20-bit address the processor can generate 2 20 = 1 Mega address. The basic memory word size of the memories used in the 8086 system is 8-bit or 1-byte (i.e., in one memory location an 8-bit binary information can be stored). Hence, the physical memory space of the 8086 is 1Mb (1 Mega-byte). For the programmer, the 8086 memory address space is a sequence of one mega-byte in which one location stores an 8-bit binary code/data and two consecutive locations store 16-bit binary code/data. But physically (i.e., in the hardware), the 1Mb memory space is divided into two banks of 512kb (512kb + 512kb = 1Mb). The two memory banks are called Even (or Lower) bank and Odd (or Upper) bank. The organization of even and odd memory banks in the 8086-based system is shown in Figure. The 8086-based system will have two sets of memory IC's. One set for even bank and another set for odd bank. The data lines D 0 -D 7 are conne...

Hex file generation using Keil

Keil μvision is an Integrated Development Tool(IDE) to write, simulate and flash our program written either in assembly language or in C. We can also flash our program to mcs51 series(8051 family) microcontroller using Keil μvision IDE. But I will prefer you to use Flashmagic developed by NXP to flash your program into 89c51(I am emphasize that 8051 has no flash memory. But we can use other microcontrollers that are code compatible with 8051 like 89c51 from Atmel or 89c51RD2BN from NXP etc.). But we want to familiar with Keil μvision to generate hex files from our embedded C programs. You want to click here to download latest version of Keil μvision. This will redirect you to official website of Keil. You must fill the form before download Keil. The Keil μvision IDE setup file has more than 100 Mb in size. After downloading this setup file double click on it and install it. During installation this may ask your e-mail ID and lot of things. If you want notif...