From IndividualComputers

Officially licensed Commodore Product

Final Prototype



The Commodore 64 Reloaded MK2 is a C64 Motherboard for building a C64 on your own. The board is shipped with empty ZIF sockets for the key chips such as CPU, port chips, sound/video chips. All other components are already assembled and pre-tested before shipment.

For building a C64 computer with this board, you need to supply the key chips on your own:

CPU 6510 or 8500

two pcs. CIA 6526 or 8521

video chip 6567, 6569, 8565 or 8562

one or two sound chips 6581 and/or 8580

The Commodore 64 Reloaded MK2 includes the following on the board:

all memory

flash rom for Kernal, Basic, Character and your own sets of ROMs

clock generator equivalent to the CSG8701 chip with two custom crystals

PLA equivalent to the CSG 906114-01 chip

Stereo-SID circuit configurable for three different popular addresses

S-Video and 3.5mm stereo outputs

USB to serial link for configuring the board with a terminal program

high-efficiency power conversion for operation from a single 12V supply

Power switch with integrated reset function

six all-black high quality ZIF sockets

User Information

The C64 Reloaded MK2 User Guide that comes with the board.

Overview

As opposed to the first C64 reloaded board, the C64 Reloaded MK2 will automatically identify the installed chips. It will not only generate the correct clocking, but also set the right voltages for the chips that you have chosen. Further, it configures the filter-capacitors for your favourite SID combination. This means that the Commodore 64 Reloaded MK2 is a completely jumper-free design.

C64 Reloaded MK2 fits in all original C64 cases: The classic "breadbox" cases and the flat versions of the case that were used in later production years. This includes the brand-new cases that were produced recently in a popular Kickstarter project, and of course our own C64 Cases.

all required voltages (5VDC, 9VAC) are generated on board and are available at external interfaces as expected (tape, userport, expansion port, joystick port). 12VDC is taken directly from the PSU. A protection circuit keeps excess input voltage from valuable chips.

The C64 Reloaded MK2 does not come with a TV-Modulator. There's an S-Video output in it's place, which is located in place of the RF output. At the S-Video output a 330Ohm resistor is installed in the chrominance line, which makes the signal more suitable for modern displays.

Audio is passed to the outside world through a 3.5mm stereo plug, which lets you use standard audio equipment. It is located in place of the channel switch, so no additional holes must be drilled into the computer case.

The known connectors for joysticks, cartridges, monitor, floppy drives, data cassette and userport are of course available on C64 Reloaded MK2.

The processor (CPU), the sound chip (SID), the I/O chips (CIA) and video chip (VIC-II) are in zero-insertion-force sockets, so they can be exchanged easily.

proper 50/60Hz signal for the CIA TOD clocks is generated on board depending on selected video mode. The time base for this is another crystal oscillator, which is running independent of the main C64 clock circuit.

All ROMs are kept together in one Flash-ROM. The board can be equipped with four Kernal ROMs (three custom) and two character ROMs (one custom).

the power switch is a 3-position switch that has a "momentary" up-position, which is used to reset the machine. This gives you a reset-button without the need to drill a hole into a classic case.

the power button "reset" switch and the RESTORE key can be configured to switch some configuration options

A video effect known as "VSP-effect" to the C64 scene leads to intermittent crashes of some C64 models, which is also known as the "VSP-bug". Since the C64 Reloaded MK2 boards use SRAM instead of DRAM, this problem has been eliminated.

gold plated user- and tape ports

Comes including metal frame around the expansion port, like the original computer.

the final board is black with white silkscreen print and uses custom black zif sockets

Power supply

Power supply available separately

The C64 Reloaded is shipped without a power supply. The power connector is a standard 12V DC plug, outer diameter 5.5mm, inner diameter 2.5mm or 2.1mm. When selecting your power supply, please double-check the polarity: The inner conductor must be "plus"! The power supply should be able to provide at least 1 amp of current. 2 amps is recommended if you want to operate the Commodore 64 Reloaded MK2 with power-hungry devices like the Commodore 1750 or a SuperCPU. For best picture- and sound quality, the power supply should have less than 100mV ripple on 12V.

