MemCARDuino

November 9, 2024 ยท View on GitHub

Arduino PlayStation 1 Memory Card reader

memcarduino

Supported platforms:

  • Arduino Uno, Duemilanove, Diecimila, Nano, Mini, Fio (ATmega168/P or ATmega328/P)
  • Arduino Leonardo, Micro (ATmega32U4)
  • Arduino Mega 2560
  • Espressif ESP8266, ESP32 (requires additional board URL)
  • Raspberry Pi Pico (requires additional board URL)
  • Logic Green LGT8F328P (requires additional board URL)

Various other boards can be supported if they have Arduino core available with SPI library with minimal or no editing to the sketch.

Warning

Some Arduino boards use 5V logic and are not recommended. Connecting it straight may shorten lifespan of your MemoryCard or damage it permanently as it is a 3.6V device. Use a lever shifter for data lines and power the memory card with 3.6 power supply.

Connecting a Memory Card to Arduino:

Looking at the Memory Card:
_________________
|_ _|_ _ _|_ _ _|
 1 2 3 4 5 6 7 8
 
Memory CardUno, Nano, etcLeonardo, MicroMega 2560ESP8266ESP32Pi Pico
1: DataD12ICSP MISOD50GPIO12 (D6)GPIO19GP16
2: CommandD11ICSP MOSID51GPIO13 (D7)GPIO23GP19
3: 7.6VSee 7.6V noteSee 7.6V noteSee 7.6V noteSee 7.6V noteSee 7.6V noteSee 7.6V note
4: GndGndGndGndGndGndGnd
5: 3.6VSee VCC note3.3V3.3V3.3V3.3V3.3V
6: AttentionD10D10D53GPIO15 (D8)GPIO5GP17
7: ClockD13ICSP SCKD52GPIO14 (D5)GPIO18GP18
8: AcknowledgeD2D2D2GPIO2 (D4)GPIO22GP20

VCC note: Memory Card is a 3.6V device. Connect it to either 3.3V provided by the board or use external 3.6 power supply.
Old Arduino uses 5V logic and it is not recommended. It may shorten lifespan of your MemoryCard or damage it permanently.

7.6V note: This is only required for 3rd party Memory Cards and knockoffs.
Use external 7.6V power supply or if you are lucky you can get by with using 5V provided by the USB.

Reading saves from a PC:

To read saves from the Memory Card to your PC use MemcardRex if you are using Windows.
Make sure to use the latest version because MemCARDuino now runs at 115200bps while older releases used 38400bps.

For other operating systems you can use a provided Python script.

Before using install pyserial:

pip3 install pyserial

Usage:

python3 memcarduino.py -p,--port <serial port> , -r,--read <output file> OR -w,--write <input file> OR -f,--format , [-c,--capacity <capacity>] , [-b,--bitrate <bitrate:bps>]

<serial port> accepts COM port names, or for linux, file references (/dev/tty[...] or others)
<output file> read from memory card and save to file
<input file> read from file and write to memory card (accepts both windows and linux file URI's)
<capacyty> sets memory card capacity [blocks] *1 block = 128 B* (default 1024 blocks)
<bitrate> sets bitrate on serial port (default 115200 bps)

Pocketstation commands:

--psinfo (print info from pocketstation)
--psbios <output file> (dump bios from pocketstation)
--pstime (appy pc time to pocketstation)

This requires a serial port (/dev/ttyACM0 for Arduino uno's, /dev/ttyUSBX for others, COMX for Windows, and various for macOS).

Thanks to:

  • Martin Korth of the NO$PSX - documented Memory Card protocol.
  • Andrew J McCubbin - documented PS1 SPI interface.