USB HID arduino leonardo
Moderator: Benj
-
- Posts: 18
- Joined: Mon Feb 25, 2013 10:15 am
- Has thanked: 3 times
- Been thanked: 4 times
USB HID arduino leonardo
The USB HID component for a keyboard doesn't work with a arduino leonardo.
- Attachments
-
- test flowcode 8 arduino leonardo 4 HID.fcfx
- (9.43 KiB) Downloaded 351 times
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: USB HID arduino leonardo
Hello,
For the AVR you need to edit the compiler options to allow the USB libraries to be included.
Use the Build -> Compiler options.
Change the AVR compiler setting to.
Location
$(compileravr)batchfiles\avra_usb.bat
Parameters
$(chip:l) "$(outdir)" "$(target)" HID
Then save as a new setting, maybe AVR USB HID.
You also need at least 10mS delays in between the SendData icons.
Let us know how you get on.
For the AVR you need to edit the compiler options to allow the USB libraries to be included.
Use the Build -> Compiler options.
Change the AVR compiler setting to.
Location
$(compileravr)batchfiles\avra_usb.bat
Parameters
$(chip:l) "$(outdir)" "$(target)" HID
Then save as a new setting, maybe AVR USB HID.
You also need at least 10mS delays in between the SendData icons.
Let us know how you get on.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Posts: 18
- Joined: Mon Feb 25, 2013 10:15 am
- Has thanked: 3 times
- Been thanked: 4 times
Re: USB HID arduino leonardo
It doesn’t work
- Attachments
-
- settings.jpg (61.84 KiB) Viewed 7199 times
-
- USBHIDPage1.jpg (129.97 KiB) Viewed 7199 times
-
- USBHIDPage2.jpg (141.09 KiB) Viewed 7199 times
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: USB HID arduino leonardo
Hi Kris,
Many thanks for letting me know. I believe I have now tracked down the cause of the problem.
I have updated the USB components and pushed the changes to the update system. Use the Help -> Check for updates menu to get the latest USB component updates.
I have also updated the compiler batch file which needs copying to the following location on your computer.
"C:\Program Files (x86)\Flowcode\Common\Compilers\avr\batchfiles"
Let us know how you get on.
Many thanks for letting me know. I believe I have now tracked down the cause of the problem.
I have updated the USB components and pushed the changes to the update system. Use the Help -> Check for updates menu to get the latest USB component updates.
I have also updated the compiler batch file which needs copying to the following location on your computer.
"C:\Program Files (x86)\Flowcode\Common\Compilers\avr\batchfiles"
Let us know how you get on.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Posts: 18
- Joined: Mon Feb 25, 2013 10:15 am
- Has thanked: 3 times
- Been thanked: 4 times
Re: USB HID arduino leonardo
The USB HID component doesn't work. There is no error with the compiler.
I use also the built in led of the arduino. With the new compiler options, it doesn't work.
I use also the built in led of the arduino. With the new compiler options, it doesn't work.
- Attachments
-
- USBHID.jpg (38.46 KiB) Viewed 7184 times
-
- USBHID.FCS
- (773 Bytes) Downloaded 338 times
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: USB HID arduino leonardo
Thanks for letting me know.
I have replicated the problem here and will see if I can investigate why it's not working for you.
I have replicated the problem here and will see if I can investigate why it's not working for you.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: USB HID arduino leonardo
Hello,
I've made some minor changes to your program and it's now working well for me.
I've made some minor changes to your program and it's now working well for me.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Posts: 18
- Joined: Mon Feb 25, 2013 10:15 am
- Has thanked: 3 times
- Been thanked: 4 times
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: USB HID arduino leonardo
Great glad it's working for you now.
I think it was mainly down to the delay before the initialise to give the PC time to see the bootloader disconnect and the HID device connect.
The other delays are still required as the HID only transfers every 10ms.
I think it was mainly down to the delay before the initialise to give the PC time to see the bootloader disconnect and the HID device connect.
The other delays are still required as the HID only transfers every 10ms.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Posts: 18
- Joined: Mon Feb 25, 2013 10:15 am
- Has thanked: 3 times
- Been thanked: 4 times
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: USB HID arduino leonardo
Hello,
Yes this should all work in v7 too. The v7 component should already work but let me know if you have any issues.
Yes this should all work in v7 too. The v7 component should already work but let me know if you have any issues.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Posts: 18
- Joined: Mon Feb 25, 2013 10:15 am
- Has thanked: 3 times
- Been thanked: 4 times
-
- Posts: 18
- Joined: Mon Feb 25, 2013 10:15 am
- Has thanked: 3 times
- Been thanked: 4 times
Re: USB HID arduino leonardo
I try to the USB_Serial component with arduino leonardo. There is a compilation error. (flowcode V7 and V8)
- Attachments
-
- TestUSBSerial.fcfx
- (8.71 KiB) Downloaded 224 times