Operating the C64 Reloaded MK2 on the supply of a car is not recommended. The voltage in a car is slightly too high and it would trigger the protection circuit of the C64 Reloaded MK2.

If you have a spare power supply from an unused xDSL or cable modem, please double-check the technical data. Power supplies from Nequester and Fritz!Box are known to work.

Chip compatibility

The C64 Reloaded MK2 can be equipped with NMOS or HMOS chips in all combinations. All ICs are automatically detected, making jumper changes unnecessary.

CPU

The C64 Reloaded MK2 can work either with the 6510 or with the 8500 CPU. You can NOT use any other CPU (such as the 6502), because it is missing essential features (IO port and tri-state address bus).

CIA

You can use 6526(A/B) or 8521 CIA chips. These have minor differences in IRQ/NMI behaviour, but are mostly compatible with the majority of software.

SID

NMOS version of the SID chip - the 6581 - or the HMOS versions, namely 8580 and 6582, can be used. The correct voltages and filter capacitors will be selected automatically (12V / 470pF for the 6581, 9V / 22nf for the 8580).

VIC-II

New and old PAL (6569 and 8565) and NTSC (6567 and 8562) versions of the VIC-II can be used. Voltages and clocks will be selected automatically. The type of VIC-II chip also defines the overall timing of the C64 reloaded MK2. Rare PAL-N versions of the VIC-II chip (6572) that were mainly sold in south America will not work. They can be activated with the factory test menu, but these settings can't be saved.

LEDs

Machine Status

Green (on board) Red (power) Status on on Running startup routine (about 1 second) off on Normal machine operation blinking on Warning state blinking blinking Error state, machine will likely not start correctly

When the machine is in error or warning state, additional info will be given in the main menu. Also the "chipset info" menu item (I) will show "unknown" when chip detection failed.

A common cause is simply bad socket connection (when using chips with oxydized pins).

Sources for reaching warning state:

SID 1 is not detected. VDD will be switched to 9 volt. The machine can still start, but there will be no audio or paddle support.

Sources for reaching error state:

VIC-II dection failed to recognise chip type based on average luma level.

VIC-II dection failed timeout when detecting first v-sync (no v-sync seen).

VIC-II dection failed because time between v-syncs is unexpected value.

CPU detection failed because PHI-2 is not toggling (permanently high or low).

In error state the VDD of the VIC-II is lowered to 5 volt and machine most likely will not start.

selected SID

When either RESTORE or RESET is configured to toggle between the two installed SIDs, the red (power) LED will indicate what SID has been selected. It will blink once for SID1 and twice for SID2.

Jumper pinouts

header CN4b signal names

header CN4b distance to mounting hole

CN4b: auxilary IEC

This connector is not installed by default. The holes have been kept free of solder during production, so it's easy to install a pin header in this place. However, any soldering on the C64 Reloaded MK2 will void warranty! CN4b has not been installed for safety reasons: Since an installed header has no protection at all, the Vcc pin may be shorted, and up to 20W of power would lead to severe damage. We therefore recommend to only install this pin header if you know what you're doing, and if you're aware that your warranty will be void with this modification.

In addition to IEC signals, this port also carries a few datasette signals, which will give you access to valuable CPU IO port pins. Pin number 1 of CN4b is marked with a square pad. All other pads of this connector are round. The drill size used for the holes is 0.89mm.

The horizontal distance to the mounting hole on the left is 61,82mm, the vertical distance is 0,62mm. When designing hardware to be mounted here consider the space limitations imposed by the lever of the zif socket next to the mounting hole - you can not use an erection bolt here.

