MoCog - A Motorola 6809 emulator for the Propeller

Introducing MoCog an emulation of the Motorola 6809 microprocessor for the Propeller.

In the few slack moments I have nowadays I have been converting the ZiCog Z80 emulator into a 6809 emulator. As usual with me this is a very unfinished early release. There is a lot of code in place but very little is tested. So far it just about single steps its way through a short loop of

NOP
ADDA $01
JMP $0000

No flag setting is in place.

This should compile with BST or homespun for the Prop Demo Board if the following defines are set: "PropDemoBoard" and "SingleStep".

Just compile, download and watch the output in the terminal window of BST or ProTerminal or whatever. Hit any key to take single steps through the loop.

I have left Cluso's code for the TriBladeProp platform (external RAM) in place but It's best he reviews it I guess.

What's this for? No idea but I want to see CUBIX running on the Prop possibly followed by FLEX, SK*DOS and/or One MAn Unix (OMU).

Edit: 8 Jul 2009 Latest version is 0.5. All op-codes now in place. Runs a GCC compiled test program (See the ram_6809 area in mocog_demo.spin). Not many ops do any flag setting yet.

Edit: 14 Jul 2009. Latest version is 0.6. Changed to run a 6809 test program. All addressing modes are working. Most other ops not yet. But at least the tests run !!!

Leon do you have a copy of Flex that will work with this or any 6800/09 ???
I have been using flex with my SWTP for years and just had an accident with my 5 /14 floppies I lost every single program 20 years worth of Motorola .Flex and OS9 lost everything I want to cry
I only had backed it up to more floppies since my computers could only read the floppies I am still in shock I had just dug everything back out since not using for years but now that I have been playing with the props and this forum it
got me motivated to setup all the old stuff again I even had an old STD bus 8080 system lost those disks as well

Hey guys thanks everyone , funny story I have a huge box with all my floppies from 3-1/4, 5, 8 . and of course I have to put it away (so its not messy wife stuff)) even though it my office .
Anyway I have a huge and I mean huge 48 LB magnetic sweeper for picking up steel at a construction site , nails scrap metal stuff like that this thing can pick up car ,,well almost but you get the idea
I scored it at a swap meet a few weeks ago, You can never have a strong enough magnet and since its been my dream to build a time machine for 50 bucks I thought I made the best deal in world.
Well you can see where this is going , its on wheels so you can push it like a vacuum cleaner .. Well guess where wifey decided to park it !!! yup right next to my huge box of 30 years of floppy disks collection
from windows 2.0 Beta, Xerox experimental windows that ran on an RCA 1802 , CPM86 , MS-Dos , Flex, OS9, Planet 9, OSX, Wave, HP UNIX, SCO you name it if it was made I had a copy on floppy I even had PDP-11 and IBM 360 anyone remember that?
And not to show my age but if anyone remembers when only real men had computers and they had switches and LED's and tape recorders for storage and 256 BYTES of RAM! well there was this ancient at the time cutting edge
BBS(remember those),lol called the "Pirates Den" he was arrested and shut down but had a whole BBS dedicated to boot leg software 300 baud modem connection high tech stuff at the time well I had the entire collection of his BBS

The funny thing is most of these disks were stored in there own cases made of wood and plastic but his box is 38X42X28 with all the separate storage containers floppies inside ,,Everything was erased and I mean everything
it sat like that on top of the magnet for weeks I guess but you would think there would be some bits left but they are all Blank there is nothing to recover its like everyone was individually erased. I tried to read sectors one at a time
but you can not believe how blank they are. even the furthest from the magnet disk are completely erased I don't think I could have done a better job on purpose. even crazier I had some digital storage tapes ,backups of some of the stuff in with the floppies
, they are blank as well I wonder if the closet setup up some kind of magnetic amplification?? Who knows its just day I lost all the stuff if anyone is in need of blank floppies let me know I don't have any use for them now

Oh guys I have all the Flex and OS9 manuals as well as the actual assembly code in print for Flex and the boot roms I even have a printed copy of code for OS9 for the radio shack color computer if anyone wants a copy I would be happy to share it with you
I was thinking maybe there is some way I can scan it into the computer and recompile it and make a boot disk ????? Anyway just ask if you want anything

This is one very good reason I don't mess with large magnets. Geomags is as large as I go, and I
keep them away from computers.

There's a story on the web about someone's magnetic billfold clasp destroying hard drive after hard
drive in a Macintosh laptop. No idea how factual it is.

I cut my teeth on an SWTP two-terminal system; that thing was so great! Basic09 and an HP pen
plotter; big old beautiful terminals; we had a blast with that system. I was totally OS9, though; no
Flex for me.

It sounds like you have a lot of very valuable artifacts, in any case.

I'm sure you can find the bits you need online, or at least a Flex club member online who can provide
you with boot disks and the like. And frankly, getting in touch with others with your particular hobby,
can be very rewarding.

I still have a pile (literally) of Color Computers of various makes in my computer room. I just cannot bring
myself to throw them away. I think I have at least six working machines.

(Edited to remove wording which may be misconstrued or offensive to some.)

Still nowhere near complete but pretty much all arithmetic/logic ops have code in place and do what they should. No flags settings in place yet. Immediate, Direct and Extended addressing modes are working.

Speed is up to 458KIPS for single byte instructions.

Now the real reason for this post. Can someone point me at a nice 8-bit by 8-bit unsigned multiply with 16-bit result for the MUL instruction?

Hi! This is a bit off topic but since there has been some great cooperation between the Propeller fans and the N8VEM home brew computing project I thought this would be OK.

I just received several PCBs for the N8VEM 6809 host processor board. It is a real 6809 that plugs into the N8VEM ECB as a peripheral. The Z80 SBC acts as the IO processor for the 6809 so you have full access to all the N8VEM peripherals and tools.

The only software I have running on the 6809 host processor is a modified version of the Motorola minibug software. I would love to get a FLEX port going.

Andrew, never mind the off topic. I think the N8VEM project is great and now it looks like it's keeps getting even better. Wish I had time to play, just now MoCog takes up all my spare minutes when I have them.

For sure FLEX is on the (distant) horizon for MoCog as well. Just now I have little idea about it or what it will take to get it up and running. So perhaps I will need to pick your brains about it sometime as I think you will get there first.

Anyway I want to get CUBIX up and running first as porting it is very well documented and all the source is available.

heater said...
Clusso: Yes I was thinking of Chips interpreter but I can never find anything of the forums when I want it. Not search.parallax.com either. Annoying because I saved a copy somewhere a few PC's back.

Any idea where it is?

Always keep a copy handy [noparse]:)[/noparse]

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Eccles : How do I open the door?
Bluebottle : You turn the knob on your side
Eccles : I haven't got a knob on my side!