Page 47 of 59

Re: WII U RASPBERRY PI 3 FINISHED

Posted: Wed Jan 30, 2019 4:56 am
by VeteranGamer
blu3rav3n wrote:
Tue Jan 29, 2019 6:22 am
Question Time! Either what am I doing wrong with the teensy....orrrr will plan b work with rigging the usb controller up to it? This is the last bit of issues thats keeping me from finishing this. Thanks
i would suggest stick with the Teensy....

which Teensy are you using?

this one would be the best option (Teensy 2.0)...

Image


as trying to get a controller to fit is just way extra work (especially for space management)
getting the analogs to work shouldnt be a major issue...
you could always swap out the analogs on the Wii U for the ones that are on the controller....


but, thats just way too much work...

are you sure you have a genuine Teensy 2.0 (not sure you can even get a clone of it)
make sure you have programmed/loaded the script onto the Teensy properly

if you have applied the wrong script or would like to reflash the Teensy...
you would need to reset the device and put it into program mode (this normally comes up when you connect to you PC)

if you facing issues...
try deleting and reinstalling the Arduino software
make sure you have the correct drivers installed
make sure your using the correct script



.

Re: WII U RASPBERRY PI 3 FINISHED

Posted: Wed Jan 30, 2019 8:02 am
by blu3rav3n
VeteranGamer wrote:
Wed Jan 30, 2019 4:56 am
blu3rav3n wrote:
Tue Jan 29, 2019 6:22 am
Question Time! Either what am I doing wrong with the teensy....orrrr will plan b work with rigging the usb controller up to it? This is the last bit of issues thats keeping me from finishing this. Thanks
i would suggest stick with the Teensy....

which Teensy are you using?

this one would be the best option (Teensy 2.0)...

Image


as trying to get a controller to fit is just way extra work (especially for space management)
getting the analogs to work shouldnt be a major issue...
you could always swap out the analogs on the Wii U for the ones that are on the controller....


but, thats just way too much work...

are you sure you have a genuine Teensy 2.0 (not sure you can even get a clone of it)
make sure you have programmed/loaded the script onto the Teensy properly

if you have applied the wrong script or would like to reflash the Teensy...
you would need to reset the device and put it into program mode (this normally comes up when you connect to you PC)

if you facing issues...
try deleting and reinstalling the Arduino software
make sure you have the correct drivers installed
make sure your using the correct script



.

Yup got an official 2.0 Teensy. I did check that I had the correct drivers and tried reinstalling the software. It seems once I flash the Teensy everything just stops working. No leds off the Teensy, I can see it in windows or device manager. Arduino software dosnt see it either. As for the script I copied everything off the first page and pasted it right into a blank page on the Arduino software window. My only thoughts is that I got a bonk Teensy or some how messed it up while soldering.

Re: WII U RASPBERRY PI 3 FINISHED

Posted: Wed Jan 30, 2019 8:13 am
by VeteranGamer
blu3rav3n wrote:
Wed Jan 30, 2019 8:02 am
Yup got an official 2.0 Teensy. I did check that I had the correct drivers and tried reinstalling the software. It seems once I flash the Teensy everything just stops working. No leds off the Teensy, I can see it in windows or device manager. Arduino software dosnt see it either. As for the script I copied everything off the first page and pasted it right into a blank page on the Arduino software window. My only thoughts is that I got a bonk Teensy or some how messed it up while soldering.


have you tried to put it back into program mode....


Image


https://www.pjrc.com/teensy/tutorial.html



.

Re: WII U RASPBERRY PI 3 FINISHED

Posted: Wed Jan 30, 2019 8:22 am
by blu3rav3n
VeteranGamer wrote:
Wed Jan 30, 2019 8:13 am



have you tried to put it back into program mode....


Image


https://www.pjrc.com/teensy/tutorial.html



.
I did try this as well and tried hold ing the button before plugging it in and then release once I plugged the usb into my pc and still nothing. If I use a pc thats never had the software or the Teensy attached is the only way I ever see it show up again and when I can hit the button for it to do something.

Re: WII U RASPBERRY PI 3 FINISHED

Posted: Wed Jan 30, 2019 10:21 am
by VeteranGamer
blu3rav3n wrote:
Wed Jan 30, 2019 8:22 am
VeteranGamer wrote:
Wed Jan 30, 2019 8:13 am



have you tried to put it back into program mode....


Image


https://www.pjrc.com/teensy/tutorial.html



.
I did try this as well and tried hold ing the button before plugging it in and then release once I plugged the usb into my pc and still nothing. If I use a pc thats never had the software or the Teensy attached is the only way I ever see it show up again and when I can hit the button for it to do something.

Then it’s obviously something wrong with the PC your using....

Maybe check your connections via device manager and delete what ever comes up as the Teensy...
Check that you’ve selected the correct device in the Arduino software (including the right Comm port)


But
If it’s recognised by another PC....
Then just reflash the correct script on the Teensy using that PC



.

Re: WII U RASPBERRY PI 3 FINISHED

Posted: Wed Jan 30, 2019 9:37 pm
by llonden
I'm currently using a Powerboost 1000 Basic along with Adafruit's USB Lipo Charger(v1.2, #259). Following the Lipopi debugging script, I'm getting some below average battery life results....

3.7v 2500mah Lipo Battery: 4.20v when fully charged, drops to 3.90v when powering on a Pi 3 and lasting only 15 minutes before hitting 3.70v and shutting down

3.7v 4400mah Battery Pack: 4.20v when fully charged, drops to 3.99v when powering on a Pi 3 and lasting only 32 minutes before hitting 3.70v and shutting down

All my 5v and Gnd wires connected to the Charger, Powerboost, and Pi are short length and thick 24 gauge. Anyone else having this issue? I hate to get this far only being able to play for less than an hour before charging again...

Re: WII U RASPBERRY PI 3 FINISHED

Posted: Sat Feb 02, 2019 12:30 pm
by EVE-TECH
Veteran gamer any update on that power circuit!!

Re: WII U RASPBERRY PI 3 FINISHED

Posted: Mon Feb 04, 2019 6:29 am
by blu3rav3n
VeteranGamer wrote:
Wed Jan 30, 2019 8:13 am

Then it’s obviously something wrong with the PC your using....

Maybe check your connections via device manager and delete what ever comes up as the Teensy...
Check that you’ve selected the correct device in the Arduino software (including the right Comm port)


But
If it’s recognised by another PC....
Then just reflash the correct script on the Teensy using that PC



.
So I tried 4 other pcs I have all with the exact same results. Plug it in, arduino software sees it, flash it, gone - cant see the device in the software or device manager. Im going to hope its something wrong with the Teensy and just order a new one.

This is the code I am pasting into the software. Now just in case any of this matters, I plug in the Teensy, open the arduino software and the loader, see the device, set the parameters in the software for - Board "teensy 2.0" and usb type to "keyboard+mouse+joystick" leave the rest alone, I delete everything out of the window and paste the code in and then flash it. Sound about right?
banjokazooie wrote:
Sun Oct 09, 2016 11:14 am

Code: Select all

const int  MODE = 15;    // the pin that the pushbutton is attached to
const int LED = 11;

int buttonPushCounter = 0;   // counter for the number of button presses
int buttonState = 0;         // current state of the button
int lastButtonState = 0;

void setup() {


  pinMode(0, INPUT_PULLUP);       // 01 Left Shoulder
  pinMode(1, INPUT_PULLUP);       // 02 Lelf Trigger
  pinMode(2, INPUT_PULLUP);       // 03 Right
  pinMode(3, INPUT_PULLUP);       // 04 Left
  pinMode(4, INPUT_PULLUP);       // 05 Up
  pinMode(5, INPUT_PULLUP);       // 06 Down
  pinMode(6, INPUT_PULLUP);       // 07 B
  pinMode(7, INPUT_PULLUP);       // 08 A
  pinMode(8, INPUT_PULLUP);       // 09 Right Trigger
  pinMode(LED, OUTPUT);           // LED
  pinMode(12, INPUT_PULLUP);      // 13 Start
  pinMode(13, INPUT_PULLUP);      // 14 Select
  pinMode(14, INPUT_PULLUP);      // 15 Y
  pinMode(MODE, INPUT_PULLUP);    // HOME Button
  pinMode(18, INPUT_PULLUP);      // 19 Left Joystick Button
  pinMode(19, INPUT_PULLUP);      // 20 Right Joystick Button
  pinMode(22, INPUT_PULLUP);      // 23 Right Shoulder
  pinMode(23, INPUT_PULLUP);      // 24 X

//  Serial.begin(9600);

 }

void loop_joystick() {

if (digitalRead(0) == LOW) 
  {
        Joystick.button(1, 1);
  }
  else
  {
    Joystick.button(1, 0);
    }

if (digitalRead(1) == LOW)
  {
      Joystick.button(2, 1);
  }
  else
  {
      Joystick.button(2, 0);
  }

if (digitalRead(2) == LOW)
  {
  Joystick.button(3, 1);
  }
  else
  {
  Joystick.button(3, 0);
  }

if (digitalRead(3) == LOW)
  {
  Joystick.button(4, 1);
  }
  else
  {
  Joystick.button(4, 0);
  }

if (digitalRead(4) == LOW)
  {
  Joystick.button(5, 1);
  }
  else
  {
  Joystick.button(5, 0);
  }

if (digitalRead(5) == LOW)
  {
  Joystick.button(6, 1);
  }
  else
  {
  Joystick.button(6, 0);
  }

if (digitalRead(6) == LOW)
  {
  Joystick.button(7, 1);
  }
  else
  {
  Joystick.button(7, 0);
  }

if (digitalRead(7) == LOW)
  {
  Joystick.button(8, 1);
  }
  else
  {
  Joystick.button(8, 0);
  }

if (digitalRead(8) == LOW)
  {
  Joystick.button(9, 1);
  }
  else
  {
  Joystick.button(9, 0);
  }

if (digitalRead(12) == LOW)
  {
  Joystick.button(13, 1);
  }
  else
  {
  Joystick.button(13, 0);
  }

if (digitalRead(13) == LOW)
  {
  Joystick.button(14, 1);
  }
  else
  {
  Joystick.button(14, 0);
  }
  
if (digitalRead(14) == LOW)
  {
  Joystick.button(15, 1);
  }
  else
  {
  Joystick.button(15, 0);
  }
  

if (digitalRead(18) == LOW)
  {
  Joystick.button(19, 1);
  }
  else
  {
  Joystick.button(19, 0);
  }

if (digitalRead(19) == LOW)
  {
  Joystick.button(20, 1);
  }
  else
  {
  Joystick.button(20, 0);
  }

if (digitalRead(22) == LOW)
  {
  Joystick.button(23, 1);
  }
  else
  {
  Joystick.button(23, 0);
  }

if (digitalRead(23) == LOW)
  {
  Joystick.button(24, 1);
  }
  else
  {
  Joystick.button(24, 0);
}

  int rX = analogRead(4);
    rX = (rX - 512) * 1.5 + 512;
  if (rX > 1023)
    rX=1023;  
  if (rX < 0)
    rX = 0;
  
  int rY = analogRead(5);
    rY = (rY - 512) * 1.5 + 512;
  if (rY > 1023)
    rY=1023;   
  if (rY < 0)
    rY = 0;
    rY=abs(1023-rY);

  int rL = analogRead(0);
    rL = (rL - 512) * 1.5 + 512;
  if (rL > 1023)
    rL=1023;  
  if (rL < 0)
    rL = 0;
  
  int rR = analogRead(1);
    rR = (rR - 512) * 1.5 + 512;
  if (rR > 1023)
    rR=1023;   
  if (rR < 0)
    rR = 0;
    //rR=abs(1023-rR);
 
  Joystick.X(rX);
  Joystick.Y(rY);
  Joystick.sliderLeft(rL);
  Joystick.sliderRight(rR);
}

  
void loop_keyboard() {

    if (digitalRead(4) == LOW)
  {
    Keyboard.press(KEY_UP);
  }
  else
  {
    Keyboard.release(KEY_UP);
   }
   
  if (digitalRead(5) == LOW)
  {
    Keyboard.press(KEY_DOWN);
  }
  else
  {
    Keyboard.release(KEY_DOWN);
  }
   
  if (digitalRead(3) == LOW)
  {
    Keyboard.press(KEY_LEFT);
  }
  else
  {
    Keyboard.release(KEY_LEFT);
  }
  
  if (digitalRead(2) == LOW)
  {
    Keyboard.press(KEY_RIGHT);
  }
  else
  {
    Keyboard.release(KEY_RIGHT);
  }

  //buttons
  if (digitalRead(0) == LOW)
  {
    Keyboard.press(KEY_ENTER);
  }
  else
  {
    Keyboard.release(KEY_ENTER);
  }
  if (digitalRead(1) == LOW)
  {
    Keyboard.press(KEY_ESC);
  }
  else
  {
    Keyboard.release(KEY_ESC);
  }

if (digitalRead(22) == LOW)
  {
    Keyboard.press(KEY_LEFT_CTRL);
  }
  else
  {
    Keyboard.release(KEY_LEFT_CTRL);
  }

  if (digitalRead(8) == LOW)
  {
    Keyboard.press(KEY_LEFT_ALT);
  }
  else
  {
    Keyboard.release(KEY_LEFT_ALT);
  }

if (digitalRead(7) == LOW)
  {
    Keyboard.press(KEY_A);
  }
  else
  {
    Keyboard.release(KEY_A);
  }
  if (digitalRead(6) == LOW)
  {
    Keyboard.press(KEY_B);
  }
  else
  {
    Keyboard.release(KEY_B);
  }
  if (digitalRead(14) == LOW)
  {
    Keyboard.press(KEY_Y);
  }
  else
  {
    Keyboard.release(KEY_Y);
  }
  if (digitalRead(23) == LOW)
  {
    Keyboard.press(KEY_X);
  }
  else
  {
    Keyboard.release(KEY_X);
  }

  if (digitalRead(12) == LOW)
  {
    Keyboard.press(KEY_F12);
  }
  else
  {
    Keyboard.release(KEY_F12);
  }
   if (digitalRead(13) == LOW)
  {
    Keyboard.press(KEYPAD_5);
  }
  else
  {
    Keyboard.release(KEYPAD_5);
  }

}


void loop() {

  buttonState = digitalRead(MODE);
  if (buttonState != lastButtonState) {
  if (buttonState == HIGH) {
    buttonPushCounter++;
//    Serial.println("on");
//      Serial.print("number of button pushes:  ");
//      Serial.println(buttonPushCounter);
} 
    else {
//  Serial.println("off");
    }
  }
  lastButtonState = buttonState;
  
 if (buttonPushCounter % 2 == 0) {
    digitalWrite(LED, HIGH);
  } else {
   digitalWrite(LED, LOW);
  }
  

    if (digitalRead(LED) == LOW)
  {
     loop_joystick();
  }
  else
  {
    
     loop_keyboard();
  }
  }


Re: WII U RASPBERRY PI 3 FINISHED

Posted: Mon Feb 04, 2019 6:56 am
by VeteranGamer
blu3rav3n wrote:
Mon Feb 04, 2019 6:29 am
VeteranGamer wrote:
Wed Jan 30, 2019 8:13 am

Then it’s obviously something wrong with the PC your using....

Maybe check your connections via device manager and delete what ever comes up as the Teensy...
Check that you’ve selected the correct device in the Arduino software (including the right Comm port)


But
If it’s recognised by another PC....
Then just reflash the correct script on the Teensy using that PC



.
So I tried 4 other pcs I have all with the exact same results. Plug it in, arduino software sees it, flash it, gone - cant see the device in the software or device manager. Im going to hope its something wrong with the Teensy and just order a new one.

This is the code I am pasting into the software. Now just in case any of this matters, I plug in the Teensy, open the arduino software and the loader, see the device, set the parameters in the software for - Board "teensy 2.0" and usb type to "keyboard+mouse+joystick" leave the rest alone, I delete everything out of the window and paste the code in and then flash it. Sound about right?
banjokazooie wrote:
Sun Oct 09, 2016 11:14 am

Code: Select all

const int  MODE = 15;    // the pin that the pushbutton is attached to
const int LED = 11;

int buttonPushCounter = 0;   // counter for the number of button presses
int buttonState = 0;         // current state of the button
int lastButtonState = 0;

void setup() {


  pinMode(0, INPUT_PULLUP);       // 01 Left Shoulder
  pinMode(1, INPUT_PULLUP);       // 02 Lelf Trigger
  pinMode(2, INPUT_PULLUP);       // 03 Right
  pinMode(3, INPUT_PULLUP);       // 04 Left
  pinMode(4, INPUT_PULLUP);       // 05 Up
  pinMode(5, INPUT_PULLUP);       // 06 Down
  pinMode(6, INPUT_PULLUP);       // 07 B
  pinMode(7, INPUT_PULLUP);       // 08 A
  pinMode(8, INPUT_PULLUP);       // 09 Right Trigger
  pinMode(LED, OUTPUT);           // LED
  pinMode(12, INPUT_PULLUP);      // 13 Start
  pinMode(13, INPUT_PULLUP);      // 14 Select
  pinMode(14, INPUT_PULLUP);      // 15 Y
  pinMode(MODE, INPUT_PULLUP);    // HOME Button
  pinMode(18, INPUT_PULLUP);      // 19 Left Joystick Button
  pinMode(19, INPUT_PULLUP);      // 20 Right Joystick Button
  pinMode(22, INPUT_PULLUP);      // 23 Right Shoulder
  pinMode(23, INPUT_PULLUP);      // 24 X

//  Serial.begin(9600);

 }

void loop_joystick() {

if (digitalRead(0) == LOW) 
  {
        Joystick.button(1, 1);
  }
  else
  {
    Joystick.button(1, 0);
    }

if (digitalRead(1) == LOW)
  {
      Joystick.button(2, 1);
  }
  else
  {
      Joystick.button(2, 0);
  }

if (digitalRead(2) == LOW)
  {
  Joystick.button(3, 1);
  }
  else
  {
  Joystick.button(3, 0);
  }

if (digitalRead(3) == LOW)
  {
  Joystick.button(4, 1);
  }
  else
  {
  Joystick.button(4, 0);
  }

if (digitalRead(4) == LOW)
  {
  Joystick.button(5, 1);
  }
  else
  {
  Joystick.button(5, 0);
  }

if (digitalRead(5) == LOW)
  {
  Joystick.button(6, 1);
  }
  else
  {
  Joystick.button(6, 0);
  }

if (digitalRead(6) == LOW)
  {
  Joystick.button(7, 1);
  }
  else
  {
  Joystick.button(7, 0);
  }

if (digitalRead(7) == LOW)
  {
  Joystick.button(8, 1);
  }
  else
  {
  Joystick.button(8, 0);
  }

if (digitalRead(8) == LOW)
  {
  Joystick.button(9, 1);
  }
  else
  {
  Joystick.button(9, 0);
  }

if (digitalRead(12) == LOW)
  {
  Joystick.button(13, 1);
  }
  else
  {
  Joystick.button(13, 0);
  }

if (digitalRead(13) == LOW)
  {
  Joystick.button(14, 1);
  }
  else
  {
  Joystick.button(14, 0);
  }
  
if (digitalRead(14) == LOW)
  {
  Joystick.button(15, 1);
  }
  else
  {
  Joystick.button(15, 0);
  }
  

if (digitalRead(18) == LOW)
  {
  Joystick.button(19, 1);
  }
  else
  {
  Joystick.button(19, 0);
  }

if (digitalRead(19) == LOW)
  {
  Joystick.button(20, 1);
  }
  else
  {
  Joystick.button(20, 0);
  }

if (digitalRead(22) == LOW)
  {
  Joystick.button(23, 1);
  }
  else
  {
  Joystick.button(23, 0);
  }

if (digitalRead(23) == LOW)
  {
  Joystick.button(24, 1);
  }
  else
  {
  Joystick.button(24, 0);
}

  int rX = analogRead(4);
    rX = (rX - 512) * 1.5 + 512;
  if (rX > 1023)
    rX=1023;  
  if (rX < 0)
    rX = 0;
  
  int rY = analogRead(5);
    rY = (rY - 512) * 1.5 + 512;
  if (rY > 1023)
    rY=1023;   
  if (rY < 0)
    rY = 0;
    rY=abs(1023-rY);

  int rL = analogRead(0);
    rL = (rL - 512) * 1.5 + 512;
  if (rL > 1023)
    rL=1023;  
  if (rL < 0)
    rL = 0;
  
  int rR = analogRead(1);
    rR = (rR - 512) * 1.5 + 512;
  if (rR > 1023)
    rR=1023;   
  if (rR < 0)
    rR = 0;
    //rR=abs(1023-rR);
 
  Joystick.X(rX);
  Joystick.Y(rY);
  Joystick.sliderLeft(rL);
  Joystick.sliderRight(rR);
}

  
void loop_keyboard() {

    if (digitalRead(4) == LOW)
  {
    Keyboard.press(KEY_UP);
  }
  else
  {
    Keyboard.release(KEY_UP);
   }
   
  if (digitalRead(5) == LOW)
  {
    Keyboard.press(KEY_DOWN);
  }
  else
  {
    Keyboard.release(KEY_DOWN);
  }
   
  if (digitalRead(3) == LOW)
  {
    Keyboard.press(KEY_LEFT);
  }
  else
  {
    Keyboard.release(KEY_LEFT);
  }
  
  if (digitalRead(2) == LOW)
  {
    Keyboard.press(KEY_RIGHT);
  }
  else
  {
    Keyboard.release(KEY_RIGHT);
  }

  //buttons
  if (digitalRead(0) == LOW)
  {
    Keyboard.press(KEY_ENTER);
  }
  else
  {
    Keyboard.release(KEY_ENTER);
  }
  if (digitalRead(1) == LOW)
  {
    Keyboard.press(KEY_ESC);
  }
  else
  {
    Keyboard.release(KEY_ESC);
  }

if (digitalRead(22) == LOW)
  {
    Keyboard.press(KEY_LEFT_CTRL);
  }
  else
  {
    Keyboard.release(KEY_LEFT_CTRL);
  }

  if (digitalRead(8) == LOW)
  {
    Keyboard.press(KEY_LEFT_ALT);
  }
  else
  {
    Keyboard.release(KEY_LEFT_ALT);
  }

if (digitalRead(7) == LOW)
  {
    Keyboard.press(KEY_A);
  }
  else
  {
    Keyboard.release(KEY_A);
  }
  if (digitalRead(6) == LOW)
  {
    Keyboard.press(KEY_B);
  }
  else
  {
    Keyboard.release(KEY_B);
  }
  if (digitalRead(14) == LOW)
  {
    Keyboard.press(KEY_Y);
  }
  else
  {
    Keyboard.release(KEY_Y);
  }
  if (digitalRead(23) == LOW)
  {
    Keyboard.press(KEY_X);
  }
  else
  {
    Keyboard.release(KEY_X);
  }

  if (digitalRead(12) == LOW)
  {
    Keyboard.press(KEY_F12);
  }
  else
  {
    Keyboard.release(KEY_F12);
  }
   if (digitalRead(13) == LOW)
  {
    Keyboard.press(KEYPAD_5);
  }
  else
  {
    Keyboard.release(KEYPAD_5);
  }

}


void loop() {

  buttonState = digitalRead(MODE);
  if (buttonState != lastButtonState) {
  if (buttonState == HIGH) {
    buttonPushCounter++;
//    Serial.println("on");
//      Serial.print("number of button pushes:  ");
//      Serial.println(buttonPushCounter);
} 
    else {
//  Serial.println("off");
    }
  }
  lastButtonState = buttonState;
  
 if (buttonPushCounter % 2 == 0) {
    digitalWrite(LED, HIGH);
  } else {
   digitalWrite(LED, LOW);
  }
  

    if (digitalRead(LED) == LOW)
  {
     loop_joystick();
  }
  else
  {
    
     loop_keyboard();
  }
  }



have you actually connected the Teensy up to a RPi and see if it recognizes it.....
(because that's all that really matters)





.

Re: WII U RASPBERRY PI 3 FINISHED

Posted: Mon Feb 04, 2019 7:32 am
by blu3rav3n
VeteranGamer wrote:
Wed Jan 30, 2019 8:13 am


have you actually connected the Teensy up to a RPi and see if it recognizes it.....
(because that's all that really matters)

.
Yup I did try, and when I load into retropi and launch the controller config and plug in the Teensy it dosnt recognize it or any of the button pushes.