CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

How to get HID-keyboard LED status?

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
clst
Guest







How to get HID-keyboard LED status?
PostPosted: Wed Jan 13, 2010 10:04 pm     Reply with quote

I have a problem with my PIC18F2550 when trying the USB-HID-Keyboard in the ex_usb_kbmouse.c example. I can't get the value of LED status, such as NUM LOCK, CAPS LOCK, etc, from PC.

How to get the value of LED status? (** value of "leds" always ZERO!)

Code:

   //receive NUM LOCK, CAPS LOCK, etc LED status from PC.
   //we won't do anything with it.
   if (usb_kbhit(2))
   {
      usb_get_packet(2, &leds, 1);
   }

What should I do?
Best Regards,
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group