Oriculator (WIP)
Oriculator (WIP)
I decided to write a new Oric emulator entirely from scratch, simply to give me something to do on the train to work
It is written purely in C, and uses SDL, so it will be possible to port it to loads of operating systems and devices.
Every part of the emulation is written from scratch, including 6502/AY/VIA, just because I always wanted to write a complete emulation.
It includes a very cool debugger/monitor, which will seriously kick ass when i've finished with it.
Current status:
6502: 100% done
VIA: Everything except shift register (don't worry, SR *will* be emulated)
AY: IO Port. No sound yet.
Tape: Not yet...
Disk: Not yet...
Some screenshots:
It is written purely in C, and uses SDL, so it will be possible to port it to loads of operating systems and devices.
Every part of the emulation is written from scratch, including 6502/AY/VIA, just because I always wanted to write a complete emulation.
It includes a very cool debugger/monitor, which will seriously kick ass when i've finished with it.
Current status:
6502: 100% done
VIA: Everything except shift register (don't worry, SR *will* be emulated)
AY: IO Port. No sound yet.
Tape: Not yet...
Disk: Not yet...
Some screenshots:
Last edited by Xeron on Thu Mar 26, 2009 7:49 am, edited 1 time in total.
I'm looking forward to this greatly too. The screenshot (if they are not just a mockup) look great.
What i'd love to see is..
The Debugger to (optionally) show a breakdown of AY registers(Unlike Caloric and Euphoric)
The Debugger to (optionally) show a matrix for the keyboard and give some visual flag for the currently selected column/row.
Complete emulation of the VIA.
Memory Dump facility to allow potentially 64K to be saved or loaded as a file(could be useful for testing emu without tape and disk)
Option to close tape file once loaded. Euphoric always held onto Tape file in order to support multi-loads but for development this is a pain.
What i'd love to see is..
The Debugger to (optionally) show a breakdown of AY registers(Unlike Caloric and Euphoric)
The Debugger to (optionally) show a matrix for the keyboard and give some visual flag for the currently selected column/row.
Complete emulation of the VIA.
Memory Dump facility to allow potentially 64K to be saved or loaded as a file(could be useful for testing emu without tape and disk)
Option to close tape file once loaded. Euphoric always held onto Tape file in order to support multi-loads but for development this is a pain.
Actual screenshots, not mockupsTwilighte wrote:I'm looking forward to this greatly too. The screenshot (if they are not just a mockup) look great.
Already done (although sound is still not actually emulated).The Debugger to (optionally) show a breakdown of AY registers(Unlike Caloric and Euphoric)
Consider it on my todo list.The Debugger to (optionally) show a matrix for the keyboard and give some visual flag for the currently selected column/row.
Only the SR is missing, and I fully intend to put that in.Complete emulation of the VIA.
On my todo list.Memory Dump facility to allow potentially 64K to be saved or loaded as a file(could be useful for testing emu without tape and disk)
I'm doing the tape stuff now. My emulator loads the whole tape image into RAM (for .TAP files).Option to close tape file once loaded. Euphoric always held onto Tape file in order to support multi-loads but for development this is a pain.
If WAV files are large, i might read them in chunks, but i could easily close the file when the tape motor is off.
Wow, do you have HIRES working too?Xeron wrote:Actual screenshots, not mockups
Other wish list items
1)Emulate the blur and oblong pixels found on real orics when used on a TV set.
1.1)Emulate the 60/50Hz switch used on some old games for visual effects of explosions.
2)Another idea is to have a status bar at the bottom of the window to reflect hardware currently attached to the virtual machine like Tape file, Disk drives(with lights to show activity), lightpen, Joysticks(moving to show activity),Sync to Cas In mod(This is emulated in Euphoric) etc. For graphics i can possibly provide these
3)Fabrice added a second AY chip using that spare bit in 6522 port B to enable it. And other Oricians have also done this. It would be great if this was supported.
4)Realistic tape handling like TZX files on Spectrum. So that actual loading sound is provided and allows games like loneraider to sound the loading tune. If added as part of wish list item 2) could have a Cassette player style Play, Rewind, Previous Track, Next Track gfx.
5)A facility similar to Dosbox that allowed a session to be captured to an AVI but this time something a bit more standard.
That reminds me, some visual indication of the cassette motor relay position would be cool. Not sure how many people used the remote on cassette recorders but i guess a must for multiloads?Xeron wrote:If WAV files are large, i might read them in chunks, but i could easily close the file when the tape motor is off.
Very nice
Do you think it would be easy to implement a "pal emulator" like in Caloric: http://caloric.anarcho.fr/screenshots.html ? (the effect with the dark horizontal lines and the slight horizontal bluring)
Would also be nice if you do that, to take the opportunity to implement an horizontal scaling, to have the 5:4 ratio of the real oric (pixels are not square on the oric, which is why the CIRCLE instruction gives elipses).
Do you think it would be easy to implement a "pal emulator" like in Caloric: http://caloric.anarcho.fr/screenshots.html ? (the effect with the dark horizontal lines and the slight horizontal bluring)
Would also be nice if you do that, to take the opportunity to implement an horizontal scaling, to have the 5:4 ratio of the real oric (pixels are not square on the oric, which is why the CIRCLE instruction gives elipses).
PAL emulation: Should be possible
Scaling: Sure, but only after i've added an OpenGL rendering mode, since scaling pixels 1/5th bigger would look terrible with simple scaling, and bicubic interpolation will add quite an overhead if i'm using the CPU
Both things are waaaaaay down the list. First of all I want to get the emulation working properly.
I'm having some weird problems with my tape emulation, though. I'm having to insert about 6 sync pulses per byte instead of 4 (tuning the timings seems to make no difference), also i have to insert an extra $16 byte at the start of the TAP file. But i'm confused how TAP files could ever work withoug that; stepping over the ROM code, it seems to find the first $16, THEN try and read 3 more!
I want to get tape emulation tied up before tackling sound and disk.
Scaling: Sure, but only after i've added an OpenGL rendering mode, since scaling pixels 1/5th bigger would look terrible with simple scaling, and bicubic interpolation will add quite an overhead if i'm using the CPU
Both things are waaaaaay down the list. First of all I want to get the emulation working properly.
I'm having some weird problems with my tape emulation, though. I'm having to insert about 6 sync pulses per byte instead of 4 (tuning the timings seems to make no difference), also i have to insert an extra $16 byte at the start of the TAP file. But i'm confused how TAP files could ever work withoug that; stepping over the ROM code, it seems to find the first $16, THEN try and read 3 more!
I want to get tape emulation tied up before tackling sound and disk.
Yes indeed, seeXeron wrote:also i have to insert an extra $16 byte at the start of the TAP file. But i'm confused how TAP files could ever work withoug that; stepping over the ROM code, it seems to find the first $16, THEN try and read 3 more!
http://forum.defence-force.org/viewtopic.php?t=63
Well, i found a workaround for the inadequacies of the .TAP format when using "real" tape emulation. I insert an extra $16 at the start of the file when loading it.
Then, when the motor is switched off, if the next byte is a $16, i send a load of dummy $16s when the motor is re-started. This allows the Atmos welcome tape image to work, for example. Without my extra $16s, the second part is way past the measly 3 synchro bytes when the second part tries to load.
Of course, I *am* going to do a rom patch for faster .TAP loading, but i wanted an "authentic" mode, which now works great
Then, when the motor is switched off, if the next byte is a $16, i send a load of dummy $16s when the motor is re-started. This allows the Atmos welcome tape image to work, for example. Without my extra $16s, the second part is way past the measly 3 synchro bytes when the second part tries to load.
Of course, I *am* going to do a rom patch for faster .TAP loading, but i wanted an "authentic" mode, which now works great
I started the ground work for sound emulation.
I put the basics in required to output sound, but since the AY emulation wasn't ready yet, I decided to mix in the (cycle exact) tape input. Result: Authentic tape noise from .TAP files
Not really useful, but fun
Of course, authentic tape noise from .WAV files (when i get around to wav support) will be even easier.
Obviously you'll have to disable turbotape to get tape noise with TAP files.
I put the basics in required to output sound, but since the AY emulation wasn't ready yet, I decided to mix in the (cycle exact) tape input. Result: Authentic tape noise from .TAP files
Not really useful, but fun
Of course, authentic tape noise from .WAV files (when i get around to wav support) will be even easier.
Obviously you'll have to disable turbotape to get tape noise with TAP files.
I know Dbug is aware of this engine, but it may assist you in developing more accurate AY emulation and remove the hastle of rendering it on Windows XP onwards which (in Euphoric) has caused no end of hastle trying to get it to sound reasonable..
http://leonard.oxg.free.fr/
This Leonard guy developed a YM emulator which was the Yamaha version of the AY chipset afaik.
http://leonard.oxg.free.fr/
This Leonard guy developed a YM emulator which was the Yamaha version of the AY chipset afaik.
Even though its way to early, I decided to put a build of Oriculator online with some (minimal) documentation.
Please, don't report bugs or incompatibilities yet. Its too early for that Just play with it and have fun...
Oriculator preview.
Please, don't report bugs or incompatibilities yet. Its too early for that Just play with it and have fun...
Oriculator preview.
0.0.2
Just uploaded an update (0.0.2).
Made a first try at AY sound. Its rubbish, but all 3 voices are emulated. Consider sound a work in progress
Other changes include a reduction in CPU usage, working blink attribute
Made a first try at AY sound. Its rubbish, but all 3 voices are emulated. Consider sound a work in progress
Other changes include a reduction in CPU usage, working blink attribute