Skip to content
/ TZXDuino Public
forked from sadken/TZXDuino

The cassette player replacement.

Notifications You must be signed in to change notification settings

Jujan/TZXDuino

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

TZXDuino

Arduino based TZX and TAP (currently only ZX spectrum and Amstrad CPC flavour) file player.
(Excuse the badly written code, I'm working on that ;) )

Parts Used

  1. Arduino (I used a Nano, but this should work on any Nano compatible.)
  2. SD Card module
  3. 16x2 I2C LCD
  4. Small audio amplifier. (I used an LM386 module, but any headphone type amplifier should work.)
  5. 5 x Buttons (Micro switches are the best, but any should work.)

Installation

Not All Libraries Are Equal!

With so many variations on the SD, LCD I2C and TimerOne libraries I thought I'd include them here. So to prevent any hair pulling moments use these versions of the libraries.

Wiring

All buttons and the motor control pull the pin to GND.

Arduino pins:
  D6 -> MOTOR CONTROL (Connected to one side of the 2.5mm socket. Only used on some CPC models.)
  D7 -> BUTTON (ROOT)
  D9 -> Output (To amplifier)
D10 -> SDCS (SD Card chip select)
D11 -> MOSI (SD Card MOSI pin)
D12 -> MISO (SD Card MI/MISO pin)
D13 -> SCK (SD Card SCK pin)
  A0 -> BUTTON (DOWN)
  A1 -> BUTTON (UP)
  A2 -> BUTTON (STOP)
  A3 -> BUTTON (PLAY)
  A4 -> LCD SDA
  A5 -> LCD SCL

LCD pins:
 SDA -> Arduino A4
  SCL -> Arduino A5
 VCC -> 5V
GND -> GND

SD Card pins:
     5V -> 5V
 GND -> GND
SDCS -> D10 Arduino
MOSI -> D11 Arduino
MISO -> D12 Arduino
   SCK -> D13 Arduino

Usage

Wire up as above, and program the Arduino using the IDE.

Copy some TZX/TAP/CDT files onto a FAT32 formatted SD Card, plug it into the TZXDuino and power it on.

I suggest to format SD Card with this tool to ensure maximum compatibility.
SD Memory Card Formatter 5.0 for SD/SDHC/SDXC
CAUTION: Formatting will cause complete data loss on SD Card. Make sure to backup the SD Card before formatting

Button functions:

  • UP/DOWN - No playback: move through the files
    During playback: Works as PREVIOUS/NEXT file.
  • PLAY - On file: starts playback.
    On directory: open directory.
  • STOP - During playback: stops playback.
    No playback: up a directory.
  • ROOT - During playback: restart playback.
    No playback: set TSX Baud Rate

To get files to load first time you'll need to adjust the volume until you get a strong signal on the Spectrum / CPC.
Once you've got a strong signal you should able to load most files as if you were using a normal tape.

History

Starting with the Arduitape WAV playing project. I've moved to playing TZX and TAP files directly without needing to convert them to a WAV file first.

Credits

Code: Andrew Beer

Testing: Duncan Edwards

Code update: Jujan

About

The cassette player replacement.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C++ 87.5%
  • C 12.1%
  • Objective-C 0.4%