Articles

Introduction to 8279 Programmable Keyboard/Display Controller – Peripheral Interfacing with 8085


Do subscribe to Ekeeda and press bell icon to get updates about latest Engineering HSC and IIT-JEE Mains and Advanced videos. The programmable keyboard display controller it’s IC number is 8279 it was designed by Intel to interface the keyboard with the Microprocessor that is why it’s name is programmable keyboard display controller means whenever we want to interface the keyboard with the central processing unit or the Microprocessor then be used as an interface the programmable keyboard display controller so we can say that if it is the CPU or the microprocessor and it is the keyboard or the display unit then as an intermediate or as an interface we will have here the eight two seven nine programmable keyboard display controller so whenever we want the CPU and the keyboard they want to transfer some data or they want to communicate with each other so this communication will takes place with this eight two seven nine okay so any transfer of data it will take place via this eight two seven nine so we can say that this programmable keyboard display controller eight two seven nine it interfaces a keyboard with the CPU or processor now what is the function of this eight two seven nine whenever any key is pressed on the keyboard then this eight two seven nine it will scan that which he is pressed and if any key is pressed on the keyboard then it will transfer the relative response of that key to the CPU so that CPU will get to know that this key has been pressed on the keyboard and the function which the CPU has to be performed will be given to it by the eight two seven nine so this eight two seven nine it is scans the keyboard and check that if any key is pressed and if it is so then it is going to transfer the response to the CPU so this eight two seven nine it is basically scanning the keyboard and it is identifying that if any key is pasted on the keyboard and if it is pressed if any key is pressed on the keyboard then it will say the relative response of the pressed key to the CPU so this is the function of the eight two seven nine programmable keyboard display controller now let us study some of the features of this eight two seven nine I see as the name programmable keyboard display controller says that this is a controller which is used to interface the keyboard and the display devices to the CPU so we can say that it is interfacing both the cubed keyboard under display devices to the microprocessor based systems so its feature is that it can have simultaneous keyboard and the display operations keyboard we know that a keyboard is designed input device through the keyboard the user it is inputting the data to the CPU it is giving the data to the CPU okay so keyboard it is an input device and display devices they are the output devices like the monitor printer these are the output devices so both the input and output devices they can be connected or they can be interfaced with the microprocessor based systems so we can say that 8 2 7 9 8 allows simultaneous keyboard and display operations one of the – one of the moods of those a 279 is the scanned keyboard mode and one of the muder scan sensor mode so these modes allow to scan the keyboard which is an input device and the sensors or the display devices so it is allowing both the keyboard under display operations next feature is that it has a 8 character as I said dr. a 2 7 9 8 scans that way the keyboard and it checks that if any key is pressed on the keyboard so the information about the opening and closure of the keys that whether it is pressed or not that information it is stored in some memory so this memory in the 8 2 7 9 it is a 8 character keyboard fifo RAM and 8 character means 8 bytes can be stored in this param at one time and this is first-in first-out this fee for stands for first and first out that means the character which is first stored into the memory that will be the first to get out of the memory means – as an output of the memory so first in first out memory and it is an eight character keyboard memory okay eight bytes can be stored similarly a ram is therefore the display devices also so here the diameters of 16 character means 16 bytes so eight characters eight bytes can be stored in the keyboard RAM and 16 characters can be stored on the display Ram now next feature of this eight to seven line is that right or left entry 16 byte display Ram now in though each character keyboard FIFO its characteristic is that the character will be stored in the ramp as first-in first-out they will use this feature that the first character that will be put in the memory that will be for the first element to get out of the memory okay that is first-in first-out suppose it is the memory here the first element is a store so this first element will be the first to get out of the memory okay now in the 16 character display ramp this ramp follows the right or left hand ring okay means the characters will be enter either from the right hand side or from the left hand side okay this we will get to to understand more when we will study the moves of 8 2 7 9 next feature is the programmable scan timing as it is this eight two seven nine it is scanning the keyboard and the display devices so this is scan time it can be programmed means we have instructions we have software instructions to which we can program this a two seven nine program with this controller that is that is known as programmable keyboard display controller because programs or we can say that the instructions and command codes can be written in this eight two seven nine so that we can modify it or we can use it for various applications so these were the features of the eight two seven nine now let us come to the topic that how we can interface the eight two seven nine with the CPU okay because it is acting as an interfacing device between the central processing unit and the keyboard and display devices so how we can interface both the CPU and the eight two seven nine let us see there are two modes or in which or we can say that there are two ways in which the keyboard is interfaced with the CPU one is the interrupt mode and second is the hold mode now the function of this a 2 7 9 it is to scan the keyboard and display devices so in the interrupt mode the microprocessor if any key is pressed on the keyboard then this a 2 7 9 it is going to interrupt the microprocessor and it will request the microprocessor that stop your current operation and then first see that this key has been pressed on the keyboard and you have to perform the relative response of that key so when this mode interrupt mode it says that the microprocessor will be interrupted every time a key is pressed so in this mode the microprocessor it will be interrupted interrupted means a service will be requested means we want the service of the microprocessor of this CPU or the microprocessor that we want your service we want that you make a response according to the key bitches pressed so processor is requested service only if any key is pressed otherwise the CPU will continue its main task so CPU will not be disturbed until and unless any key is pressed if CPU is doing some work it will continue doing its main task only when if any key is pressed then only the CPU will be interrupted so that is the interrupt mode now comes to the old mode so in the poll mode the cpu it is going to periodically means at a certain interval of time it is going to check the internal flag of the eight two seven nine the keyboard controller and if that flag is set or reset according to that it will make that the key is fresh or not okay so it is periodically checking the internal flag of eight two seven nine to check that whether the key has been pressed or not if this internal flag is not set it means that he is not pressed and if it is set it means the key is pressed okay so every time it is not necessary that every time the key is pressed okay it may be possible that it is pressed or it is not press it is just checking periodically making a check at every exit an interval of time suppose like after every two seconds it is checking the flag that whether the key is pressed or not okay so CPU is always like we can say that it is busy in checking though every time it has to check the internal flag okay so a task has been assigned to the CPU that you have to check the internal flag whereas in the interrupt mode the CPU will be disturbed only when the key is pressed it can continue doing its the its main task but in pole mode the CPU is every time disturb every time it has to check at certain intervals of time that the key is pressed or not so this is the way in which the eight two seven nine it is interfaced with the CPU one is the interrupt mode and second is the hold mode now let us come to the topic that how does this eight two seven nine works okay how it is scans the keyboard and how it is going to transfer or send the response of the key to the CPU let us see that how does this a two seven nine work now dokie this a two seven nine it is interfacing the keyboard and the display devices with the CPU so if we see a simple keyboard then it consists of 64 keys and these 64 keys they are interfaced with the CPU now this keyboard it consists of maximum 64 keys okay and these he is they are interfaced with the CPU by using the key codes so every key it will have a key code associated with it now when the key is pressed then the eight two seven nine it is going to transfer the key code into the memory of the keyboard and this eight two seven nine okay so so when the key is pressed then the eight two seven nine it is going to store the key code of that pressed key into the eight byte FIFO wrap it is going to store that key code into the eight byte C forum and this rabbit is accessed by the CPU so the CPU it is going to read this eight byte FIFO Ram and through the key code it is going to know that this key has been pressed and it has to perform the function which is associated with that key now if more than because one is spaced at a time suppose that many keys are pressed and their key codes are stored in the eight byte FIFO Ram then that condition because it can store only eight byte okay so eight byte more than eight bytes keys are pressed then that condition is known as overrun so if more than eight keys or eight characters are entered in the FIFO because this people at a time it can save only eight by means eight characters it can save and if more than eight characters are entered in the FIFO it means that more than eight keys are pressed at a time and this is when the Oberon statuses said so so whenever the eight keys of more than eight keys are pressed at a time then this Oberon statuses said now when Oki is present on that then the keycode of that key is saved in the FIFO and now if the P forum it contains a valid key entry means it shows that a key has been pressed valid they are saying because whenever eight keys are pressed or more than eight keys are pressed then that is not a valid key entry so here we are saying that if the FIFO it contains a valid key entry then the CPU is interrupted in an interrupt mode else the CPU checks the status in the polling mode to read the entry okay as I said in the net how we can interface the keyboard with the CPU I have explained the two modes interrupt mode and the polling mode so here I am saying that if the FIFO it is containing a valid key entry then two things can happen in the interrupt mode the CPU will be interrupted or in the polling mode the CPU it is going to check the status of the flag okay so here I have written that if he fuckin taints a valid key entry then the CPU is interrupted in an interrupt mode is the CPU it will check the status in the polling mode to read the entry okay so the CPU is getting the information that this key has been pressed and the response of that key is provided by the CPU means the function which is associated with the key which is space will be performed by the CPU now once this entry which is there in the FIFO it is read by the CPU then the FIFO it is updated and the key entry it is pushed out of the FIFO to generate space for the new entries so suppose this is the fee for am in this fee for the information about the key which is pressed it is stored okay suppose this information is X X s now this information it will be read by the CPU and once the CPU has read the information about this key pressed and it has read it then this entry which is there in the FIFO it will be pushed out for the FIFO so that the new key code entries or the new entries of the key which is pressed that will be stored in the FIFO okay so in this way the 8279 it is working it is first scanning the keyboard that if any key is pressed or not and if it identifies that a key has been pressed on the keyboard then it is going to store the key code which is related with that key pressed into the FIFO Ram and then this Ram will be read by the CPU CPU will get to know that this key code is there in the FIFO Ram and this key code is associated with this key so that function which is associated with the key will be performed by the CPU and then this p4 Ram will be made empty this entry will be pushed out of the fee for app so that the new please can get space into dough maybe they can be stored in this wrap okay so in this way the eight two seven nine programmable keyboard display controller works so in this video we studied about some of the features of 8 2 7 9 then we studied that how we can interface the keyboard with the CPU the two modes interrupt mode and the polled mode we studied and then we studied that how the 8 to 7 9 programmable keyboard display controller works so I hope that this topic is clear to you thank you

Be the First to comment.

Leave a Comment

Your email address will not be published. Required fields are marked *