Arduino and a WII controller

Discussion in 'General Electronics Chat' started by sqlman, Feb 22, 2015.

  1. sqlman

    Thread Starter New Member

    Feb 22, 2015
    5
    0
    Hi all - I am trying to teach my son (and myself) some elementary electronics.
    Right now we are working on controlling a WII through and Arduino - later we will write programs.
    Much later, we will simply transmit the IR codes the WII controller sends - not there yet.

    Through trial and error, we have found that some buttons on the WII controller "work" if connected to 5V; some "work" if they are grounded.

    Now we are trying to connect them to an Arduino, which has various outputs we can control.
    So the question is: how do I build a circuit that, when energized (ie 5V in) connects an input wire to GROUND?
    I guess electronic relays would be the easiest answer? I need to control buttons (up/down/left/right) that are triggered when connected to ground.

    Thanks
     
  2. Robartes

    Member

    Oct 1, 2014
    57
    13
    Can you give a bit more detail please? The way I'm reading this now is that you want an Arduino to 'push the buttons' on a Wii remote, i.e. have the Arduino act as the human player pushing the buttons. Is that correct?
     
  3. sqlman

    Thread Starter New Member

    Feb 22, 2015
    5
    0
    Exactly. And some buttons are "pushed" when you connect them to +5V while others are "pushed" when connected to ground. - we found that by trial and error
     
  4. Robartes

    Member

    Oct 1, 2014
    57
    13
    OK, thanks for clarifying that. What is the Wii controller powered from?
     
  5. sirch2

    Well-Known Member

    Jan 21, 2013
    1,008
    351
    I note you say "later we will write programs". To get the Arduino to drive the WII buttons you need to write a program. Get the arduino running the Blink example and look a the program for that, what that does is turn an LED on and off which might be similar to turning the wii buttons on an off.
     
  6. sqlman

    Thread Starter New Member

    Feb 22, 2015
    5
    0
    The WII has it's own batteries - which are at +4.5V, so I am thinking of just using the +5V from the Arduino
     
  7. sqlman

    Thread Starter New Member

    Feb 22, 2015
    5
    0
    What I meant is that we have cannibalized the LED program, and we can turn on the buttons that need +5V - but we cant "turn on" the buttons that need to connect to GROUND.

    Eventually, we'll get around the whole WII controller and simply transmit the correct codes via bluetooth - but this is the best way to get him to understand what his happening. He will also appreciate that soldering (which turns out to be harder than he thought) can be circumvented - but he has not figured that out yet :)
     
  8. GopherT

    AAC Fanatic!

    Nov 23, 2012
    6,004
    3,757
    @sqlman
    Here. This is how switches are normally connected (to row, to get 0 or 5 volts). Notice how voltage at output changes when switch is open (left) and closed(right) depending whether it is a pull-up resistor or pull-down resistor.

    Use transistors. MOSFETS are used here. You may also use BJT transistors

    image.jpg
     
    Last edited: Feb 22, 2015
  9. sqlman

    Thread Starter New Member

    Feb 22, 2015
    5
    0
    THANKS! Perfect. Any specific items you'd recommend? (ie model number etc so we can hike down to RadioShack?)
     
  10. GopherT

    AAC Fanatic!

    Nov 23, 2012
    6,004
    3,757
    First, check if your local shop is open, many have closed or will close in the next few days. You may find clearance prices.

    Then just look for NPN and PNP transistors. Get the multi pack of each. Any will work. I drew with MOSFET, they are not available at rS. For the NPN and PNP, add a resistor in series with the signal input to the base (1k to 10k ohm)

    The 2N3904, 2N4401 and 2N2222A are common NPN and 2N3906 and 2N4403 will be at RAdio Shack
     
  11. GopherT

    AAC Fanatic!

    Nov 23, 2012
    6,004
    3,757
    This is using transistors listed above.

    image.jpg
     
    sqlman likes this.
Loading...