Pin number Signal name 1 CASS_WRT (Datasette pin 5) 2 CASS_SENSE (Datasette pin 6) 3 Cassette motor control (CPU port pin P5, TTL-level) 4 IEC_SRQ 5 VCC (caution: unfused!) 6 IEC_ATN 7 IEC_CLK 8 IEC_DATA 9 Reset 10 GND

The remote control menu

The C64 Reloaded MK2 provides a remote control menu which can be accessed via a terminal connected to the USB link, which is located next to the tape connector.

Parameters: 19200Bps, 8 databits, No Parity 1 Stopbit (19200 8N1), No handshake (RTS/CTS is not connected)

Windows

For Windows we recommend Tera Term

To find out what COM port your C64r MK2 is connected to, plug in the USB cable and open the device manager. Look under COM & LPT for "Prolific USB-to-Serial Comm Port"

Start Tera Term, then configure the Port via Setup->Serial Port (select 19200Baud, 8N1) and press ALT+N to create a new connection, then select the COM port.

To send files using X-Modem use File->Transfer->XMODEM->Send

Linux

For Linux we recommend minicom.

To find out what interface name is being used, you can look it up in the system log like this:

sudo tail -f /var/log/messages

then plug the USB connection into your PC. the log will show a line like this:

Oct 30 3:13:37 localhost kernel: usb 3-13.4: pl2303 converter now attached to ttyUSB2

now you can start minicom like this:

sudo minicom -b 19200 -D /dev/ttyUSB2

Don't forget to disable Hardware Handshake, press CTRL+A, Z, O, "serial port settings"

To send files using X-Modem, press CTRL+A then S

macOS

Caution: The Prolific driver for macOS is really crappy. It keeps your system from shutting down, crashes if you insert/remove the USB connector a second time, and since there is no automatic de-installer, it is hard to remove from the system. You have been warned: We do not recommend to use this driver.

Download the driver for the version of your macOS from the Prolific website. After the driver has been installed, a new device will appear under

/dev/cu.usbserial

You can now connect to this interface with this command line:

screen /dev/cu.usbserial 19200

If you are truly an expert, you can install the lrzsz package (part of MacPorts) and also use the XModem transfer function using the good old sx command. Describing this procedure would go way beyond the scope of this Wiki. A good starting point is this tutorial. Once again, this is for low-level unix experts.

For all other Mac users, we recommend Serial. This program does not require installing a kernel mode driver, as it can talk to the Prolific chip on it's own. Further, it supports XModem transfers "out of the box", and it will be free for seven days.

Using the remote control Menu

Connect your C64reloaded MK2 to your PC via USB. Then start a terminal program and power on the C64reloaded. now you will see the welcome message:

**** Commodore C64 Reloaded MK2 V20171114 **** 128K SRAM System by individual Computers, PLA FREE READY (press key for menu)

In all menus press SPACE to show the current menu again. Press X to abort current function or leave menu.

To make interacting with the menus via non interactive scripts easier, a ? will be shown as a prompt when the menu is waiting for a selection.

Main menu

A - Audio output B - IEC burst option D - Remote debugging F - Factory tests I - Chipset info K - Configure Keys (RESTORE and RESET/POWER) L - Load default settings M - Memory and ROM selection R - Reset machine T - TOD clock frequency S - Stereo SID options U - Upload ROMs W - Write settings Z - Reinitialize memory and reload ROM images from flash

Audio Output

Press A to configure how the SIDs are routed to the audio output.

1 ==> Mono SID 1 2 - Mono SID 2 L - SID 1 Left, SID 2 Right R - SID 1 Right, SID 2 Left

The audio output at the DIN A/V connector will always get the left channel.

IEC burst option

0 ==> IEC burst option disabled (default) 1 - IEC burst with CIA1 (CN1 on SRQ, SP1 on DATA) 2 - IEC burst with CIA2 (CN2 on SRQ, SP2 on DATA)

Some drives, such as 1570/1571/1581/FD2000/FD4000, support "burst mode" for serial transfers. This is about 5-6 times faster than regular IEC bus transfers. To use this mode select the respective option (CIA1 is common, and compatible with the C128 software) and install a patched kernal (available eg here) or use a burst-capable fastloader. Please keep in mind that enabling this option may result in some incompatibilities with certain fastloaders, original software etc.

