Sample Program
FR Family MB2198-01 Emulating and Debugging Installation Guide, Doc. No. 002-05223 Rev. *A
7
2.2.1
Source Code
This sample code program
is only an example with no “great assignment“. It contains a simple wait-function
(
void
wait
), which needs an integer value for the wait time. The resulting delay time depends on the value itself
and the clock speed of the emulation system. This function uses the global variables
i
for counting.
The main program (
void
main
) set the LED port of the Starterkit MB91230 to output and low level. After this and
endless loop ist startet.
In this loop a call to the wait function is performed and the LED port register is increased.
By executing this small program the LEDs of the board are flashing. The left ones faster, the right ones in a lower
fequency.
MAIN.C
- description
- See README.TXT for project description and disclaimer.
----------------------------------------------------------------------*/
#
include
"mb91230.h"
unsigned int
i;
void
wait(
unsigned int
a)
{
for
(i=0; i<a; i++);
}
void
main(
void
)
{
PDR1=0x00;
DDR1=0xFF;
while
(1)
{
wait(20000);
PDR1++;
}
}
Содержание MB2147-01
Страница 9: ...FUJITSU SEMICONDUCTOR CONTROLLER MANUAL DSU FR EMULATOR MB2198 01 HARDWARE MANUAL CM71 00413 2E ...
Страница 10: ......
Страница 11: ...FUJITSU LIMITED DSU FR EMULATOR MB2198 01 HARDWARE MANUAL ...
Страница 12: ......
Страница 20: ...viii ...
Страница 22: ...x ...
Страница 56: ...34 CHAPTER 2 CONNECTION METHOD ...
Страница 64: ...42 CHAPTER 3 OPERATION METHOD ...
Страница 66: ......
Страница 69: ...47 APPENDIX A DSU FR Cable Specifications Figure A 2 Connector Terminal Arrangement for DSU 3 Pin 1 Pin 30 ...
Страница 76: ...54 APPENDIX B User System Specifications ...
Страница 78: ......
Страница 92: ......