User Tools

Site Tools


project:gba

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

project:gba [2007/04/27 00:21] (current)
Line 1: Line 1:
 +====== Game Boy Advance ======
 +Originally this page was written as part of my project'​s scrap-book, however it has come to my attention that other sites are linking to this page for info on how to use the GBA serial port, if you are looking for this information,​ please consult '​[[:​project:​gba:​code#​commsprobe|CommsProbe]]'​ and '​[[:​project:​gba:​code#​rs232_terminal|RS232 Terminal]]'​ in the [[:​project:​gba:​code]] section.
  
 +CommsProbe allows the serial port of the GBA to be misused as a general purpose I/O port (allowing each of the 4 data pins to be induvidually set as input or output).
 +
 +RS232 Terminal uses the GBA serial port for rs232 serial data, suitable for connection to the serial port of a PC //via suitable level conversion logic// --- **a PC serial port runs a +/-12V and direct connection to the GBA serial port will probably have regrettable results**. That said, it is likely that the PC will be happy with the 0/+3.3V logic that the GBA uses. You can use HyperTerminal to send and recieve ASCII data on the serial port, but be warned that if you have ScrollLock on HyperTerminal will pause, and you will believe your system to be broken. I found out the hard way.
 +
 +To make things easier for you I have extracted pre-compiled versions of the above, with their instructions,​ from my project report disc (which can be found on the [[:​project]] page). Please note that RS232 Terminal is called ''​UARTTest''​ in this download.
 +
 +{{project:​gba_comms.zip|Download GBA_Comms.zip (85.3KB)}}
 +
 +===== Code =====
 +See [[project:​gba:​code]].
 +
 +//Note that complete code is available on the project report disc (see [[:​project]]),​ ready for
 +compiling. The above links to only the "​interesting"​ parts of the code.//
 +
 +===== Communications Port =====
 +
 +Cutting up an **offical GBA link cable** (as the unofficial one didn't have all
 +the pins necessary for serial / general-purpose IO connected to wires) so I
 +can measure the voltages of the GBA and connect it to a circuit board.
 +
 +==== Physical interface ====
 +
 +{{project:​gba-link-plug.png}} {{project:​gba-link-socket.jpg}} Pin out of the GBA connector plug (cable receeding into page) and socket.
 +
 +^ Colour ^ Pin# ^ Pin Name           ^ UART Role ^ Voltage (logic 1) ^
 +|        | 1    | V<​sub>​CC</​sub> ​    ​| ​          ​| ​                  |
 +| Red    | 2    | **SO** SerialOut ​  | Tx        | 3.31V             |
 +| Orange | 3    | **SI** SerialIn ​   | Rx        | 3.31V             |
 +| Brown  | 4    | **SD** SerialData ​ | RTS       | 3.31V             |
 +| Green  | 5    | **SC** SerialClock | CTS((On GBA power-up this is an output, so a 1K Ohm resistor ought to be inserted between this and any voltage convertor logic to prevent to output from shorting each  other out. See [[http://​www.devrs.com/​gba/​files/​gbadevfaqs.php#​PCGCable|DevRS.com]])) ​      | 3.31V             |
 +| Blue   | 6    | GND                |           ​| ​                  |
 +
 +Observations:​
 +  * <​del>​Voltages are consistent to +/- 0.05V on both a GBA and a GBA:SP. It seems there are slight differences between the voltages on each pin.</​del>​ Actually it seems this is not so, perhaps the wires had different resistances on the unoffical cable?
 +  * Apparently when you use a GB/​GBC((Game Boy / Game Boy Colour: The predecessor to the Game Boy Advance, which is backwards compatable with these formats)) the voltages are 0/5V
 +  * When the pins are set as input, but not connected to anything they float high, and the bits in the register are set to 1 accordingly.
project/gba.txt · Last modified: 2007/04/27 00:21 (external edit)