blob: da7ca081008e148037c868a2814ea012d62ba7b4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
// GameCube controller to USB adapter
// Copyright (C) 2014 Florian Jung
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License version 3 as
// published by the Free Software Foundation.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
/* Setup:
lfuse: 0xe0
hfuse: 0xd9
attach a 12MHz quartz to the atmega8, using the appropriate XTAL pins.
connect avr.PD{2,3} over 68 Ohm to usb.DATA{+,-}
connect usb.DATA{+,-} over 3v6-Z-Diode ( ----|<---- ) to GND
connect usb.DATA- over 1.5kOhm to usb.Vcc
connect usb.GND to avr.GND.
supply 3.3V to the 3.3V line of the gamecube controller.
supply 5V to the 5V line of the gamecube controller.
connect the GND and SHIELD lines of the controller to the common GND.
connect the DATA line of the gamecube controller to the C5 pin.
!!! ensure that the PORTC has bit 0 cleared at any time. !!!
!!! otherwise, +5V is supplied to the pin; the gamecube !!!
!!! controller, however, may shortcut the line down to !!!
!!! GND at any time, leading to HARDWARE DAMAGE. !!!
*/
|