Page 1 of 1

fixed hid descriptor in RAM

Posted: Mon Dec 31, 2012 2:28 am
by Kasia
Hi ... :)
I learn to use v-usb. I train with the system of 1-key-keyboard (http://www.obdev.at/products/vusb/prjdetail.php?pid=64 ). I built and ran the system, compile a program in WinAVR. All working ok. I work to understand the HID descriptor and develop software for their simple needs. I was looking for an example using software v-usb instead of the descriptor located in the flash memory in RAM. I have not found it. My own attempts to modify the 1-key-keyboard failed. The program compiles without errors, but the device did not work properly (in WinXP error 10). I need help finding examples of implementations using software located hid descriptor in RAM. I will also be grateful for your help in modifying the 1-key-keyboard to working with hid descriptor placed in RAM.
Thanks :)

Re: fixed hid descriptor in RAM

Posted: Mon Dec 31, 2012 4:18 am
by ulao
Do you mean PROGMEM ?

Code: Select all

const char  analog_usbHidReportDescriptor[] PROGMEM = {
///// gampad
0x05,0x01,  //    Usage Page Generic Desktop
0x09,0x05,  //    Usage Joystick
0xA1,0x01,  //    Collection Application
//axis
   0x85,0x01,        //    Report ID 1
   //0x05, 0x02,                  //USAGE_PAGE (Simulation Controls)
   //0x09, 0xBB,                //USAGE (Throttle)
...

Re: fixed hid descriptor in RAM

Posted: Mon Dec 31, 2012 7:46 am
by declan smith
It called Dynamic HID Descriptor.
It looks like the same with yours : http://forums.obdev.at/viewtopic.php?f=8&t=5450

Re: fixed hid descriptor in RAM

Posted: Tue Jan 01, 2013 7:56 pm
by Kasia
Thank you. I read about it. I used to follow the guidelines, but without success. Now I could see that things are not done well. Try again. Forum V-USB searched carefully. I was thinking about other examples, can anyone else tried this technique. It's easier to understand the subject, seeing a few examples. Thank you again, can now succeed.

Re: fixed hid descriptor in RAM

Posted: Tue Jan 01, 2013 8:02 pm
by Kasia
ulao wrote:Do you mean PROGMEM ?

...


PROGMEM means that the plate is located in the non-volatile memory (flash memory). And it can not be changed during program execution. Or just I can not. Few even know how ... :roll:

Regards

Re: fixed hid descriptor in RAM

Posted: Mon Jan 07, 2013 1:31 am
by Kasia
Thank you, I read further about HID and modified the V-USB library and launched a single chip HID two devices: one type Keyboard (http://blog.flipwork.nl/?x=entry:entry081009-142605), the second type of USAGE 1 Aplication (from hid-date, vusb-20121206.zip, http://www.obdev.at/products/vusb/download.html). HID descriptor in flash, no RAM. Device selection is made the switch before starting the program. Devices exchange data via eeprom. "hid-data" (commandline) writes to eeprom character code, that "1-key ..." after starting the download and after pressing send the application running on the computer.
If you would be interested users attach modified code (or all if admin allow). Problem solved.
I turn to further experiments :-)

Regards