first address read after Oric power on
Posted: Fri May 22, 2020 12:47 pm
Hi !
I would not to learn a bit more about Oric Emulation and working.
What is the first address that Oric 6502 execute in memory after cpu power on? is it 0x1000 ?
Also, witch compiler is requiered to compile Oricutron , is it gcc ?
I would not to learn a bit more about Oric Emulation and working.
What is the first address that Oric 6502 execute in memory after cpu power on? is it 0x1000 ?
Also, witch compiler is requiered to compile Oricutron , is it gcc ?
Code: Select all
from py65emu.cpu import CPU
from py65emu.mmu import MMU
f = open("program.rom", "rb") # Open your rom
# define your blocks of memory. Each tuple is
# (start_address, length, readOnly=True, value=None, valueOffset=0)
m = MMU([
(0x00, 0x200), # Create RAM with 512 bytes
(0x1000, 0x4000, True, f) # Create ROM starting at 0x1000 with your program.
])
# Create the CPU with the MMU and the starting program counter address
# You can also optionally pass in a value for stack_page, which defaults
# to 1, meaning the stack will be from 0x100-0x1ff. As far as I know this
# is true for all 6502s, but for instance in the 6507 used by the Atari
# 2600 it is in the zero page, stack_page=0.
c = CPU(mmu, 0x1000) # first address ?
# Do this to execute one instruction
c.step()