Remote debugging

C - Continue (after halt) H - Halt machine L - Display memory layout R - Read memory W - Write memory

Press H and C to halt and continue the CPU. This is achieved by pulling the DMA line, with all expected side effects.

Press L to see the memory layout of the internal RAM, the output will look like this:

00000-0FFFF C64 main memory 10000-11FFF Default Kernal ROM 12000-13FFF Custom Kernal ROM 1 14000-15FFF Custom Kernal ROM 2 16000-17FFF Custom Kernal ROM 3 18000-18FFF Last I/O write (copy) 18800-18BFF = Color RAM (r/w) 19000-19FFF <unused> 1A000-1BFFF BASIC ROM 1C000-1CFFF Custom Character ROM 1D000-1DFFF Default Character ROM 1E000-1FFFF <unused>

The area marked "Last I/O write (copy)" contains the last value(s) written to the I/O area, eg 18000 contains the last value written to D000.

Press R to show the contents of a memory range according to the above memory map. All entered values are in hexadecimal notation:

Enter start address in hexadecimal (Type 'X' to abort)?0300 Enter last address in hexadecimal (Type 'X' to abort)?031F 8B E3 83 A4 7C A5 1A A7 E4 A7 86 AE 00 00 00 00 4C 48 B2 00 31 EA 66 FE 47 FE 4A F3 91 F2 0E F2

Reading memory will halt the C64 reloaded MK2, use C to resume operation.

Press W to write to the memory. All entered values are in hexadecimal notation:

Enter start address in hexadecimal (Type 'X' to abort)?0400 000400?01020304 000404?050607

Press X after you entered the last value you want to write. Writing memory will halt the C64 reloaded MK2, use C to resume operation.

Chipset info

Press I to see which chips have been detected. You will see an output similar to this:

VIC-II: 8565 (73 00 AF55 PAL) SID 1 : 8580 (DD 00) SID 2 : 6581 (A5 CE) CPU : PHI2 OK (0457)

Press any key to go back to the main menu.

Configure Keys (RESTORE and RESET/POWER)

L - Configure long press RESET/POWER function P - Configure short press RESET/POWER function R - Configure long press RESTORE function

Configure long press RESET/POWER function

Press L to configure what function holding RESET for more than half a second will trigger:

1 - Toggle between default kernal and custom image 1 2 - Cycle through default kernal and custom image 1, 2 3 - Cycle through default kernal and all custom images C - Toggle between default and custom character ROM R ==> Reset machine S - Toggle between SID-1 and SID-2 (when set to mono)

Configure short press RESET/POWER function

Press P to configure what function holding RESET for less than half a second will trigger:

1 - Toggle between default kernal and custom image 1 2 - Cycle through default kernal and custom image 1, 2 3 - Cycle through default kernal and all custom images C - Toggle between default and custom character ROM R ==> Reset machine S - Toggle between SID-1 and SID-2 (when set to mono)

Configure long press RESTORE function

Press R to configure what function holding RESTORE for longer than half a second will trigger:

1 - Toggle between default kernal and custom image 1 2 - Cycle through default kernal and custom image 1, 2 3 - Cycle through default kernal and all custom images C - Toggle between default and custom character ROM R - Reset machine S ==> Toggle between SID-1 and SID-2 (when set to mono)

Load default settings

Press L to load factory default settings. Custom ROMs that have been uploaded are unaffected.

Factory default settings are as follows:

(A) Audio output = (1) Mono SID1 (B) IEC burst option = (0) Disabled (K L) Long press RESET/POWER = (R) Reset machine (K P) Short press RESET/POWER = (R) Reset machine (K R) Long press RESTORE = (S) Toggle between SID-1 and SID-2 (M C) Select character ROM = (D) Default character ROM (M E) Select extra image = (0) Unused (M I) Memory initialization pattern = (C) Emulate original DRAM pattern (M K) Select kernal ROM = (D) Use default kernal ROM (S) Stereo SID option = (1) Mono SID1 (T) TOD clock = (A) Auto

