Changes

Jump to: navigation, search

SOUNDCHIP SFG-01 MBIOS

977 bytes added, 12:58, 27 June 2021
5-1 Program Example
Program explanations will be made in the following sections.
With the example program, it is assumed that the VDP and PPI of the MSX system have already been Initialized by MSX-BASIC
 
===5.1.1 Program structure===
 
Lines between 35 and 50 show the framework of the sample program.
Here, the IRQ mode is set to mode-1. Stack area is defined, and SFG-01 is set to slot 3. As well as initializing the system, UISV and AST vectors are defined in the MIDB.
Note the clock-B vector, defined M line 46, routes the control to interrupt processing entry lines 195 and 196); then real time rhythm handler "auto:" (lines 224 to 244) is invoked. The idea of the program is to use clock-B for the auto-rhythm clock, handle the events there, and play them in the main loop of the program.
 
===5.1.2 Definition of instruments===
 
In the sample program, IDB#P0, IDB#P1 and IDB#0 are defined in the line numbers between 59 and 129. Between lines 141 and 144, the channels tithe FM sound generator IC are assigned to the above IDB's.
Assignment details are;
 
IDB#0 channels 0,2,3,4,5
IDB#1 channel 1
IDB#P0 channel 6
IDB#P1 channel 7
==5-2 Supplementary explanation for recording and playback programming==

Navigation menu