Japanese
★ INDEX ▲ | STN-5 | STN-6 | STN-9 | STN-18 | STN-19 | STN-21 | STN-22 ▼
STN-18
Usage restrictions regarding system programs
issue number: | STN-18 |
date of issue: | 95/01/20 |
media: | ●Common | ○CD-ROM | ○Cartridge | ○Others |
connection: | ●Program | ○Hard | ○Manual | ○Tools | ○Game | ○ Bug | ○Others |
Information distinction: | ●New | ○Change | ○Addition |
importance: | ●Strict observance | ○Recommended | ○Reference | ○Others |
attached file: | ●No | ○ Yes |
Subject supplement: | Restrictions on the use of the SYS_SETSINT() function from slave CPUs |
Contents
When the SYS_SETSINT() function is used from the slave SH, the correct default value will not be written to the corresponding vector in the slave vector table indicated by vector number Num.
Do not use the default registration method of specifying the address as 0 from the slave SH.
There is no problem in operating the master and slave vector tables from the master SH. Also, if you need to return the slave vector to the default registration, use the method below.
■How to operate
- ●When the slave SH operates the slave vector independently
- In a case where the slave SH program resides in work RAM, if the slave automatically uses different interrupt handling depending on the situation, at the beginning (when the default can be obtained),
- func_org = SYS_GETSINT(Num);
- After saving in a variable and registering and updating the desired processing routine,
- SYS_SETSINT(Num, func_1st);
:
SYS_SETSINT(Num, func_2nd);
:
- To return to the default, register the first address.
- SYS_SETSINT(Num, func_org);
- ●When the master SH operates the slave vector
- In cases where the slave SH program is reread at each stage, and the master frequently turns the slave ON/OFF, it is sufficient to initialize the slave vector before the master turns the slave ON or after turning it OFF. , from the master SH at the timing mentioned above,
- SYS_SETSINT(Num+0x100, 0);
- Execute.
By adding 0x100 to the vector number, the method of manipulating the slave vector from the master SH can also be used for normal processing routine registration.
that's all
★ INDEX ▲ | STN-5 | STN-6 | STN-9 | STN-18 | STN-19 | STN-21 | STN-22 ▼
Copyright SEGA ENTERPRISES, LTD., 1997