Example program with periodic variable stimulation – Freescale Semiconductor Microcontrollers User Manual

Page 640

Advertising
background image

ColdFire V1 Full Chip Simulation Connection

True Time I/O Stimulation

640

Microcontrollers Debugger Manual

Listing 28.6 IO_Show Procedure in io_demo.c

static void IO_Show(void) {
for (;;) { // endless loop
dir = 1;
do {
Delay();
PORT_DATA++;
} while ((dir == 1) && (PORT_DATA != 255));
dir = -1;
do {
Delay();
PORT_DATA--;
} while ((dir == -1) && (PORT_DATA != 0));
}
}

Example Program with Periodic Variable
Stimulation

1. Choose Simulator > Reset.

2. Choose Simulator > Load Io_demo.abs.

3. Choose Component > Open > Stimulation

Figure 28.73

shows the Stimulation component.

Figure 28.73 Stimulation Component Window

4. Activate the Stimulation Window by clicking on it.

5. Choose Stimulation > Open File io_var.txt.

6. Choose Stimulation > Execute.

7. Choose Run > Start/Continue.

Advertising