Documentation ¶
Overview ¶
Package cdf implemnents the various CDF type cartridge mappers including CDFJ. It was developed with reference to Darrell Spice's CDJF blog and the source to the various example ROMs therein
https://atariage.com/forums/forum/262-cdfj/
Also, it seems that most complete survey of details for this cartridge type is the Stella source code. Therefore, I have resorted to the study of the CartCDF.cxx file as found in Stella 6.4.
Note that all CDF formats rely on the arm7 package.
Index ¶
- Constants
- func NewCDF(env *environment.Environment, version string, data []byte) (mapper.CartMapper, error)
- type Registers
- type State
- type Static
- func (stc *Static) HotLoad(cartData []byte)
- func (mem *Static) IsExecutable(addr uint32) bool
- func (stc *Static) MapAddress(addr uint32, write bool) (*[]byte, uint32)
- func (stc *Static) Read16bit(addr uint32) (uint16, bool)
- func (stc *Static) Read32bit(addr uint32) (uint32, bool)
- func (stc *Static) Read8bit(addr uint32) (uint8, bool)
- func (stc *Static) Reference(segment string) ([]uint8, bool)
- func (stc *Static) ResetVectors() (uint32, uint32, uint32)
- func (stc *Static) Segments() []mapper.CartStaticSegment
- func (stc *Static) Snapshot() *Static
Constants ¶
const ( DSCOMM = 32 DSJMP = 33 )
registers should be accessed via readDatastreamPointer() and updateDatastreamPointer(). Actually reading the data in the data stream should be done by streamData().
The following values can be used for convenience. The numbered datastreams can be accessed numerically as expected.
The AMPLITUDE register must be accessed with version.amplitude because it can change depending on the CDF version being emulated.
const ( NumDatastreams = 32 NumMusicDataFetchers = 3 )
Variables ¶
This section is empty.
Functions ¶
func NewCDF ¶
func NewCDF(env *environment.Environment, version string, data []byte) (mapper.CartMapper, error)
NewCDF is the preferred method of initialisation for the CDF type.
Types ¶
type Registers ¶
type Registers struct { FastFetch bool SampleMode bool // the MusicFetcher and Datastream feilds are copies of the data as it // exists in ARM memory MusicFetcher [NumMusicDataFetchers]musicDataFetcher Datastream [NumDatastreams]datastream }
Registers implements mappers.Registers.
type Static ¶
type Static struct {
// contains filtered or unexported fields
}
Static implements the mapper.CartStatic interface.
func (*Static) IsExecutable ¶ added in v0.20.0
IsExecutable implements the arm.SharedMemory interface.
func (*Static) MapAddress ¶
MapAddress implements the arm7tdmi.SharedMemory interface.
func (*Static) ResetVectors ¶
ResetVectors implements the arm7tdmi.SharedMemory interface.
func (*Static) Segments ¶ added in v0.18.0
func (stc *Static) Segments() []mapper.CartStaticSegment
Segments implements the mapper.CartStatic interface