We've just updated MediaWiki and its underlying software. If anything doesn't look or work quite right, please mention it to us. --RanAS

SPC700/Driver Upload: Difference between revisions

From SnesLab
Jump to: navigation, search
(linkify main audio)
(added official port names)
Line 3: Line 3:
{| class="wikitable"
{| class="wikitable"
|-
|-
! Port Name (SPC side) !! Port Address (SPC side) !! Port Name (5A22 side) !! Port Address (5A22 side) !! Data
! Official Port Name !! Port Name (SPC side) !! Port Address (SPC side) !! Port Name (5A22 side) !! Port Address (5A22 side) !! Data
|+
|+
| CPUIO0 || 00F4h || APUIO0 || 2140h || The [[SPC IPL]] writes BBAAh here when ready, kick and kickback (as described by [[fullsnes]]) also go through here
| PORT0 || CPUIO0 || 00F4h || APUIO0 || 2140h || The [[SPC IPL]] writes BBAAh here when ready, kick and kickback (as described by [[fullsnes]]) also go through here
|+
|+
| CPUIO1 || 00F5h || APUIO1 || 2141h || The SPC IPL writes BBAAh here when ready, the 5A22 writes which command ("transfer" or "entry" as described by fullsnes) it wants the IPL to run here, and the driver data is uploaded through here too
| PORT1 || CPUIO1 || 00F5h || APUIO1 || 2141h || The SPC IPL writes BBAAh here when ready, the 5A22 writes which command ("transfer" or "entry" as described by fullsnes) it wants the IPL to run here, and the driver data is uploaded through here too
|+
|+
| CPUIO2 || 00F6h || APUIO2 || 2142h || The 5A22 writes the upload destination ARAM address here, and the entrypoint into the SPC program once all blocks have been uploaded
| PORT2 || CPUIO2 || 00F6h || APUIO2 || 2142h || The 5A22 writes the upload destination ARAM address here, and the entrypoint into the SPC program once all blocks have been uploaded
|+
|+
| CPUIO3 || 00F7h || APUIO3 || 2143h || The other byte of the upload destination ARAM address goes here.  This port appears to not be used for anything else during driver upload.
| PORT3 || CPUIO3 || 00F7h || APUIO3 || 2143h || The other byte of the upload destination ARAM address goes here.  This port appears to not be used for anything else during driver upload.
|}
|}



Revision as of 21:33, 2 July 2023

In order to use main audio (Blargg's trick notwithstanding), the 5A22 must first upload a sound driver to the SPC700 over the following four ports:

Official Port Name Port Name (SPC side) Port Address (SPC side) Port Name (5A22 side) Port Address (5A22 side) Data
PORT0 CPUIO0 00F4h APUIO0 2140h The SPC IPL writes BBAAh here when ready, kick and kickback (as described by fullsnes) also go through here
PORT1 CPUIO1 00F5h APUIO1 2141h The SPC IPL writes BBAAh here when ready, the 5A22 writes which command ("transfer" or "entry" as described by fullsnes) it wants the IPL to run here, and the driver data is uploaded through here too
PORT2 CPUIO2 00F6h APUIO2 2142h The 5A22 writes the upload destination ARAM address here, and the entrypoint into the SPC program once all blocks have been uploaded
PORT3 CPUIO3 00F7h APUIO3 2143h The other byte of the upload destination ARAM address goes here. This port appears to not be used for anything else during driver upload.

Fullsnes has pseudocode for the upload procedure in https://problemkaputt.de/fullsnes.htm#snesapumaincpucommunicationport and anomie's SPC700 Doc lists a very similar 11 step procedure.