Memory and ROM selection

C - Select character ROM E - Select function of extra image I - Memory initialization pattern K - Select kernal ROM

Select character ROM

D ==> Use default character ROM U - Use custom character ROM

Select function of extra image

Press E to select what to use the extra ROM image for:

0 ==> Unused (default) B - BASIC ROM U - Copy to $8000-$9FFF on startup

The "Copy to $8000-$9FFF on startup" can be used for some standard 8k cartridge images - however keep in mind this is not a true "cartridge emulation", the image will be copied to C64 RAM at power-up!

Changes to this setting only take effect on the next powercycle (or use 'Z' in mainmenu)

Memory initialization pattern

C ==> Emulate original DRAM pattern Z - Fill memory with zeros

Select kernal ROM

D ==> Use default kernal ROM 1 - Use custom kernal ROM image 1 2 - Use custom kernal ROM image 2 3 - Use custom kernal ROM image 3

Reset machine

Press R to reset the C64 reloaded MK2. This has the same effect as pressing the reset button at the power switch.

Stereo SID options

Press S to change how the SID chips are mapped into memory.

1 ==> Mono SID 1 2 - Mono SID 2 4 - Stereo D420 5 - Stereo D500 B - Stereo D420 and D500 E - Stereo DE00

When a stereo mode is selected, SID 1 is the one that is mapped to D400.

Keep in mind that if you have a Chameleon connected, you will have to set up the mapping of the "SID Real Stereo Chip" to match your selection in this menu, and then select the actual effective mapping via "SID Emulation" setting in the chameleon menu.

TOD clock frequency

A ==> Auto 5 - 50 Hz 6 - 60 Hz

This menu lets you select the frequency used for TOD clock ticks. Normally this would be defined by your local power grid frequency (eg 60Hz in the US, 50Hz in Europe). "Auto" will use 50Hz when a PAL VICII was detected, and 60Hz when an NTSC VICII was detected. This way the C64 reloaded MK2 always operates under ideal conditions to match a common PAL or NTSC setup.

Upload ROMs

Press U to upload and flash custom ROM images.

1 - Upload custom kernal ROM image 1 (8kb) 2 - Upload custom kernal ROM image 2 (8kb) 3 - Upload custom kernal ROM image 3 (8kb) C - Upload custom character ROM (4kb) E - Upload extra image (8kb)

First select the ROM image you want to change, then start X-MODEM send in your terminal program. Make sure the size of 8k images is exactly 8192 bytes, and the size of 4k images is exactly 4096 bytes. Files with 2-byte "load address" prepended will not work.

Before you can use the uploaded images they must be loaded to RAM, which you can do by selecting Z in the main menu. Alternatively power-cycle the C64R MK2.

Write settings

Press W to write current settings to the internal EEPROM and store them permanently.

Reinitialize memory and reload ROM images from flash

Pressing Z will fill the RAM with the power-up pattern, reload the ROM contents from flash, and then reset the C64 reloaded MK2. This equals a "hard reset".

Factory tests

Press F to enter the factory test menu.

M - Perform memory test N - Force NTSC timing P - Force PAL timing V - Test voltage selection Z - Clear settings

Perform memory test

Press M to run a simple memory test. You should see output like this:

Test datalines PASS Test address line A 0 PASS Test address line A 1 PASS Test address line A 2 PASS Test address line A 3 PASS Test address line A 4 PASS Test address line A 5 PASS Test address line A 6 PASS Test address line A 7 PASS Test address line A 8 PASS Test address line A 9 PASS Test address line A10 PASS Test address line A11 PASS Test address line A12 PASS Test address line A13 PASS Test address line A14 PASS Test address line A15 PASS Test address line A16 PASS

