+ Post New Thread
Results 1 to 12 of 12
  1. #1
    Full Member level 1
    Points: 2,035, Level: 10

    Join Date
    Aug 2004
    Posts
    105
    Helped
    0 / 0
    Points
    2,035
    Level
    10

    ccs keyboard

    hi...

    I need a keyboard driver which enable a PIC to read input from AT or PS/2 PC keybaord... and the keyboard driver source code in C lagangue best in hi-tech PIC C not asssembly.....

    Thanks

    •   AltAdvertisement

        
       

  2. #2
    Advanced Member level 5
    Points: 16,636, Level: 31

    Join Date
    Jul 2001
    Location
    Oberon
    Posts
    1,897
    Helped
    442 / 442
    Points
    16,636
    Level
    31

    pic keyboard




  3. #3
    Banned
    Points: 5,790, Level: 18

    Join Date
    Jun 2005
    Location
    scotland uk
    Posts
    646
    Helped
    96 / 96
    Points
    5,790
    Level
    18

    keyboard c example

    ccs compiler has a library for this



  4. #4
    Full Member level 4
    Points: 2,433, Level: 11

    Join Date
    Dec 2004
    Posts
    230
    Helped
    10 / 10
    Points
    2,433
    Level
    11

    pic24 keybaord

    But can you give some sample code for 4x4 key pad scanning. And if I required more then 4x4 key pad for this is there any solution?



  5. #5
    Banned
    Points: 5,790, Level: 18

    Join Date
    Jun 2005
    Location
    scotland uk
    Posts
    646
    Helped
    96 / 96
    Points
    5,790
    Level
    18

    picc keyboard

    i use an application called quickbuilder for ccs and pic mcus

    it has many drivers for 4x4 keyboards etc you just challange the build engine
    and it returns the
    fully built driver code block you then just include and init

    youll find an example setup of code in here
    http://uk.geocities.com/vsmvdd/COMVDD_EBOX_DESIGN.zip
    the designs for comvdd ebox the code there is half made for testing and as example of a big driver in usemade by quickbuilder

    i see by there site that it is not being distributed anymore at the moment

    so here is a driver i compiled within quickbuilder for you

    i used bport 0-3 and 4-7 pins for rows and columbs
    but its quite easy to change to the pins you want
    even adding a set of defines so the driver is easly setup then included

    you need to init the driver as mentioned in the driver text

    i see on the quickbuilder site the app is now
    the full version with just limited libs and sources

    however it loaded the design i made ok
    so you can use it to change the design to what you need

    as a kind of demo test of quickbuilders ability {a very handy tool }



    to read the data from any keyboard
    you pull the clock pin high
    then let the keyboard controller pull it back low
    then each bit is clocked out of the data line

    9600baud 1 start 1 stop bit

    so you need only to add a serial clock output to the serial port command string on any pic with a hardware uart software uarts wont work so well

    its easy to read AT keyboard
    ps2 is almost identical and the differenace is transparent to the data they produce
    5 pin din is just a different plug and slight protocol changes
    there are many keyboards all are 9600 baud
    a good thing to do is look for links to texts
    as ps2 keyboards can be init to use advanced drivers but ALL default to a standard local area layout



    •   AltAdvertisement

        
       

  6. #6
    Full Member level 1
    Points: 2,035, Level: 10

    Join Date
    Aug 2004
    Posts
    105
    Helped
    0 / 0
    Points
    2,035
    Level
    10

    hitec c at keyboard

    Quote Originally Posted by VSMVDD
    ccs compiler has a library for this
    Thanks for reply but I need the source code in .c not .lib

    Quote Originally Posted by Code Warrior
    But can you give some sample code for 4x4 key pad scanning. And if I required more then 4x4 key pad for this is there any solution?
    look at this site: http://www.vermontficks.org/pic.htm



  7. #7
    Full Member level 2
    Points: 5,889, Level: 18
    TechToys's Avatar
    Join Date
    May 2006
    Posts
    146
    Helped
    24 / 24
    Points
    5,889
    Level
    18

    pic keyboard

    May take a look at my web page to see if my driver (PS2) works for you.

    My page: www.TechToys.com.hk -> Download section.

    I have summarized the ps2 driver and tested it with Melabs X1 board, 4MHz crystal, 16F877.

    John Leung



  8. #8
    Full Member level 2
    Points: 2,554, Level: 11

    Join Date
    May 2004
    Location
    Coimbatore, INDIA
    Posts
    125
    Helped
    8 / 8
    Points
    2,554
    Level
    11

    pic ps2 keyboard c source code

    hai all

    this is the code i used to read the at keyboard and the key pressed will be displayed in LCD.
    if u want more particular details and pcb layout send me a pm



  9. #9
    Full Member level 1
    Points: 2,035, Level: 10

    Join Date
    Aug 2004
    Posts
    105
    Helped
    0 / 0
    Points
    2,035
    Level
    10

    keyboard hi-tech pic

    link:

    http://www.sourceboost.com/Products/...ampleCode.html

    don't know it will work if converted to hi-tech pic c.....

    Thanks



  10. #10
    Advanced Member level 3
    Points: 7,585, Level: 20

    Join Date
    Dec 2004
    Posts
    759
    Helped
    113 / 113
    Points
    7,585
    Level
    20

    pic keyboard ps2 mikroc

    MikroC also do have a library containing keyboard sour ce code.



  11. #11
    Newbie level 1
    Points: 1,177, Level: 7

    Join Date
    May 2006
    Posts
    1
    Helped
    0 / 0
    Points
    1,177
    Level
    7

    ccs c code for key board using serial

    you can found in sample code of CCS C program



    •   AltAdvertisement

        
       

  12. #12
    Full Member level 4
    Points: 2,433, Level: 11

    Join Date
    Dec 2004
    Posts
    230
    Helped
    10 / 10
    Points
    2,433
    Level
    11

    pic24 keyboard

    CCS C compiler has built in function for scanning 4x4 key matrix.



--[[ ]]--