Home » RBC Forums » General Discussion » My 6809 board: MAXI09
My 6809 board: MAXI09 [message #1330] |
Fri, 11 November 2016 13:17 |
aslak3
Messages: 2 Registered: November 2016
|
Junior Member |
|
|
Hi,
First of all, thank you to Andrew for setting up my account!
MAXI09 is my second 6809 board, the first one was much simpler. The goal was to try to integrate all the parts needed to make what would have been a decent mid 80s 8 bit micro: good video, sound and a nice keyboard. All onto one board.
I must admit I am a 6809 fan. Hell, apparently Bill Gates said it was the best 8 bit MPU, so it must be true. ;) It's a great instruction set compared to the 6502 IMO.
Since I'm keen to learn more about the topic, I have used 2 FPGAs for glue logic and other things. These are the most accessible, through-hole (via PLCC socket) 5V FPGAs I could find: the Altera Flex10 K (EPF10K10). These are small (500 logic elements) but they do have a few RAM bits and are good enough for implementing what I need.
Anyway, I named the board after my son, Maximillian. Parts used:
68B09
512KB RAM, 32KB EEPROM - all of this is mappable
V9958 with 192KB VRAM with DIN6 RGB using BBC Micro pinout
OPL2 aka YM3812 sound output (mono)
SC16C654 Quad UART - two channels on RJ45 at '232 levels, one on a TTL level header, and one attached to keyboard controller
Keyboard controller is an ATMega8515 (PLCC 44 to keep board space down) with an Amiga 600 keyboard attached
The venerable 6522 acts as GPIO and parallel printer port
Two Atari style 9 pin joysticks attached via addressable latches
There are some devices on SPI, which is provided by one of the FPGAs:
Two XY analogue inputs via a MCP3002 which share the 9 pin joystick ports
DS1305 RTC
32KB EEPROM in a CAT25256
The first FPGA, which I have cheesy named MuDdy is attached to pretty much all the MPU pins and can (when I implement it) be used as a simple MMU and DMA controller. So far I have written a simple bus-mastering (via /HALT) DMAC and it works well. Currently the address pins are all routed through so the MPU sees 32KB RAM, 16KB of IO and 16KB ROM. MuDy also, using the FPGAs RAM bits, holds a 256 byte boot loader. This lets me reprogram the EEPROM even if I've previously written nonsense to it. MuDdy also does the boring but essential things like address decoding.
The second FOGA has the cheesy name of DISCo (Disk, Interrupts, SPI Controller). It is attached to the IDE header. Originally I was going to attempt to write a proper "host" IDE controller and completely isolate the IDE databus from the rest of the system. But this required too many pins, so DISCo is limited to operating the high byte latch so 16 bit devices can be used. For storage I use a Compact Flash in an adapter. DISCo is also responsible for interrupt routing. The board contains about 8 interrupt sources so there needs to be a way to configure which interrupt lines go where (the 6809 has 3 pins so there is a choice). Because of wanting to minimise the 6809 code in the ISRs, DISCo exposes a priority encoded interrupt "number" so all the main ISR has to do is consult a table. I could have made this even better by directly generating the vector, but I ran out of pins on the FPGA.
DISCo also has an SPI host interface. Currently this is a bit of cheat; DISCo is just an interface to the SPI pins with the actual bit shifting still being doing in 6809 code. Eventually I'll implement something functionally like the 65SPI, if anyone is familiar with it.
I'm very pleased with the hardware choices. The V9958 is an amazing VDC, and I've only really scratched the surface with what it can do. Likewise the OPL2. For fun I wrote a routine to playback DOSBox registry dumps and the playback sounded just like the original. I just which I had some musical abilities.
Software. Well, there are loads of possibilities. I guess I could port an existing OS, but currently I am writing my own. I also have a Monitor which I wrote for excersising the hardware. This has proved very useful in the early sages. I've also written things like a disassembler and some routines for reading the Compact Flash when it has a MinixFS on it (everyone "does" FAT, and I wanted to be different). But there are two different goals, from a software point of view.
The first is that I really want to write some games for my board. I noticed that the MSX has a decent version of Pac Man, so based on the fact it has roughly the same video and sound, I thought I could write a version as well. So far I have got as far a writing a version of Snake. With the analogue joystick inputs I could also write some cool pong games.
The second thing is satisfying the craving to write a useable multitasking Operating System, and some programs to run in it. Obviously there is FLEX, and other cut down UNIX flavours. But I wanted to write my own, just for the challenge. And I've got pretty far. I'm not interested in borrowing UNIXs process model or anything. If anything, what I've come up with so far borrows from AmigaOS's Exec more. I have a simple multitasking scheduler (no priorities), with signals and a very simple driver model. I have drivers for the UART ports, and a console driver with virtual consoles on different function keys (the V9958 makes this very easy). Eventually I might have a go at writing an editor and maybe even an assembler, to make the system self hosting. I might get bored before then though.
Anyways, here is a few pictures, since this is a whole load of text already.
You can read more about MAXI09 in my blog... which I can't link too yet it seems.
Any questions just ask away.
Lawrence
-
Attachment: IMAG0175_1.jpg
(Size: 78.58KB, Downloaded 1479 times)
-
Attachment: IMAG0163.jpg
(Size: 110.17KB, Downloaded 1498 times)
|
|
|
|
Re: My 6809 board: MAXI09 [message #2501 is a reply to message #2233] |
Fri, 21 April 2017 12:17 |
aslak3
Messages: 2 Registered: November 2016
|
Junior Member |
|
|
Hey there,
It's taken me a while to spot that someone replied on my thread, sorry about that!
I do actually have a few 6309s, and I tried them (briefly) in my simpler 6809 board with some success. I'm maybe a bit "mad" but I actually think some of the features added to the 6309 are a bit weird. The register set is certainly a little less orthogonal then the regular 6809, and that bothers me. The faster clock, reduced dead cycles, and use of CMOS are great though.
In the MAXI09 board case, I managed to make a small error in the PCB and neglected to notice that the XTAL pin, when using an oscilator and not a crystal, needs to be left floating instead of being tied to ground. Since it's a 4 layer board I'd basically have cut the pin of a 6309 to use it in my board, and I wasn't willing to do that.
At the moment I'm really enjoying writing my own OS - I have a very very basic "Shell" working now, able to walk the Minix filesystem etc. That's keeping me very busy. But, as a side project, porting an existing OS to the board would certainly be great fun - it would be really interesting to run some "real" software on the board. I suspect the port would be a real challenge, especially considering the V9958 console.
I'll send you an email shortly. I'd love to see how difficult porting NitrOS-9 would be.
My blog is here: http://aslak3.blogspot.co.uk/
Take it easy!
Lawrence
|
|
|
Current Time: Mon May 20 14:14:19 PDT 2024
Total time taken to generate the page: 0.00706 seconds
|