XMODEM upload tool

A program shall do one thing and just one thing. Tired of using a ton of different programs for XMODEM uploads that come with loads of other functionality, decided to do an utility that does just that. Upload a file through a serial port using XMODEM.

Download the tool here, source code available at the git repository.

SVG to KiCAD footprint with Inkscape

Happy new year! And to celebrate, here’s a plugin for Inkscape that converts SVG documents into KiCAD footprints.

Hosting my own repos

BitBucket has officially deprecated Mercurial so, for the time being I’m deploying a Rhodecode instance to manage the existing repos while I consider moving all the stuff to git or keep it as is.

Repositories available on dev.heavydeck.net, instance running on an Atom laptop that I had laying around the place.

SEGA Flash Card V2 (and stand-alone mapper)

The original SEGA Flash Card, while working, needed a new revision made entirey with freely available software and free software where available. It would also be useful to separate the mapper into its own module as to allow using it on any other projects.

N0RAMboot as a BIOS replacement

The N0RAM project project has received a series of upgrades since its initial functionality as a serial bootloader. As a last bit of functionality I’ve decided to make N0RAM suitable for a BIOS replacement, able to load a ROM via serial port as it already does, and attempting to load a ROM from the other available sources (Cartridge/Card/External) if available.

Feature already available on the N0RAM project starting at V1.3

Making a DB9 console controller plug

Many consoles of the 8bit and 16bit era tend to use a D-Sub connector for their controller ports, usually a male DB9 on the console and a female DB9 at the end of the controller cable. For instance, the Atari controller plug below is shared among other consoles like the SEGA Master System, SEGA Megadrive/Genesis.

Capacitive touch sensor with 555 timer

Quick prototype. I wanted to test wether an ICM7555 could be used to make a capacitive sensor by connecting an aluminum foil square as the C side of an astable configured 555 and how much of a difference in frequency would I get out of it.

When adding an extra wire is not an option

At my former job we developed a series of industrial control hardware that control and integrates many types of hardware which in the end are connected using either UART, RS-232 or any easily convertible-to-RS232 communication interface. A common interface is the point-to-point variant of RS485/RS422 which is easily converted back and forth to RS232 or UART with any available transceiver like the MAX3488 that has on the same 8-pin package an RS485/RS422 transmitter and a receiver. If the bus mode is half duplex or multi-drop the MAX3485 or similar is used with an additional pin to control the direction of the bus on our end.

N0RAMboot: A Zero RAM bootloader


Not so long ago made an XMODEM serial bootloader for the SEGA Master System (link) and while it works pretty well, it has a few restrictions like upload size (being written in C requires some RAM for working) and the uploaded ROM must be able to bootstrap and relocate itself within RAM once chainloaded. This works just fine to upload small programs to RAM but it feels bad not being able to use the full 8KB of RAM for the uploaded ROM. This would require the bootloader itself to use exactly Zero 0 bytes of RAM.

This project is already working! Download the latest ROM here! Source available at my BitBucket repository.

Making a Roland mill understand g-code.

It is time to document one of my older projects, which I finished on a working state around ~5 years ago. The project in question makes an old Roland EGX-30 engraver accept a reasonable subset the very common machining language ‘g-code’ so it can be used for interesting tasks like milling PCBs.

Micro85: An i8085 microcomputer


Having found some i8085 CPUs not so recently I decided to make a proper microcomputer with them, providing it with common peripherals like RS-232 ports, and some not so common for the day peripherals like an LCD screen and a DMA controller. On this page I will be documenting the projects as it gets developed.

Master System color pattern ROM

Video signal on my SEGA Master System is completly broken, so to have a clue wether the signal is OK using my scope, I needed a color pattern on the screen. The SMPTE color bars are an obvious option so I quickly coded a ROM to show just that. The famous 7 color bars.

You can download the ROM here.
Source code on BitBucket.

Making an i8085 microcomputer

Not so recently I’ve come around a bunch of Intel 8085 CPUs (actually SIEMENS clones) and decided to put them to work. As you can see on the pic above there is already some work done but I will document the project when more work is one.

Verilog code and the resulting gate cost

Silly stupid experiment. How expensive is to add two numbers in Verilog? How expensive is subtracting? Multiplying? Shifting?

64kbps is enough to stream video

Mobile internet providers usually give you a limited amount of data per month (1GB most commonly) at full 3g/4g speed, past this limit speed is reduced to 64kbps until the month ends or you pay for an extended data package. 64Kbps is pretty similar to the 56Kbps I had back in the day so I decided to test how far can I push video compression with today’s tools and past century speeds.

Master System serial bootloader


Got tired of having to flash a cartridge every time I needed to run a small test program on the SEGA master system so, since I already have a serial port, I decided to make a serial port bootloader implementing the venerable XMODEM protocol.

The XMODEM bootloader is available as part of my Master System “BIOS menu” ROM; repository available on Bitbucket.

This quick project loads a ROM up to 4K in size using XMODEM, this way small ROMs can be loaded on the console using a PC and a serial adapter without having to remove the cartridge, flash another ROM and restart the computer, usually many times in a short period of time which is common (and annoying) during development.

Bringing OpenWRT to the NanoPi-M2


Recently bought one of the many Raspberry Pi look-alike boards, in this case the FriendlyARM’s NanoPI-M2, a single board computer based off the Cortex-A9 S5P4418 SoC. Out of the box this board supports Debian Linux and some flavour of Android. However the Linux distribution I wanted to use, OpenWRT was nowhere to be seen. So I did the correct thing and made the necessary changes to make OpenWRT run on this board. This board’s vendor is kind enough to provide a kernel source tree and prebuilt compilers, saving me a fair amount of work and making me decide to start porting right away.

At the time of this post I just managed to make a basic OpenWRT run on it, with USB, ethernet and USB-CDC networking support. Once is more fully featured I’ll post more results.

New cartridge revision in design!


Having a working prototype card is now time to make a more definitive, more user friendly version of the circuit.

This new revision will use the more common cartridge slot, and will be able to program the flash ROM without an external programmer using a microcontroller to connect to a PC and upload a new ROM with it. I will also be using KiCAD instead of any other proprietary CAD tool.

Serial port for the Master System


Blinking an LED is the first step with any programmable hardware, putting a serial console to work is the natural step 2. No one thought about giving the SEGA master system a serial port, so I decided someone had to do it.

Having a serial console is by far the easiest, most convenient way of interacting with a computer. It allows an easy way of controlling, monitoring, transferring information to and from a system with minimal hardware and software requirements.

The main goal of this project is to provide an UART port on an unmodified Master System so it can communicate with a PC using an of-the-shelf USB-to-UART converter.

Prototypes are ugly


The working flash card built as described on this site is not the first attempt at making a SEGA master system flash cartridge of some sort. The very initial hacks into it were built around a PIC18F44K22 microcontroller with some signals exposed on pin headers to prototype the mapper hardware. While the approach using a single microcontroller proved too hard if not impossible, these boards were great for prototyping.

SEGA Master System flash card


This project attempts to make a programmable SEGA Master System card which would allow loading custom programs or existing games on the Master System console through its card slot. The motivation behind this project has been being able to quickly develop software for the console, especially cartridge dumping tools since the Card Slot boots first on unmodified systems, and of course being able to play old SEGA games the way they were intended. On the console itself.