Results 1 to 6 of 6
  1. #1
    happiocholloh is offline Member
    Join Date
    Jan 2012
    Posts
    10
    Rep Power
    0

    Default Java + Keyboard Wedge + RFID

    Im playing around with some cheap RFID readers, they do not come with and sdk or an API, but they are automatically set up as a 'keyboard wedge'

    Im hoping to set up a textfield with a timer so that if a tag is passed over it checks the input and the string id associated. But that means if someone accidently presses the keyboard I would get an incorrect ID.

    So Im thinking,

    1. Is there a checksum process that I can use to check string is only from the tag?
    2. Can I lock the keyboard from input but still be able to use the reader?
    3. Is there a better library which identifies the usb device and port and info?
    4. Or another way entirely.

    I am a beginner and have my head around all the OO stuff and core but this is stretching me.

  2. #2
    Diargg is offline Senior Member
    Join Date
    Feb 2012
    Posts
    117
    Rep Power
    0

    Default Re: Java + Keyboard Wedge + RFID

    Disable the textfield? Which would make it a Label. You should explain what "keyboard wedge" means. Does the RFID reader have a keyboard attached?

    You're better off writing code until it breaks, and then asking for help.

  3. #3
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,184
    Rep Power
    19

    Default Re: Java + Keyboard Wedge + RFID

    if someone accidently presses the keyboard I would get an incorrect ID.
    Use a JTextField and setEditable(false).

    db

    edit Or a JLabel as Diargg recommended; personally, I prefer a disabled or uneditable text component for displaying read-only data (and not just in Java).
    Last edited by DarrylBurke; 06-06-2012 at 03:23 PM.
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

  4. #4
    happiocholloh is offline Member
    Join Date
    Jan 2012
    Posts
    10
    Rep Power
    0

    Default Re: Java + Keyboard Wedge + RFID

    That looks like an interesting option but a 'keyboard wedge' a term I picked up whilst trying to find the solution emulates the keyboard. Apparently the system does not tell the difference. So if I set editable to false, how could I get the input from the RFID. Its set up so that when you wave a tag, any program that takes keyboard input will display the info as if someone has typed it in.

    The RFID is just a box but when you wave the tag over it, it sends emulated keystrokes of number 12467799, This sequence is contained within the tag. The only code I can find reference COM ports.

    ill keep trying, thanks for your ideas, Ill try di

    Quote Originally Posted by DarrylBurke View Post
    Use a JTextField and setEditable(false).

    db

    edit Or a JLabel as Diargg recommended; personally, I prefer a disabled or uneditable text component for displaying read-only data (and not just in Java).

  5. #5
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,184
    Rep Power
    19

    Default Re: Java + Keyboard Wedge + RFID

    Oh.

    Does the reader send any special character to signal beginning and end of input? or only the keystrokes corresponding to the String representation of the tag ID?

    db
    If you're forever cleaning cobwebs, it's time to get rid of the spiders.

  6. #6
    happiocholloh is offline Member
    Join Date
    Jan 2012
    Posts
    10
    Rep Power
    0

    Default Re: Java + Keyboard Wedge + RFID

    It does only the keystrokes corresponding to the String representation of the tag ID?

    however I have found a solution on a c# forum that looks promising, not sure how do this though

    Currently I'm handling this by attaching to the KeyPress event and looking for a series of very fast key presses that contain the card swipe sentinel characters.

    Im thinking log system time whenever a key is pressed and check that there is a series of characters and then read from the text label. Im just wondering how to make sure there werent any accidental key presses moments before.

    Hmmm
    Last edited by happiocholloh; 06-15-2012 at 07:20 PM.

Similar Threads

  1. Java RDP Keyboard Issue
    By traqglow in forum Java Applets
    Replies: 2
    Last Post: 04-27-2012, 03:21 AM
  2. Active RFID Programming
    By ahmedmii in forum Advanced Java
    Replies: 0
    Last Post: 02-19-2012, 07:10 PM
  3. Replies: 1
    Last Post: 08-25-2010, 10:07 AM
  4. rfid projects in java
    By javastuden in forum Advanced Java
    Replies: 1
    Last Post: 08-09-2010, 01:53 PM
  5. Java RFID Programming
    By Shaolin in forum Advanced Java
    Replies: 1
    Last Post: 10-17-2009, 11:13 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •