Starting with Motorola MC6802

Discussion in 'Embedded Systems and Microcontrollers' started by ElectricMagician, Feb 8, 2013.

  1. ElectricMagician

    Thread Starter Member

    Jul 26, 2012
    57
    0
    Hello Everybody,

    (I did use the search function)

    I have an MC6802CP - 68K 8-bit CPU with RAM and clock

    (I understand this is a microprocessor, not a microcontroller, as I want to experiment with both.)

    I haven't found any resources that deal with this chip (programmers, sample projects, or anything like that.)

    What do I need to start building simple projects with this microprocessor? ( I do have a background on 68k assembly, so writing programs shouldn't be a problem)

    Thank you for your kind help!
     
  2. MrChips

    Moderator

    Oct 2, 2009
    12,432
    3,360
    The MC6800 and MC6802 are the forerunners of many of Freescale (aka Motorola) current microcontrollers, particularly the HC05 family. There is nothing wrong with starting out with current mcus such as M68HC08 or MC9S08 family.
     
  3. tubeguy

    Well-Known Member

    Nov 3, 2012
    1,157
    197
  4. MrChips

    Moderator

    Oct 2, 2009
    12,432
    3,360
    The competition always beat Motorola off the mark. MOS Technology beat the MC6802 with their 6502.
    Zilog Z80 beat the MC6809. Intel 8086 beat the MC68000.
    Too bad for the whole microprocessor generation and PC users as a whole.
    We must have lost at least 5 years in the IBM/Intel/MS dark days.
    Hopefully the ARM consortium will regain those lost years.
     
  5. takao21203

    Distinguished Member

    Apr 28, 2012
    3,577
    463
    The serial bus used for programming is esoteric at best, quite an effort even to read about it.

    I think 9s08 is a bit antiquated, there are more modern controllers and also inexpensive dev. boards.

    If you use the vintage controllers you should have a valid reason. They are not as much comfortable, slower, and memories are much smaller. Not to talk about cost, complexity of PCBs and availability.

    There are countless vintage 8bit controllers and even 4bit controllers, not all bad, but the original dev. hardware no longer available, often the programming spec. is kept as a state secret. Kind of. Take a PIC- get all the datasheets free, and laugh about consulting firm wannabee's who never touch any real silicon but wanted to guard the documentation + make money with it, and suit the market to their needs.
     
  6. ElectricMagician

    Thread Starter Member

    Jul 26, 2012
    57
    0
    Thank you all for your informative responses!

    I didn't necessarily want to start with an antique chip, I would prefer something modern and, if possible, relatively simple enough that I wouldnt need an awful lot of circuitry (or a pre-manufactured pcb) to deploy it in independent projects.

    What would be the suggestions for something like this?

    Again, thank you very much.
     
  7. MrChips

    Moderator

    Oct 2, 2009
    12,432
    3,360
    There are lots to choose from, depending on your knowledge, background and what you hope to accomplish. I don't want to get into a PIC vs Atmel vs Arduino vs Raspberry pi wars but I'm sure we can find something to suit your needs.
     
    absf and ElectricMagician like this.
  8. takao21203

    Distinguished Member

    Apr 28, 2012
    3,577
    463
    Look at the boards from Freescale, they are called Kinetis I think. Quite good. Or the STM32 boards which have a very powerful 170 MHz controller with large memory.

    Maybe get both. They don't cost much.

    Motorola has spun off their semiconductors stuff years ago, it is now Freescale.

    It is absolutely aimed at the professional user, it is anything but not simple basic stuff.

    The older CPUs used external parallel memories, and these take a lot of effort, now all moved inside the chips. Some use external serial FLASH or even RAM.

    Only high-speed circuits use parallel RAM these days. For instance a digital camera has such a chip.

    You can of course wire up an old 8bit chip relatively easily, but anything more than a minimal system, and you end up with tons of chips and countless PCB tracks/proto wires.

    Both the Freescale and the STM32 have a serial port for some kind of ICSP (the in circuit protocol to flash PICs), so you can actually buy blank chips, and build your own boards, use the dev. kit as programmer. Does not support the whole range I think, and I have not seen it in detail on the Freescale evalution boards.

    Farnell has the datasheet on their product page, they ship fast, and as I said, these boards are low cost.

    Also look at the Freescale website and the Freescale forum. Where you can encounter, they don't deal so much with trivial questions.

    The STM32 board is compareable in size to the PICKIT3, only about 2x times larger and it can program some of their chips.

    I think the same also applies for Freescale. Normally people use a dedicated programmer, and also the PICKIT3 is an economy programmer module.

    Maybe get all of these technologies, use them together, or use whatever is best for a project.

    I am not a person giving advice to use specific brand, even if I use PICs myself. Also have a STM32 board here, an old Motorola board, and a micro Arduino. I just don't need to use something else than PIC, even if the STM32 board is tempting with it's 170 MHz.
     
    ElectricMagician likes this.
  9. absf

    Senior Member

    Dec 29, 2010
    1,492
    372
    I dont have any 6802 but I have lots of used 6803 which are in sockets from used boards.

    After comparing the datasheets of 6802 and 6803, they are quite similar mpus. The 6802 doesnt have any ports while it has 16 address and 8 data lines. The 6803 has a 8 bit and a 5 bit port but the lower address lines are mutiplexed with the data lines while the higher 8 bit address lines are independent. Both mpu have 128 bytes of internal RAM.

    So just adding an eprom or eeprom, I can flash some LEDs with the 6803. But you need to add an output port using 74HC373 in order to connect to the LEDs for the 6802. Both mpu also have clock driver built in so just adding a 4 MHz crystal and 2x27pF would be it.

    I constructed my 6803 sbc on the breadboard with an extra HC373 output port for other functions. The program is stored in a 2716 EPROM which is hard to find now but you can use 27C256 or 27C512 by just grounding the unused address lines.

    If you just want to have some fun flashing LEDs, not to just junk the antique. You can always put in an eprom and a HC373 and have some LED blinking in a short while. The assembler I used was "AS03" and there are other flavors for 6801, 6802, 6805 and 6809 etc. If you want to develop bigger programs, you'd need extra RAM externally and a decent monitor program.

    Allen
     
    Last edited: Feb 9, 2013
    ElectricMagician likes this.
  10. takao21203

    Distinguished Member

    Apr 28, 2012
    3,577
    463
    Use a PIC to emulate the EPROM, for instance 16f946 has 53 I/O should be more than enough.

    I do not know if the memory bus allows for very slow memory (fake), but many old CPUs actually do.

    You can say pointless, but you also have to deal with that particular assembler mindset and register architecture.

    May be of use to some people.

    EPROMs well...I have 2x 2716 here for reference and even an UV lamp and two GAL programmers. Ridiculous. Serial FLASH- 8 Mbit or even 16 MBit in a small SOIC.

    You could even make small "cards" from EEPROMs or serial FLASH, write them with a GAL programmer, and plug into your 6802 system.

    If you don't want a direct serial connection through the PIC (for instance don't want to have a cable around or to make one).

    For sure dealing with this old tech is either hobby or study or state of the art (to maintain vintage), but not so much used professionally now. Think of the risk mentioning it for a job and they just skip all this stuff- little sense for Nostalgia.

    Take SEGA- for them the Master or the MEGA drive never even existed in the first place.

    I was thinking at some point of time to use the Master system together with embedded chips as display and I/O unit- quite easily since the bus allows DMA request (which you do not have to end anytime, never indeed if you desire).

    But then I was not able to find any officially approved documentation or any documentation meant to be for that purpose. All e waste now.
     
    ElectricMagician and absf like this.
  11. ElectricMagician

    Thread Starter Member

    Jul 26, 2012
    57
    0
    I have an Arduino uno, I find it powerful and easy to use (program-wise), but I was looking for something where I can "build" the circuit myself, not just use a prebuilt board (I think I would learn more this way)
     
  12. ElectricMagician

    Thread Starter Member

    Jul 26, 2012
    57
    0

    Hi Allen, thank you for the extremely useful response! I'm going to try this in addition to also experimenting with other units!
     
  13. takao21203

    Distinguished Member

    Apr 28, 2012
    3,577
    463
    The 68008 is more appreciate maybe. It only has 8bit memory bus, not 16bit like the plain 68000.

    With these smaller CPUs, at best you can do as much as with a 16F PIC, but have to use assembler, and you have to deal with big efforts of external chips.

    I am also working at a single board computer design based on the 68000.

    I have now done away with any idea to build it for high speed. If I can just execute 68000 instructions, no matter how slow, that's the goal now.

    The problem is larger PICs are 3V so you'd need banks with latches for level translation + countless wires.

    It is bad enough with one 8bit RAM chip already.

    Or take the 68SEC000 which is still manufactured. 3V, 15mA, 8bit bus as option. Needs SMD PCB though, and no adapter boards exist.
     
    ElectricMagician likes this.
  14. thatoneguy

    AAC Fanatic!

    Feb 19, 2009
    6,357
    718
    They are decent boards, but the development suite to work with them is rather expensive. Initial investment of > $150 to even see if it is applicable for what the user wants to do is a bit harsh.

    There are hundreds of choices, but which system to start on will be dependent on what the OP wants to accomplish. If it is something like a timer and LCD display, that's a cheaper and non-intensive task for the processor. If the user wants to do realtime processing of multiple inputs, producing multiple outputs, that gets more complicated.

    Most systems are about $25 to $100 to get started with (from 8 bit uC to FPGA), though the clustering around $25-$50 is heaviest. That is for the programmer (one time cost), programming environment of some sort (usually C based), and a demo board. The actual processing power is independent of the price, in other words, a 32 bit ARM processor with a lot of I/O costs about the same to get going as an 8 bit processor with 16 I/O. The difference is the integrated peripherals on the processors/controlelrs, and ease of use.
     
    ElectricMagician likes this.
  15. takao21203

    Distinguished Member

    Apr 28, 2012
    3,577
    463
    I found one suite for the STM32 board which is fully functional, only a 16K or 32K limit.

    Of course if you use a filesystem and jpeg, that's gone already (assume also USB stack).

    Makes people wonder why they can not get anything for free.

    I am not bound by that as I have the know how to use multiprocessor, or to segmentate executeable code (especially if the processor can run from RAM).

    I used a PIC 18F with a color TFT, wrote a small BMP decoder + palette expander from 8bit integrated palette to 16bit LUT.

    Made 10 BMPs, wrote them to a serial FLASH as binary using my GAL programmer, and wrote down the start offsets. No file system needed.

    It is only using a few KByte, for sure the 8bit palette reduces resolution, but all fits into a small serial FLASH chip.

    Why bother with JPEG? If you wanted to, or needed to, it has it's price, and that's that, let's say.

    The professional will always find a workaround and get things done.

    If I wanted to make a commercial board, the investment for the IDE is next to nothing.

    If I want a demo board, 10 BMPs are plenty. And these are full display images, not just tiles.

    Optimized the C code for the font and my BMP stuff + overclocked the PIC a little, and it fills the screen instantly.

    And this is just a entry-level 18F PIC, cost about $2.

    Think what I could do with the STM32 board. There is no limit. If I have a code limit, I put most of the functionality into data tables, and use a serial FLASH.

    So saying the code limit is limiting you, is not an excuse to program a cool demo or a small application.

    The greatest thing I have done was to implement a text message scroller on a 16F57- 12x5! Really maxing it out to more than 90%. And I use C language. I had to use some tricks, and that was so interesting. To see the limit, and move the barrier a bit. It is using proportional fonts, and not just 1:1 writing to the LED matrix. It is remapped bit by bit.

    Most text message scrollers I saw don't use proportional font, and they are hardcoded to the LED matrix, means the output writer is just primitive as easy as possible.
     
    ElectricMagician likes this.
  16. GetDeviceInfo

    Senior Member

    Jun 7, 2009
    1,571
    230
    the 6802 was a true 8 bit buss, not like the 68000. Processors of this timeline were just that, processors. They had no peripheral/memory support, other than the basic decoding signals. The 8051, another 8 bit machine, found extended popularity, and eventually was surrounded by peripherals.

    There would be little reason to learn the interface of the 6802, the 6502, or a number of similar devices, as their existence as base processors alone has ended.

    You should probably define your objectives a bit better, then selecting a system/architecture would be easier.
     
    ElectricMagician likes this.
  17. takao21203

    Distinguished Member

    Apr 28, 2012
    3,577
    463
    Mastering these ancients electrically will provide a good grief of technology.

    Don't overdo it, means to build a board with 50 ICs.

    I have learned and I always find impressions from simply reading the plain 68000 manuals.

    Not saying one should try to force the design like it is these days.

    This was all CISC and often single task. While today it is most likely RISC, multi-task, and C language is used.

    Don't become an assembler whiz and nothing else.

    I see it as a challenge to come up with a workable 68K design and that means NOT a large PCB and not an EPROM bank.

    I am currently very close to it.

    And without drawing schematics, I did some years ago, I did some PCB layouts.

    Then at some point Lattice stopped to make GALs.

    So these can no longer be used.

    I have a layout with a CPLD here and using the SEC000, but I have no urge to produce a working PCB.

    I want a plain 68K board as well.

    If you are able to see a 68K computer in your imagination without a schematic- so you can most other PCBs.

    The value of this design is not measureable- I have read it was actually done with lead pencil on paper, and with some 74XX + LED displays.

    It is really more like a 4bit-state machine, not so much a CPU.

    Very much depending on microcode.

    You would know these details for each CPU you research, after a while.
     
    ElectricMagician likes this.
  18. Granzeier

    New Member

    Feb 22, 2015
    2
    3
    I do realize that this is an old thread, but I found it recently, and wanted to add some information that is relevant. Maybe this can help someone else who is looking for 680X information.

    The OP [ElectricMagician] specifically requested information about microprocessors - he says that he does understand the difference. I think that this should eliminate PIC, Atmel and other MCUs from answers, other than tangentially.

    Now, ElectricMagician, you mention that you are looking for information about the 6802, but then immediately claim that it is a 68K CPU; the 6802 is an 8-bit CPU (as you mentioned,) but the 68K is the 16-bit 68000 descendant of the 6800. The 6802 chip contains a 6800 (not 68K, or 68000) with an on-board clock circuit and 128 bytes of RAM.

    I used to teach the 6800 in the Heathkit ET-3400 in a microprocessor course at a local tech school. The 6802 is a wonderful chip to begin with, and (as MrChips pointed out) the forerunner of some of the newer Motorola, and Freescale microcontrollers. The ET-3400 is a wonderful trainer, and the Heathkit course that came with it is superb. You can download the entire set of manuals for the trainer, along with a lot of additional stuff from the ET-3400 Yahoo Group (https://groups.yahoo.com/neo/groups/ET-3400/info)

    Another good place for information about the 6800 is the SWTPC Site. This is a site dedicated to the antique SWTPC 6800, an early computer based on the MC6800. You can find that site at http://www.swtpc.com/, click on the link for Mike Holley's documentation page.

    If you want to build a simple, low-cost 6800 system, for playing around (err, experimenting) take a look at San Bergmans' SB-Projects, 6802 Nano Computer (http://www.sbprojects.com/projects/nano6802/index.php.) This is a tiny, 3-chip system, along with a few projects to illustrate the board. San's SB-Assembler page (http://www.sbprojects.com/sbasm/6800.php) has a nice intro to the MC6800 CPU. While you are looking over these 680X-related projects, click on the link for his home page, and take a look at some of his other stuff. (BTW, I have no relation to San, just that I have liked his projects for many years.)

    If, on the other hand, you are actually looking for the 16-bit 68K info, do a search - there is a lot of info out there - I just skip most of it, because I concentrate more on the earlier 8-bit stuff, from my early days in the 1970's. I do know that Hack-A-Day has a 68K project (http://hackaday.com/2014/02/20/hackaday-68k-a-new-hackaday-project/,) and there appears to be a set of files available on Git (H-A-D article: http://hackaday.com/2014/03/27/hackaday-68k-so-you-want-a-kit/.) The H-A-D project page is here: http://hackaday.io/project/5-mc68000-backplane-computer.

    I hope that this can help you, or someone else (or me, if I find this page while browsing for nostalgia in the future. ;))

     
    ElectricMagician and absf like this.
  19. MrChips

    Moderator

    Oct 2, 2009
    12,432
    3,360
    We do frown on reviving old and dead threads. In this particular case, I believe you have added some useful links for anyone interested in experimenting with old technology, i.e. MC6800, for nostalgic reasons. In this case we'll let this stand, for the record.

    Welcome to AAC. There's much more to offer than just MC6800 projects.
     
  20. Granzeier

    New Member

    Feb 22, 2015
    2
    3
    Thanks for letting me post to such an old thread (I kind of suspected that it would be blocked, but hoped for the best.) Normally, I would not add to this kind of thing, but (since I love the 680X, and that is how I found this forum) I thought that I could add some stuff to help out the members here, as well as anyone else who ends up here the way I did.

    Also, thanks for the welcome. I have updated my profile, and posted to the New Member's thread.
     
    absf likes this.
Loading...