Jump to content
lawrence_jeff

Launchpad USB example and documentation additions/labs

Recommended Posts

I have figured it out, it only works when I connect to device. However when I run the gamepad example, the correct drivers dont seem to install. It shows up as Gamepad example, but gamepad drivers are not installed. 

Is this perhaps because the g_pSerialNumberString was already detected on my computer as a Volume control device?

many thanks

Jesse

 

Sometimes Windows does get confused. I thought I had some info in the document about that but don't have it in front of me. If you change the PID it should see it as a new device. (Shouldn't be necessary if you delete the device)

Share this post


Link to post
Share on other sites

@@lawrence_jeff

thank you for the quick reply. I've changed the pid in usb_dev_custom_structs.c to USB_PID_GAMEPAD following the documentation and as well deleted the device but it still doesnt appear as a gamepad. The same happens when I load the usb_dev_gamepad project, the code will run, but incorrect driver.

Additionally, I plugged in the launchpad to a 'fresh' computer to see what driver it would install and the same thing happens.

Is there a way to force the right driver?

Share this post


Link to post
Share on other sites

@@lawrence_jeff I figured I would try out the keyboard and mouse example to see if the proper drivers install. Following the documentation I made the changes to usb_dev_custom and usbhidcustom.c/.h. However, when I deploy neither does the computer install the correct drivers, nor does it send keyboard commands, what is sent is continuous volume 'UP' as seen on my pc.

When I try to run the usb_dev_KeyandMouse example a continuous alternating volumeUp volumeDown stream is sent. I dont know where In the code this is originating from...

any ideas why this might be happening?

many thanks

Jesse

Share this post


Link to post
Share on other sites

@lawrence_jeff i've finally come back to working on the Lauchpad and have been very unsuccessful at getting the gamepad example running. 

In windows it still does not show up as a gamepad and does nothing when plugged in, and in linux when I push SW1 the volume increases/decreases very rapidly.  

 

 

I dont know why this is happening. I have attached usb_dev_custom.c as well as usbhidcustom.c and usbhidcustom.h. Would it be possible for someone to take a look and let me know what im doing wrong?

 

many thanks

Jesse

 

 

usb_dev_custom.c

usb_dev_custom_structs.c

usb_dev_custom_structs.h

usbdhidcustom.c

usbdhidcustom.h

Share this post


Link to post
Share on other sites

Is there any other information I can provide in order to clarify where this problem is originating from? 

 

Is there alternatively another example program which sets up the LM4F120 as a gamepad? (I know there is an example from the TM4C123GXL, can this be compiled for the LM4F120?)

Share this post


Link to post
Share on other sites

@@lawrence_jeff, @@Rhys

 

Hi guys and thanks for your work here. I know this is an old thread, but I've got a couple of question's and maybe you have the answers.

I've used the supplied code for building an arcade control encoder for a raspberry pie arcade cabinet. The controls consist of

2 classic arcade style joysticks and 14 buttons, 1 joystick and 7 buttons for each player. I've written the device report descriptor to send 2

report ID's 1 for each player. When I plug the encoder into a windows machine it enumerates as a game pad with 2 controllers

and everything works as expected. When I plug it into any of my linux machines including the rpi, the encoder enumerates and

everything works except for the x- , y- axis values. My first question do you have any idea what values are expected for the -x, -y?

In the device descriptor I've set logical minimum to -1, logical maximum to 1. I've set up my descriptor just like the example in the USB spec.

Also did either of you use the gamepads discussed above in a linux based system?

 

post-36-0-29026500-1485803065_thumb.jpgpost-36-0-72850500-1485803165_thumb.jpg

 

This is so close!

I am using the Stellaris Launchpad for this.

Any ideas are much appreciated.

thanks

Tim

 

 

Share this post


Link to post
Share on other sites

@@lawrence_jeff, @@Rhys

 

Hi guys and thanks for your work here. I know this is an old thread, but I've got a couple of question's and maybe you have the answers.

I've used the supplied code for building an arcade control encoder for a raspberry pie arcade cabinet. The controls consist of

2 classic arcade style joysticks and 14 buttons, 1 joystick and 7 buttons for each player. I've written the device report descriptor to send 2

report ID's 1 for each player. When I plug the encoder into a windows machine it enumerates as a game pad with 2 controllers

and everything works as expected. When I plug it into any of my linux machines including the rpi, the encoder enumerates and

everything works except for the x- , y- axis values. My first question do you have any idea what values are expected for the -x, -y?

In the device descriptor I've set logical minimum to -1, logical maximum to 1. I've set up my descriptor just like the example in the USB spec.

Also did either of you use the gamepads discussed above in a linux based system?

 

attachicon.gifLP.jpgattachicon.gifcab.jpg

 

This is so close!

I am using the Stellaris Launchpad for this.

Any ideas are much appreciated.

thanks

Tim

Its been long enough that I would have to take a look to figure it out - can you post your code? Or email lawrence underscore jeff at hotmail.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×