Skip to content

blitztide/GB-OBDII

Repository files navigation

GB-OBDII

GB-OBDII is a hardware/software project where OBD-II scanning functionality is added to a Gameboy or Gameboy Colour, this is done by creating a custom cartridge for the Gameboy and also a custom connector for the OBD-II port which will convert from a gameboy link cable connection to a microcontroller which then converts the commands to something the vehicle will understand

Introduction

The General overview of the project is as follows:

Software Required

RGBDS - Rednex Game Boy Development System

Hardware

Custom GB Cartridge

WIP, not sure if going for fully custom board or a modified MBC5 cartridge with a new flash chip for use in further projects.

Custom OBD-II Daughterboard

This board will be powered via the OBD-II port and will convert the OBD-II port to RS232 for connection to a PC or the intermediate uController.

GB Link Cable Adapter

We will be utilising the following GB link cable adapter from PALMR throughout the project, they are available to order through OSH Park.

AllPro Adapter

The AllPro adapter is an open source OBD-II scanner that supports all ELM327 commands, by utilising this board as our starter board we can save valuable time in development. We can interface into the chip using RS232 Serial from our uController or a PC for debugging.

uController converter

This is currently planned to be an ATMega328P due to previous experience with the platform. We will be using this uController to convert the Gameboy link cable connection to a RS232 connection.

Custom PCB

WIP

Software

GB Cartridge firmware

Menus

WIP

Libraries

Standard Functions

Included in this library are the following functions:

StrCpy - Copy from DE to HL until 0x00 incrementing HL and DE

MemCpy - Copy from DE to HL for BC bytes

WaitVBlank - Wait until rLY==144 then return

Menu System

WIP

Microcontroller firmware

ATMega328P

We Will be using the Arduino bootloader and the ArdOBD library to interface with the AllPro Adapter, We will also use a custom library to interface with the GB Link cable.

Flashing

ICSP headers are on the board to program the device using a USBASP.

AllPro OBDII

This will use the original firmware provided at OBDDiag.net

Flashing

we can program the AllPro chip using the reccomended tools of a USB-Serial cable and the Flash Magic Tool. The image file is referenced at the bottom of this document.

References

  1. GB ASM Programming Guide
  2. GBCPU manual
  3. GB Programming Manual
  4. AllPro
  5. GB Link Cable
  6. AllPro Image File
  7. Flash magic
  8. GBDev Github

About

Gameboy OBDII Reader

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published