Pages: [1]   Go Down
Author Topic: Connect to USB Missile Launcher  (Read 1955 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

RE: http://www.reddit.com/r/arduino/comments/srbln/help_fire_usb_missile_launcher_serial_commands_c/

Harware:

I traced the USB commands to the missile launcher and it takes in four 0a 0a 00 00 00 00 00 00. I am having trouble sending this to the missile launcher via the arduino.

Pretty sure I have to do something like this: http://www.circuitsathome.com/mcu/driving-the-cheeky-mail-notifier-from-arduino#more-5665
But setReport is giving me errors.
Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 644
Posts: 50524
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
But setReport is giving me errors.
Your code? The errors?

Our psychic is out sick today. Strange that she didn't see that coming...
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

http://www.circuitsathome.com/mcu/driving-the-cheeky-mail-notifier-from-arduino#more-5665

I can't even compile the above. I believe it is because it is using the legacy usb host shield that does not work with arduino 1.0?
Code:
error: 'class USB' has no member named 'setReport'

Some information about the USB
Code:
Intf.number: 00
Alt.: 00
Endpoints: 01
Endpoint address: 82
Attr.: 03
Max.pkt size: 0008
Polling interval: 0A
Endpoint address: 81
Attr.: 03
Max.pkt size: 0008
Polling interval: 0A


« Last Edit: April 25, 2012, 08:51:31 am by twodayslate » Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 644
Posts: 50524
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
I believe it is because it is using the legacy usb host shield that does not work with arduino 1.0?
The hardware doesn't care which version of the IDE you use. Which version of the USB Host library are you using?
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

USB Host Library 2.0

The legacy version wasn't working for me because it said the BYTE was outdated for arduino 1.0
Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 644
Posts: 50524
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

So, you are using version 2.0 with some code that expects version 1.0, and you are having problems compiling, and can't figure out why. Did I miss something?
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Nope, that basically sums it up.

So what is the replacement for setReport for 2.0?
Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 644
Posts: 50524
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
So what is the replacement for setReport for 2.0?
Beats me. Might be easier to get the older version working with 1.0, though.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Where would I be able to download a pre-1.0 arduino environment?
Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 644
Posts: 50524
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Why not make the USB 1.0 library work with Arduino 1.0? It can't be that hard.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 6
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Alright. I finally got this to compile. However, I don't think I am connected fully.
Code:
    #define MailNotifier_ADDR        1
    #define MailNotifier_EP          81
    #define MailNotifier_IF          0
    #define EP_MAXPKTSIZE            8
    #define EP_POLL               0x0a

    EP_RECORD ep_record[ 81 ];
Here is the usb information from arduino http://pastebin.ca/2140539

edit:// Here is my code: http://pastebin.ca/2140545

edit:// I got it! http://pastebin.ca/2140564
I used pre-1.0 and the legacy USB driver.
« Last Edit: April 25, 2012, 08:58:24 pm by twodayslate » Logged

Pages: [1]   Go Up
Jump to: