Browse Source

Convert README to github markdown

pull/2/head
Daniel Schaal 5 years ago
parent
commit
08bb4ef448
  1. 21
      README.md

21
README → README.md

@ -1,16 +1,16 @@ @@ -1,16 +1,16 @@
Arduino N64 Controller Library
# Arduino N64 Controller Library
Based on the work in http://www.instructables.com/id/Use-an-Arduino-with-an-N64-controller/ here comes a comfortable library for usage with e.g. Arduino Uno. For NES there is already http://code.google.com/p/nespad/ . This library uses inline assembly and controllers can be attached to PIN 0 up to 13. But be aware that it's not written in best way possible. Place the folder N64Controller into your folder 'libraries'.
I used it in combination with TVout ( http://code.google.com/p/arduino-tvout/ ) and EEPROM ( http://arduino.cc/playground/Code/EEPROMWriteAnything ) for highscore I modified an existing Tetris port which itself uses Simple Tetris Clone under MIT license to be useing this library here and the result is quite nice: http://pothos.blogsport.eu/files/2012/03/N64Tetris.zip
I used it in combination with TVout ( http://code.google.com/p/arduino-tvout/ ) and EEPROM ( http://arduino.cc/playground/Code/EEPROMWriteAnything ) for highscore I modified an existing Tetris port which itself uses Simple Tetris Clone under MIT license to be using this library here and the result is quite nice: http://pothos.blogsport.eu/files/2012/03/N64Tetris.zip
Example code for library usage:
## Example code for library usage
```cpp
#include <N64Controller.h>
#include <N64Controller.h>
N64Controller player1 (12); // this controler for player one is on PIN 12
N64Controller player1 (12); // this controller for player one is on PIN 12
void setup() {
player1.begin(); // Initialisation
@ -26,22 +26,27 @@ void loop() { @@ -26,22 +26,27 @@ void loop() {
}
// …
}
```
Wireing:
## Wireing
To use, hook up the following to the Arduino:
Digital I/O 2: N64 serial line
All appropriate grounding and power lines, i.e.
GND to left N64 controller PIN, Dig.PIN2 to middle Serial/Signal,
3.3V to right N64 PIN
```
/------------\
/ O O O \
| GND Signl 3.3V |
|________________|
```
Maybe: connect PIN X with external 1K pull-up resistor to the 3.3V rail
Default and fallback PIN is 2
## Authors
Gamecube controller to Nintendo 64 adapter
by Andrew Brown
Loading…
Cancel
Save