Return to previous page | Return to menu | Go to next page
6.1.2 Command code handshake
This is a method of issuing a command after checking whether the command code is “00h”. Check that the command code is “00h” on the main system, and issue commands in the order from block 1 to block 8. Similarly, the sound driver simply checks the block 1 to block 8 in order and processes the command if a command code is written.
The command code is cleared by the sound driver at the end of processing, so if the command code is not yet cleared to “00h”, it means that the command is still being processed or is waiting to be started. I mean. Conversely, when the issued command code is cleared to "00h", it means that the sound driver command processing has been completed.
Precautions (for command code handshake)
When issuing the - command, write the command code after writing all the command parameters. The sound driver takes command parameters as soon as it detects a command code, so if you write the command code first, processing may occur with unexpected command parameters.
- The sound driver checks block 1 to block 8 in order, so if you simply search for an empty block and set a command, the command will be executed in a different order from the order written by the main system. there is. If the execution order is changed, the system may malfunction. Therefore, when executing a process whose execution order is fixed, set the command so that the order is not changed.
- In this procedure, the main system and the sound driver are processed asynchronously, so the command order may be changed even if the above precautions are observed. If you need to follow the execution order, avoid this by using only one command block and verifying that the previous command has been processed before issuing the next command.
Return to previous page | Return to menu | Go to next page