hrvach / oraopy Goto Github PK
View Code? Open in Web Editor NEWOrao emulator in Python
License: GNU General Public License v2.0
Orao emulator in Python
License: GNU General Public License v2.0
Just a wishlist,
I'd like to have save/load CPU/RAM state snapshots as a tool
to prepare collection of binary images for easy and fast loading
to FPGA emulation.
If there's no standardized binary form for image, i'd like to propose :)
"ORAO_SNAPSHOT\0": ascii 0-terminated header for file type.
follows multiple blocks of data, usually CPU state and RAM
0x01: block type 1 is header for CPU state
0x10: 8-bit length of data to follow not including this byte
.... 16 bytes of register states A X Y F SP PC etc.
0x02: block type 2 is header for RAM or ROM content
0x00 0x10: 16-bit starting address 0x1000
0x00 0x20: 16-bit length of block length thats follows, not including this length
... 0x2000 bytes of data
Hi,
I've been toying around with creating cc65 runtime for Orao.
In the process I've forked this emulator, and added following features (useful for development):
.prg
binaries generated by cc65Could you please add a LICENSE file to your project, so that I can fork under proper rules?
Thanks
It appears that cycle count constants are not correct.
Consulting this reference, all of the branch instructions take 2cy, +1 if branch occurs on the same page, and +2 if branch occurs on different page. Yet in the emulator most of the branch instructions are set to 4cy (except BVS 3cy), and +1 if the branch occurs. Page checking is not accounted.
Consulting the same reference LDA oper,X takes 4cy, +1 if page boundary is crossed, yet the emulator consumes 5cy regardless of crossing page boundary.
ldx #0
lda $22F0,x
and
ldx #$20
lda $22F0,x
(excluding LDX) both consume 5cy in the emulator, regardless of first not crossing the page boundary.
Same issue is also present with LDA oper,Y
HI!
seems that have small problems :)
$ python3 orao.py
pygame 1.9.6
Hello from the pygame community. https://www.pygame.org/contribute.html
Traceback (most recent call last):
File "orao.py", line 301, in
cpu.step()
File "orao.py", line 284, in step
instruction, addressing, cycles = self._opcodes[opcode]
KeyError: 255
I added 0xFF instruction as NOP, then it opened window with
graphics terminal showing just a white screen but no boot.
If I press any key then window closes and I get this error:
Traceback (most recent call last):
File "orao.py", line 315, in
for address, keycodes in cpu._kbd.iteritems():
AttributeError: 'dict' object has no attribute 'iteritems'
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.