NicoHood / Nintendo

Use Nintendo Controllers with Arduino
http://www.nicohood.de
MIT License
278 stars 55 forks source link

Gamecube.begin(2); Fails #1

Closed Ivoah closed 9 years ago

Ivoah commented 10 years ago

I have the gamecube controller plugged into my breadboard and Arduino Micro: gc

This setup worked using brownan's N64 to Gamecube program. The resistor in the image should be 1KΩ

NicoHood commented 10 years ago

Hi Ivoah. First: Try to clean your Fritzing schematics, thats very confusing. Clean the lines and color them better.

Then i would recommend you to check if the controller is not damaged. I strongly highlighted that you need a logic level converter for this library. See my schematic in the readme! They are 1 buck and safer. I could make it compatible but i dont like it without because you can damage the controller if you dont pay attention.

Another thing i want to mention in general: N64 is not supported yet and the sending to the console is paused, because my console doesnt want to accept my keyinputs. I will continue this project later.

Ivoah commented 10 years ago

Sorry about the fritzing image, I haven't used it very much. The controller works fine with a gamecube. As I mentioned above, it also works with another gamecube controller program for the arduino.

NicoHood commented 10 years ago

Sure. Be lucky that you didnt burned the controller. Use a logic level converter like i said and report the result. Its 1$ and saves all your GC controllers + it should work then.

Edit: What you are doing is to give the controller a 5V logic signal but its made for only 3.3v! Just for understanding, that is NOT good, please turn off your Arduino with this setup or your controller can get damaged

What Controller are you using? Official? Wavebird? Can you tell me the DOL number?

Ivoah commented 10 years ago

It is a madcatz controller

NicoHood commented 10 years ago

Interresting. As i said, try a logic converter. If it still doesnt work you might want to see whats going on with a salae logic analyzer and send me a screenshot. You know its so tricky to get the assembler stuff working.

What IDE version are you using? 1.5.7 and above seems to be broken because of compiler improvements.

Ivoah commented 10 years ago

I am using Arduino 1.0.5, and I don't have a logic converter or analyzer. p.s. Thanks for trying to help me with this problem :)

NicoHood commented 10 years ago

This will do it hopefully: http://www.ebay.com/sch/i.html?_sacat=0&_from=R40&_sop=15&_nkw=logic+level+converter&LH_PrefLoc=2&rt=nc&LH_BIN=1

Sorry i have no other solution yet. You can try another official! controller too. But this will damage the controller anyways. What you are doing is to give the controller a 5V logic signal but its made for only 3.3v! Just for understanding, that is NOT good, please turn off your Arduino with this setup or your controller can get damaged.

Ivoah commented 10 years ago

Why does it work without the logic converter on the gamecube to n64 converter?

NicoHood commented 10 years ago

Its the way i control the digital pin. The other sketch switches the pin from in to output and this causes the line to go low and high without setting it to 5V. But i SET the pin high and low because its the "normal" way to do it. Why not go ahead and buy this converter before damaging your controller anyways?

Ivoah commented 10 years ago

Oh, okay, I probably will buy it, thanks for the information

NicoHood commented 9 years ago

It might be possible that your not official controller has different timings. The official has exact 3 and 1uS pulses. And due to the pin mapping i have less time to implement a proper measurement. Thatswhy if you controller is slower or faster it might miss some values.

However you still need a logic level converter, i am sorry.

How to solve this? I have to get my hands on the controller or see a logic analyzer output. Or just use an official controller or use his version.

NicoHood commented 9 years ago

Can you please try again with the current beta version 1.1? https://github.com/NicoHood/Nintendo/tree/beta

Should work with the newer IDE 1.6 as well.