is it possible to change the device class from keyboard to joystick while the USB device is plugged in and running?
I want to use both function at one time.
I'm planning to change between both classes by pressing Scroll Lock.
have anyone done this or do know if it's possible? sorry for my bad English writing..
changing the device class while running
Re: changing the device class while running
No that is in prog mem I think. You would be better off with a dual device layout and figure out how to switch via vendor ( using software) or a hardware switch.
Re: changing the device class while running
ulao wrote:No that is in prog mem I think. You would be better off with a dual device layout and figure out how to switch via vendor ( using software) or a hardware switch.
I decided to make this device by using software and found an information about the composite device.
And I remember your ID from your posts about this.
As you can guess, I'm beginner to this function so I need your advice.
Can you please tell me a little bit more about this function?
Re: changing the device class while running
I'm not sure what you want to know? There are a few composite examples around that is how I figure it out.
Re: changing the device class while running
It is possible to change between two device class without plugging the device out.
This can be done by making the device descriptors,configuration descriptors,hid descriptors,strings,serial etc all dynamic and selecting them according to the state of any specific key and change them when the key state is changed.
AVR is soft-reseted and upon starting new device is detected.
Donot Know if this is what you are searchinf for.
This can be done by making the device descriptors,configuration descriptors,hid descriptors,strings,serial etc all dynamic and selecting them according to the state of any specific key and change them when the key state is changed.
AVR is soft-reseted and upon starting new device is detected.
Donot Know if this is what you are searchinf for.
Re: changing the device class while running
ulao wrote:I'm not sure what you want to know? There are a few composite examples around that is how I figure it out.
The problem is that I can't find them because of my english skill I guess.. can you link one of those example codes for me please?
Re: changing the device class while running
Madara wrote:It is possible to change between two device class without plugging the device out.
This can be done by making the device descriptors,configuration descriptors,hid descriptors,strings,serial etc all dynamic and selecting them according to the state of any specific key and change them when the key state is changed.
AVR is soft-reseted and upon starting new device is detected.
Donot Know if this is what you are searchinf for.
yes this is what I'm looking for! thanks. but I can't really find out the way to code it..
Do you mean I have to make the new ones of them? or should I just fix the original arrangements etc..Because I just found that they already exist.
And which part exactly do I need to change or make???
Re: changing the device class while running
Look at http://www.raphnet.net/electronique/sne ... dex_en.php ( source at bottom of page )
He made an adapter that changes the reportDescriptor based on a variable. Depending on what the condition is, it leads a new descriptor. This maybe what you are after.
He made an adapter that changes the reportDescriptor based on a variable. Depending on what the condition is, it leads a new descriptor. This maybe what you are after.