While doing my robots I got into micorcontrollers. I decided to use the
Motorola 68HC908 controllers. There are many members in the MC68HC908 family
with different options. I started with the 68HC908GP32. This one has got
32 kB of Flashmemory, 512 of Byte Ram, 8 8 Bit AtoD inputs, 5 outputs that
will drive up to 25 mA, 2 timer channels and lots more. All in all there
are 29 I/Oīs when using the 40 pin DIP version. The Controller is in system
programmable and has an in system debugging feature. So there is no need
to debug in a slow simulator, you can debug on the chip in realtime. For
programmming I use the P&E assembler and debugger. I got myself the Codwarrior HC08 special edition from Metrowerks. It can generate C-programs up to 16 KB and unlimited assembler. There
is a 4K free version of the Cosmic C-compiler too, but it is limited to 4KB overall codesize. Iīam doing
my first programs with Metrowerks now. It is a little complicated at first
to get a project setup the right way, but after that it is quite nice to
work wit. Iīll write something about working with Codewarrior by times.
A short introduction to assembler programming can be found in the HCS08 Family Reference Manual in chapter 7.You can see the schematic of my first controllerboard here.
It uses the MC68HC908GP32.
Because I didnīt want to solder capacitors on MAX232 all the time I developed
a little extra board. So I can use it for programming/debugging and for
serial communications. You can see a picture of the controllerboard on
the robot pages. I used a canned oscillator of 19,6608 MHz , so I can program
the chip with a speed of 19200 Baud and nearly 5MHz busfreqeuncy is fast
enough for the moment. There is the option to change the oscillator to
a 32MHz oscillator to get full 8 MHz busfrequency. I tested to programm
the board with a 20 MHz Oscillator and it worked without any problem on
the RS232 communication line with the P&E software. I think frequencies
of 5, 10 or 30 MHz should be possible too without communication errors.
Those frequencies are sometimes easier to get then the frequencies that
Motorola expects. With 5 MHz busspeed it is much easier to calculate runtimes
by cyclecounting. Alternativly you can use 32 kHz Quarz with the PLL. I
will try this on another board. I dont know if this will work on a prototyping
board or if you have to use an etched PCB.

Next thing that happened was , that I got one of the free Motorola Nitron
Demo Kits. Motorola gave away 4000 of this one, and I`am one of the lucky
guys who got one. On the board is an 8 pin 68HC908QT4 with 4 kByte ofFlash,
128 Byte of Ram 2 Timer channels, 4 AtoD channels and an internal oscillator.
The board has a potentiometer on one of the AtoD channnels and a led for
experimental purposes. It was combined with the Metrowerks HC08 special
edition, so i didnīt had to download it. This board has the MCU soldered
on it and canīt program blank part
The Demo Board from Motorola

I too have a demoboard from Softecmicro. This board has full featured progrramming
hardware on it with powerdown support. The QT4 MCU is in a socket an can
be replaced. Because it has a prototyping area, it is easy to solder a
16 pin socket onto it to program the QY chips. Although there is the possibility
to solder a MON08 connector to program other 68HC08 chips. So it is possible
to program all your blank parts. This board is much more useful but the
price is 4 times the price of the Motorola board
The Softecmicro demoboard


For my own experiments I orderd me some of the 16 Pin 68HC908QY4. I never
cared of the other components on the board when I used the 68HC908GP32,
for the 68HC908QY4 I build a standalone programmer. The Board has got all
you need to programm most 68HC908 MCU or get them into Monitor Mode. I
soldered a 16 pin Socket on the board for the Nitrons. You can view the
schematic here. The DIP switches can be used to put 4 signals on High or Low potential.
So you can get all combinations for the signals MOD0, MOD1, SSEL, and DIV4
matching the MCU. The programmer can be used as standalone Nitron programmer
or programm other HC08 MCUs on their board if there is a connector. It
is althoug possible to use the programmer with the User Monitor. The board
can power the MCU board or otherwise be powered by the MCU board.

A 68HC908QY4CP

I buildt a littele LCD Terminal with a Nitron an an LM052L LC Display LCD-Terminal .
Meanwhile I built my second GP32 board. The bord is different in that way,
that the Monitor Mode signals are controlled by DIP switches. So I can
switch to native signals at runtime. This time the MCU uses a 32kHz quarz
for the clock. All my worries about doing the oscillatorcicuit on a protoboard
were needless. The canned oscillator is for programming and debugging only
and can be switched off by a jumper. I soldered a MAX232 on the board to
use the SCI of the MCU. The other channel of the MAX232 can be used for
ISP.
 |
 |
| The board |
The oscillator |
No schematics yet
Iīve tried my first SMD device, after getting a few MC68HC908QY1CDW in
SOIC package. Because i donīt want to etch my own PCBīs I took a little
adapterboard and soldered the Chip on it. Soldering the SMD chip wasnīt that hard , the only thing to take care
of is not to take too much solder and to take some extra flux. If here
is too much solder, you can use solderwick to get it off. A magnifying
lense could be handy too. I took solder with a diameter of 0.5 mm, so it
is easier not to take too much of it.

The QY1 controller is specified to have 1.5 KB flash memory, but the ones
I tested had 4 KB of flash memory, which I found out by accident. Maybe
this will change on later masksets. I checked if the AtoD channels are
bonded to the pins, and yes they are. So there is much more use for this
chips than expected.
The semiconductor part of Motorola is now called Freescale and the good news is, that you can order samples now. This makes it a lot easier to get some of their parts, that are hard to get for me. I ordered two MC68HC908AB32 and two MC68HC908JB16. I had them within a few days. I like the AB32 for its 51 I/O pins and the two timers with four channels each. This one
is only availible in QFP64 package. I have built a board with them. The
JB16 has an USB interface , lets look what thats good for. Freeescale now
offers some new Nitron Chips. The MC68HC908QB4 and the MC68HC908QB8 frum
the new QB serie. There is althoug a new MC68HC908QY8 with 8 KB of Flash
and 256 Byte of RAM. The two QBs are really rich featured. The 68HC908QB4
has 4 KB Flash and 128 Byte of RAm, the 68HC908QB8 hat 8 KB Flash and 256
Byte RAM. The both hava a 10 channel 10 Bit A to D konverter, 4 timer channels,
SPI and an ESCI in a 16 pin package. The ESCI can be used as RS232 or as
LIN interface. The QBs are pincompatible with the QYīs as long as only
the features of teh QYs are used. Usind the User Monitor from thhe QT/QY
series isnīt easy. Because of all the onboard peripheral the are some more
interrupt vectors used. This memory locations are used by the User Monitor.
If you donīt need some of the interrupts, it should be possible to useit.
Another problem is that the ROM routines used by the User Monitor have
different adresses, which arenīt published by freescale yet.
See my HCS08 Demoboard an this page.
Iīam having a HCS12 board now, which will need further investigation.
|