Skip to content

MiSTle-Dev/NanoApple2

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

62 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Nano Apple IIe

The Nano Apple IIe is a port of both MiSTer and MiST FPGA core components for the Apple IIe computer:

Board FPGA support Note
Tang Nano 20k GW2AR HDMI
Tang Console 60K NEO GW5AT-60 HDMI / LCD
Tang Console 138K NEO GW5AST-138 HDMI / LCD
Tang Mega 60k NEO GW5AT-60 HDMI / LCD
Tang Mega 138k Pro GW5AST-138 HDMI / LCD
Tang Primer 25K GW5A-25 HDMI no Dualshock

This project relies on a µC being connected to the FPGA. --> MiSTle-Dev wiki <--

Note

If you don't need the WIFI modem on a Nano20K/Primer25k then even the onboard BL616 µC (normally used for bitstream programming) can be used. A dedicated FPGA bitstream and FPGA companion firmware is needed in that configuration. The onboard BL616 µC is presently supported for TN20K, Console 60K, Primer25k, Mega138k Pro board. WIFI modem is supported on Console 60K too (requires antenna)

The project based on an Apple ][+ FPGA implementation.
Original for the DE2: https://www.cs.columbia.edu/~sedwards/apple2fpga/
Port for the MiST: http://ws0.org/tag/apple2/

All HID, SDcard and µC firmware by Till Harbaum

Features:

  • HDMI Video and Audio Output
  • TFT-LCD module 800x600 SH500Q01Z + Speaker support
  • USB Keyboard
  • USB Gamepad
  • USB XBOX 360 Controller
  • Dualshock 2 Controller Gamepad for MiSTeryShield20k / MiSTeryShield20kPico via spare pinheader
  • USB Mouse as AppleMouse or as Joystick
  • Disk loading via OSD. supported formats: .NIB
  • HDD loading via OSD. supported formats: .HDV (raw ProDOS partition images, 32MB)
  • Selectable 6502 or 65C02 CPU
  • Joystick support (analog proportional)
  • Mouse card in slot 5 (AppleMouse)
  • Scanlines
  • Monitor type: Color, amber, green and black&white
  • Selection of color palette (NTSC //e, Apple IIgs, AppleWin, Custom)
  • Loadable Custom Color Palette
  • Language card in slot 0
  • Super Serial Card (SSC) in slot 2
  • 64K base + 64K auxilary RAM with 80 column and double hi-res support
  • Mockingboard model A (two AY-3-8913 chips for six audio channels) in slot 4
  • Video ROM Switch (US /local UK)
  • Loadable 8K custom Video ROM (US / local)
  • SSC configuartion
  • Tape loading via the UART RX pin (ADT Pro)
  • Selectable mixed mode text color artifacts
  • FPGA Companion WIFI modem via SSC (M0S Dock, PiPico W, Console 60K onboard BL616)

image

Tip

Be aware that this core loads .NIB Disk Drive images only identical to the MIST core.
On the fly conversion from .DSK as the MISTer core is doing using Linux host system is not supported.

Tang Console 60k / 138K NEO

See Tang Console 60K / 138K NEO

Tang Mega 60k NEO

See Tang Mega 60K NEO

Tang Mega 138K Pro

See Tang Mega 138K Pro

Installation

The installation on the Tang Nano 20k board can be done using a Linux PC or a Windows PC Instruction.

Keyboard

  • Win/Cmd Key - Closed Apple
  • Alt Key - Open Apple
  • Key F2 toggle RESET
  • Key F12 OSD

Push Button utilization

  • S1 reserved
  • S2 open OSD

Apple II slot assignments

  • Slot 0 - language card (memory expansion)
  • Slot 1 - not populated
  • Slot 2 - Super Serial Card (SSC)
  • Slot 3 - 80 col + 64K RAM expansion (//e)
  • Slot 4 - Mockinboard model A (six audio channels)
  • Slot 5 - Mouse Card
  • Slot 6 - Disk Drive controller
  • Slot 7 - Hard Disk Drive controller

Disk format notes

Use dsk2nib to convert AppleII disk images to .nib images.

For HDD, only HDV images (raw ProDOS partition images) 32MB in size are supported.
A Cold Reset is needed to boot from HDD. 2MG images may work if the 64-byte header is removed.

dd if=diskimage.2mg of=diskimage.hdv bs=64 skip=1

Instructions

On the "Apple ][" boot screen open the OSD with F12 and choose a disk. It will boot the disk automatically.

If you OSD press reset you'll enter Applesoft with the ] prompt. From here you have some limited commands. See: http://www.landsnail.com/a2ref.htm.

If you want to boot another disk choose a .nib image via the osd and type the following:

]PR#6

or

]CALL -151`
*C600G

The HDD interface is in slot 7. Unlike the floppy interface, it does not stall until an image is mounted, so either press OSD cold reset or use one of the following after mounting an image:

]PR#7

or

]CALL -151`
*C700G

OSD

invoke by F12 keypress

  • Reset
  • Cold Reset
  • Audio Volume + / -
  • Scanlines effect %
  • Monitor type
  • Color Palette
  • SSC, HDD, MB, MOUSE disable/ enable
  • CPU type
  • HID device selection for Joystick Port
  • Invert Joystick X/Y
  • Video ROM switch
  • SSC Baudrate, Parity, Mode

Gamecontrol support

USB Gamepad Stick as Joystick (no DPAD). OSD: USB #1 or USB #2
Button A and B Buttons as Trigger:

or
Dualshock 2 Gamepad Stick as Joystick. OSD: DS #1 or DS #2

square and cross Buttons as Trigger:

Important

In a MiSTeryShield20k configuration Dualshock is supported via the spare J8 pinheader.
See MiSTeryShield20k DS2 Adapter / Cable for further information. Thx venice1200 !

Note

TN20k: You have to select OSD "DS2 #2 Joy" for a MiSTeryShield20k configuration.
TN20k: You have to select OSD "DS2 #1 Joy" if you use the Sipeed Joy to DIP adapter.

or Mouse. OSD: Mouse
USB Mouse as Joystick.

LED UI

LED function TN9K TN20K TP20K TP25K TM60K TM138k Pro Console60k/138k
0 FDD1 activity - x - x x x x
1 FDD2 activity - x - x x x x
2 FDD1 mounted - x - - - x -
3 FDD2 mounted - x - - - x -
4 HDD mounted - x - - - x -
5 unused - x - - - - -

Multicolor RGB LED

  • green      all fine and ready to go
  • red          something wrong with SDcard / default boot image
  • blue        µC firmware detected valid FPGA core
  • yellow      FPGA core can't detect valid firmware
  • white      -

Powering

Circuit with Keyboard can be powered by Tang USB-C connector from PC or a Power Supply Adapter.

Synthesis

Source code can be synthesized, fitted and programmed with GOWIN IDE Windows or Linux.
Alternatively use the command line build script gw_sh.exe build_tn20k.tcl

SSC RS232 Serial Interface WIFI Modem

Have a look: Wiki WIFI Modem

Connect to you WIFI AP and have a try: ATD bbs.retrocampus.com:23 or just have a look at telnetbbsguide and choose as you like.

HW circuit considerations

Pinmap TN20k Interfaces

Sipeed M0S Dock and DualShock Gamepad connection.
wiring

Pinmap Dualshock 2 Controller Interface (Port #DS1)

image

DS pin Tang Nano pin FPGA pin DS Function
1 J5 18 71 MISO JOYDAT
2 J5 19 53 MOSI JOYCMD
3 n.c. - 7V5
4 J5 15 - GND
5 J5 16 - 3V3
6 J5 17 72 CS JOYATN
7 J5 20 52 MCLK JOYCLK
8 n.c. - JOYIRQ
9 n.c. - JOYACK