Skip to content

Commit 60dc5eb

Browse files
committed
go6502.go: revised memory map due to pda6502 V1 schematic error.
74CH138 inputs reversed; splits ROM into two, moves VIA.
1 parent 27c5e08 commit 60dc5eb

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

go6502.go

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,8 @@ import (
2626
)
2727

2828
const (
29-
kernalPath = "rom/kernal.rom"
29+
kernalPath = "rom/kernal.rom"
30+
charRomPath = "rom/char.rom"
3031
)
3132

3233
func main() {
@@ -44,6 +45,11 @@ func mainReturningStatus() int {
4445
panic(err)
4546
}
4647

48+
charRom, err := memory.RomFromFile(charRomPath)
49+
if err != nil {
50+
panic(err)
51+
}
52+
4753
ram := &memory.Ram{}
4854

4955
via := via6522.NewVia6522(via6522.Options{
@@ -92,8 +98,9 @@ func mainReturningStatus() int {
9298

9399
addressBus, _ := bus.CreateBus()
94100
addressBus.Attach(ram, "ram", 0x0000)
95-
addressBus.Attach(via, "VIA", 0xC000)
96-
addressBus.Attach(kernal, "kernal", 0xE000)
101+
addressBus.Attach(via, "VIA", 0x9000)
102+
addressBus.Attach(charRom, "char", 0xB000)
103+
addressBus.Attach(kernal, "kernal", 0xF000)
97104

98105
exitChan := make(chan int, 0)
99106

0 commit comments

Comments
 (0)