EVBU - An Open Source 68HC11 Simulator

Andrew Sterian
Padnos College of Engineering & Computing
Grand Valley State University


Top-Level | BUFFALO Emulation | Peripheral Emulation | Waveform I/O Version 0.5
March 10, 2002
Timer | Output Compare | Input Capture | Parallel I/O | Pulse Accumulator | Interrupts | Unsupported Peripherals | Register Support

Introduction

Many of the 68HC11 peripherals are emulated in EVBU. While the emulation is fairly accurate, you should not consider EVBU to be a reference implementation of the 68HC11. If you try to do strange things, like use Port A pin 7 as a pulse accumulator input while programming the DDRA7 bit to make this pin an output, you get what you deserve! That is, EVBU may or may not behave like a real 68HC11. If you can suggest improvements for enhancing the accuracy of the emulation, however, I would be glad to hear from you.

The peripherals that are emulated are listed in the sections below, grouped by function. Some functions are implemented in the same Python module, however, so disabling a module (using the --no-timer or --no-pio command-line options) will disable several functions. There is no need to disable modules unless you really want to improve the speed of emulation a little bit. If you really want to speed up emulation, consider rewriting some of the core PySim11 modules in C and send them to me :-)

Timer

Most of the timer functions of the 68HC11 are emulated. This includes:

The following aspects of the timer system are not yet implemented:

The timer system is disabled if the --no-timer command-line option is given.

Output Compare

The output compare system is fully emulated. This includes:

The output compare system is disabled if the --no-timer command-line option is given. Control of port pins is disabled if the --no-pio command-line option is given.

Input Capture

The input capture system is fully emulated. This includes:

The input capture system is disabled if the --no-pio command-line option is given. Input capture timings (i.e., TICx registers) are disabled if the --no-timer command-line option is given.

Parallel I/O

Parallel I/O is implemented through the waveform I/O graphical interface. Output pins are graphed in a window that mimics a logic analyzer. Input pins are stimulated using waveforms described by text files. These waveforms also appear in a waveform window.

The parallel I/O emulation assumes the 68HC11 is operating in single-chip mode, so that Ports B and C are available for general-purpose use.

The supported parallel I/O function include:

Functions not yet supported are:

The parallel I/O system is disabled if the --no-pio command-line option is given.

Pulse Accumulator

The pulse accumulator system is fully emulated. This includes:

The pulse accumulator system is disabled if the --no-pio command-line option is given. The timer module (disabled with --no-timer) maintains the PAIF and PAOVF flags, hence these may be enabled/disabled separately.

Interrupts

Interrupts are emulated by EVBU. All of the supported peripherals that generate interrupts are capable of generating interrupt events if enabled by their local masks and by the I bit in the CCR. Interrupt emulation includes:

Interrupt system functions not yet supported are:

Unsupported Peripherals

The following 68HC11 peripherals are not yet emulated by EVBU:

For another view of supported and unsupported peripherals, see the next section which provides a register view of peripheral support.

Register Support

This section describes the peripherals emulated by EVBU from a register point of view. In the table below, registers fully emulated have no comments (i.e., have a blank table cell). Registers not supported or fully emulated indicate the bits that are/are not supported.

RegisterAddressComments
PORTA 0x1000 
PIOC 0x1002Not supported
PORTC 0x1003 
PORTB 0x1004 
PORTCL 0x1005Not supported
DDRC 0x1007 
PORTD 0x1008 
DDRD 0x1009 
PORTE 0x100A 
CFORC 0x100B 
OC1MC 0x100C 
OC1MD 0x100D 
TCNT 0x100E 
TIC1 0x1010 
TIC2 0x1012 
TIC3 0x1014 
TOC1 0x1016 
TOC2 0x1018 
TOC3 0x101A 
TOC4 0x101C 
TOC5/TIC40x101E 
TCTL1 0x1020 
TCTL2 0x1021 
TMSK1 0x1022 
TFLG1 0x1023 
TMSK2 0x1024Prescaler bits writable any time
TFLG2 0x1025 
PACTL 0x1026 
PACNT 0x1027 
SPCR 0x1028Not supported
SPSR 0x1029Not supported
SPDR 0x102ANot supported
BAUD 0x102BNot supported
SCCR1 0x102CNot supported
SCCR2 0x102DNot supported
SCSR 0x102ENot supported
SCDR 0x102FNot supported
ADCTL 0x1030Not supported
ADR1 0x1031Not supported
ADR2 0x1032Not supported
ADR3 0x1033Not supported
ADR4 0x1034Not supported
BPROT 0x1035Not supported
EPROG 0x1036Not supported
OPTION 0x1039Not supported
COPRST 0x103ANot supported
PPROG 0x103BNot supported
HPRIO 0x103CRBOOT, SMOD, MDA, IRVNE not supported
INIT 0x103DRAM3-0 not supported
TEST1 0x103ENot supported
CONFIG 0x103FNot supported

Back to the top-level documentation

© 1999-2002, Copyright by Andrew Sterian; All Rights Reserved. mailto: steriana@claymore.engineer.gvsu.edu