cbfs

package
v0.0.0-...-2913399 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 4, 2024 License: GPL-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const CBFSHeaderMagic = 0x4F524243

Variables

This section is empty.

Functions

This section is empty.

Types

type ArchType

type ArchType uint32

func (ArchType) String

func (a ArchType) String() string

type CBFSFileHeader

type CBFSFileHeader struct {
	Magic    [8]byte
	Len      uint32
	Type     FileType
	CheckSum uint32
	Offset   uint32
}

type CBFSHeader

type CBFSHeader struct {
	Magic         uint32
	Version       uint32
	ROMSize       uint32
	BootBlockSize uint32
	Align         uint32
	Offset        uint32
	Architecture  ArchType
	Pad           [1]uint32
}

func (CBFSHeader) String

func (c CBFSHeader) String() (ret string)

type CBFSReader

type CBFSReader interface {
	GetFile(name string) ([]byte, error)
	ListFiles() ([]string, error)
}

func OpenFile

func OpenFile(file *os.File) (CBFSReader, error)

func OpenROM

func OpenROM() (CBFSReader, error)

type FileType

type FileType uint32

func (FileType) String

func (f FileType) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL