vii
7.2.3
Writing Non-kernel Interrupt Handler.................................................................................. - 216 -
7.2.4
Writing Cyclic Handler/Alarm Handler ................................................................................. - 216 -
7.3
Modifying MR100 Startup Program.............................................................................................. - 218 -
7.3.1
C Language Startup Program (crt0mr.a30)........................................................................... - 219 -
7.4
Memory Allocation.......................................................................................................................... - 224 -
7.4.1
Section used by the MR100..................................................................................................... - 225 -
8.
Using Configurator ................................................................................................................................. 227
8.1
Configuration File Creation Procedure ..............................................................................................227
8.1.1
Configuration File Data Entry Format.......................................................................................227
Operator ...................................................................................................................................................................228
Direction of computation .........................................................................................................................................228
8.1.2
Configuration File Definition Items............................................................................................229
[( System Definition Procedure )]............................................................................................................................229
[( System Clock Definition Procedure )]..................................................................................................................231
[( Definition respective maximum numbers of items )]..........................................................................................232
[( Task definition )]...................................................................................................................................................234
[( Eventflag definition )] ..........................................................................................................................................236
[( Semaphore definition )]........................................................................................................................................237
[(Data queue definition )] ........................................................................................................................................238
[( Short data queue definition )]..............................................................................................................................239
[( Mailbox definition )] .............................................................................................................................................240
[( Fixed-size memory pool definition )]....................................................................................................................241
[( Variable-size memory pool definition )] ...............................................................................................................242
[( Cyclic handler definition )]...................................................................................................................................244
[( Alarm handler definition )] ..................................................................................................................................245
[( Interrupt vector definition )]................................................................................................................................246
[( Fixed interrupt vector definition )]......................................................................................................................247
8.1.3
Configuration File Example.........................................................................................................250
8.2
Configurator Execution Procedures ...................................................................................................254
8.2.1
Configurator Overview.................................................................................................................254
Executing the configurator requires the following input files: ..............................................................................254
When the configurator is executed, the files listed below are output. ..................................................................254
8.2.2
Setting Configurator Environment .............................................................................................255
8.2.3
Configurator Start Procedure......................................................................................................256
8.2.4
Precautions on Executing Configurator......................................................................................256
8.2.5
Configurator Error Indications and Remedies ...........................................................................257
Error messages ........................................................................................................................................................257
Warning messages ...................................................................................................................................................259
9.
Sample Program Description.................................................................................................................. 260
9.1
Overview of Sample Program .............................................................................................................260
9.2
Program Source Listing.......................................................................................................................261
9.3
Configuration File................................................................................................................................262
10.
Stack Size Calculation Method ........................................................................................................... 264
10.1
Stack Size Calculation Method...........................................................................................................264
10.1.1
User Stack Calculation Method...................................................................................................266
10.1.2
System Stack Calculation Method ..............................................................................................268
10.2
Necessary Stack Size...........................................................................................................................272
11.
Note.................................................................................................................................................. - 275 -
11.1
The Use of INT Instruction............................................................................................................ - 275 -
11.2
The Use of registers of bank .......................................................................................................... - 275 -
11.3
Regarding Delay Dispatching ........................................................................................................ - 276 -
11.4
Regarding Initially Activated Task................................................................................................ - 277 -
12.
Appendix .......................................................................................................................................... - 279 -
12.1
Data Type ........................................................................................................................................ - 279 -
12.2
Common Constants and Packet Format of Structure .................................................................. - 280 -
12.3
Assembly Language Interface........................................................................................................ - 282 -