Test voltage selection

Press V to enter the voltage selection test menu. This menu is ment to be used for measuring the respective voltages at the IC sockets with a multimeter. If you don't want to do this or don't know what means do not use this menu!

WARNING: !!! ONLY PERFORM THESE TESTS WITH EMPTY SOCKETS !!! Selecting voltages that do not match the installed ICs will potentially damage the ICs and/or the C64 reloaded MK2.

A - SID 1 to 9 Volts B - SID 1 to 12 Volts C - SID 2 to 9 Volts D - SID 2 to 12 Volts L - VIC-II to 5 Volts H - VIC-II to 12 Volts

Clear settings

Press Z to completely erase the config eeprom. This feature is for testing that the menu system will actually load sensible defaults when no settings are available - to restore factory defaults use L from the main menu.





The Password to enter the Factory tests menu is here... icomp

Notes

The Final Cartridge 3 does not start correctly (crash) when using the Reset at the Powerbutton/Userport when the Desktop is active (right after poweron). This is not a Bug! - it behaves like this on any C64. Use the reset button at the cartridge instead!

The lightpen delay is always the same as on C64 motherboards with discrete logic (Box Check "Type" will show "DL" in second column). Some test programs may wrongly assume this means the machine uses an "old" VICII although a "new" VICII is installed. This is not a Bug and it has no effect on any real world programs.

The component C23 near the tape port is not assembled. This has been done in order to ensure compatibility with the "tapecart" project.

If you encounter problems with the 1541U, please try updating the firmware to its latest version. When using the 1.x firmware disable the "start with menu screen" option. When using the 3.x firmware make sure the timing parameters are at their default values (CPU Addr valid after PHI2: 80ns-96ns depending on firmware, PHI2 edge recovery: Enabled). We have tested various hardware versions of this product successfully, but please understand that the FPGA nature of this product makes it impossible to test all and every combination of hardware and firmware.

The WiModem from CBMStuff has no proper filtering in its VCC connection and draws excessive power in short pulses, which causes visible artefacts in the video output and noise in the audio. This is not a Bug! of the C64RMK2 - but a problem of the device, the vendor of the device must use proper filtering in such cases. (This might be true for other devices based on the ESP32 wifi modules). Similar side effects can be observed on other C64s, C128s and VIC20s with this device. See here for a possible fix.

Utilities

mk2codenet is a codenet clone that works over the USB link of the C64 reloaded MK2.

The Commodore 64 Reloaded MK2 configuration and update tool is currently in Alpha status. It has been tested successfully on Win7 machines (both 32-bit and 64-bit) and on Windows 10 machines. This newer version now also works with Win XP machines and on Linux using wine.

Download: C64RMK2 tool February 27th, 2018 (older versions: February 5th, 2018, January 29th, 2018, January 24th, 2018, January 4th, 2018, January 3rd, 2018 )

This is still an engineering tool. You need to follow these steps in the right order to update the MCU firmware and thus improve the VIC-II recognition:

first make sure the USB connection works and the required drivers are installed as described above. Linux users may have to add a link to the serial device as described in the wine documentation.

make the USB connection to the computer, wait for the additional COM port to be added to the system

start the tool

make sure to select the correct Prolific USB-COM port bridge (if there is only one, it will be preselected automatically). if the tool can not detect the ports automatically you will have to pick the com port by its number (eg this seems to be the case when using wine).

switch on the C64RMK2

click on "connect" and verify if there is output in the output window of the tool

if this is verified positive, click on "update firmware" and power-cycle the C64RMK2. The process will take about 30 seconds. After this is complete, the C64RMK2 will automatically launch using the new firmware.

On some computers, the virtual COM port is not properly initialized with this tool. As a workaround, you can start the popular "Putty" tool once, select the Prolific serial bridge with the 19200/8N1 settings, and end the tool before starting the C64R MK2 tool. Also, some customers reported that starting the tool with administrator rights was required in order to get it to work.



