C cross-compiler for 6800 (yes, you read correctly)

A key aim with interrupt routines, especially on chips with lots of registers and no "load/save multiple register" instruction, is to avoid (non-inlined) function calls - it makes a huge difference.

Have you ever used a COP8 microcontroller? The overhead in figuring out which interrupt occurred, stacking the basic registers (even though there are only three of them), and jumping to the real interrupt routine was typically something like 40 instruction cycles. You had the same again for the exit. And each instruction cycles was ten clock cycles, with a 10 MHz maximum clock. So you have close to 0.1 ms overhead for an interrupt - it makes the AVR's interrupts seem lightning fast.

Also note that the newer X Megas have DMA and an "event" system that lets you do quite a bit of action without needing interrupts.

Reply to
David Brown
Loading thread data ...

I don't think sending an email would help you - the Walter Banks at Bytecraft is the Walter Banks that has been posting in this thread, and he doesn't have a 6800 compiler.

Reply to
David Brown

I came close once, but managed to dodge that bullet. I remember reading through the datasheet and manuals and then being quite relieved that we decided to do something else (though I don't remember what the "something else" was -- it may have been one of the low-pin-count '430s).

--
Grant Edwards               grant.b.edwards        Yow! Will this never-ending 
                                  at               series of PLEASURABLE 
                              gmail.com            EVENTS never cease?
Reply to
Grant Edwards

You could look into web archives for Manx Software systems products. I had the Manx C compiler running on an Apple 2 with 5Mb hard drive circa 1983/5. Of course, that was for a 6502 target and was very slow, both in compilation and because of the volume of code produced for even the smallest of programs.

I would find a good 6800 Xasm and use that, or if you can stand it, one of the Forth packages that were available at the time. 6800 asm is pretty trivial anyway and should be easy to learn and become fluent in...

Chris

--
** Remove the meaning of life to reply...
Reply to
tridac

Not sure how this can help with a 6800.

Do you mean run Forth on the 6800? The computer in the OP's post had just 2k or so of memory, which probably isn't enough.

Reply to
Paul Rubin

The National COP8 and Zilog Z8 both were bit serial cores. There was a later version of the COP8 that was implemented with parallel data paths.

It was a fun processor :) to write a C compiler for. In addition to your comments all of the paging addressing complete with slightly different calculations of page addressing for jmp's and calls. It has three types of jumps, pc relative, within the current page and absolute address. One two and three byte instructions. As jump targets drifted over page edge addresses during optimization they needed to change from one type to another impacting code in other pages as well.

It is one processor I would not want to write anything but a trivial application in assembler

The good news is it was quite low power at the time it was released.

Walter..

Reply to
Walter Banks

For me it's the RCA 1802 and the COSMAC Elf.

We couldn't afford better when I was growing up, but several months of abject begging did get me a COSMAC Elf kit when I was growing up. I think the most I ever did with it was run an RC servo, and jigger the clock timing so that you could actually get stable graphics on a TV with a color-burst crystal.

--

Tim Wescott 
Wescott Design Services 
http://www.wescottdesign.com
Reply to
Tim Wescott

Den mandag den 10. februar 2014 04.49.47 UTC+1 skrev CTH:

something here?:

formatting link

-Lasse

Reply to
langwadt

A few years ago (well quite a few years ago) I was at the RCA plant in NJ and met the guy who hand taped out the Elf had his retirement delayed a few months waiting for one of the voyagers to pass one of the outer planets just in case he was needed. NASA one way or another was paying to make sure he was available in case he was needed. He like most engineers I know didn't know how to do nothing for a few months.

The response to 6800 has been amazing on this thread

w..

Reply to
Walter Banks

I'm confused. The Elf was a homebrew personal computer project presented in Popular Electronics. There were a couple small third-party companies that offered Elf kits based on the design from the magazine, but I can't believe Voyager had an Elf in it.

Or did this guy tape up the 1802 processor itself?

--
Grant Edwards               grant.b.edwards        Yow! Hold the MAYO & pass 
                                  at               the COSMIC AWARENESS ... 
                              gmail.com
Reply to
Grant Edwards

Yes, I noticed ;-)

Cheers, Chris.

Reply to
CTH

I built the 4k RAM expansion (on a home-made PCB) but otherwise yes, 1k EPROM, 300bd FSK cassette tape storage, hex keypad and 64 x 32 dot composite video display.

You are entirely correct, of course, but with time pressures etc C is more convenient - provided it's feasible!

All indications are that assembler is how i's going to be...

Cheers, Chris.

Reply to
CTH

I have vague memories of that. Also the SC/MP based kits - lots of toggel switches & LEDs (new tech for the era!). They pre-date mine by a few years.

Cheers Chris.

Reply to
CTH

Agreed!

Cheers, Chris.

Reply to
CTH

Thanks Lasse, this looks interesting!

Cheers, Chris.

Reply to
CTH

I assume that Walter meant the 1802. I'm pretty sure it was the COSMAC

1802, and that it was part of a family of inter-operable "COSMAC" parts, many of which the Elf was built from. Hence the "COSMAC Elf".

I do remember it having the most frustrating instruction set -- it was just two or three instructions short of being a really powerful machine. On the other hand, you could pretty much look at the instruction set and see the logic behind it. There probably weren't many transistors in there.

--

Tim Wescott 
Wescott Design Services 
http://www.wescottdesign.com
Reply to
Tim Wescott

While the 1802 has been used in a fair number of spacecraft, the Voyagers would have been design frozen well before the 1802 was available.

Reply to
Robert Wessel

He taped the processor for the 1802. Thanks for bailing me out :)

Amazing when you think about it the kind of processing power that used to be used for space or any application.

w..

Reply to
Walter Banks

Yea, it was pretty odd compared to the the other processors I had worked with at the time (8080, Z80, PDP-11). In one class we had homework assignments to write assembly language programs for an 1802, but we had no actual hardware to run them on -- at the time I remember being told the 1802 was the only rad-hard microprocessor processor. Many years later in grad school I ended up writing some assembly language for a CDC Cyber 6600 mainframe, and it was oddly reminiscent of the 1802: the only way to read/write memory was via register-indirect addressing, and there was no real support for a call stack. [At least that's how I remember it 25 years later.]

--
Grant
Reply to
Grant Edwards

I posted a link to the archive in another message. But AFAIK, Manx never had a 6800 compiler.

Large code size was somewhat inevitable.

The Aztec 6502 native compiler actually was pretty good. C is defined in such a way that it requires most integer operations to be 16-bit or larger. It takes a lot of instructions to run a mostly 16-bit program on an 8-bit CPU. [Hence the bytecode compiler.]

George

Reply to
George Neuner

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.