Search found 33 matches

by dp11
Mon Dec 12, 2022 11:18 am
Forum: Emulation and Simulation
Topic: Illegal opcodes emulation in simple emulator written in C
Replies: 12
Views: 8325

Re: Illegal opcodes emulation in simple emulator written in

I would probably check to see how good the emulation is of the instructions with https://github.com/Klaus2m5/6502_65C02_functional_tests and my cycle timing checker which includes undocumented instructions : https://github.com/dp111/6502Timing
by dp11
Sun Sep 04, 2022 5:21 pm
Forum: Emulation and Simulation
Topic: 6502 Instruction timing tester
Replies: 2
Views: 30147

Re: 6502 Instruction timing tester

I've added vectors to the beginning of the code to make it easier to port the test to another system. Now you just need to patch the vectors with putchar, start timer and read timer, instead of building the code.
by dp11
Mon Aug 29, 2022 8:47 pm
Forum: Emulation and Simulation
Topic: 6502 Instruction timing tester
Replies: 2
Views: 30147

6502 Instruction timing tester

I've created a 6502 /65C02/65C12 instruction timing checking test suite.

It first of all targeted BBC micro and Master machines ( which have been checked against real hardware). I've extended it to support C64 , but this hasn't yet been checked against real hardware. It passes in VICE , but not in ...
by dp11
Tue Oct 26, 2021 11:12 pm
Forum: Emulation and Simulation
Topic: 6502 emulation: looking for microcontroller recommendations
Replies: 45
Views: 26861

Re: 6502 emulation: looking for microcontroller recommendati

Please do play with my stuff. But I will warn you that it is heavily optimisied for for the tube. If you spot any performance improvements do let me know. Decimal adc has the feeling of a few extra cycles could be removed, but I haven't put any time into it.
by dp11
Wed Oct 20, 2021 10:16 pm
Forum: Emulation and Simulation
Topic: 6502 emulation: looking for microcontroller recommendations
Replies: 45
Views: 26861

Re: 6502 emulation: looking for microcontroller recommendati

I should say pizero non jitter is about 290MHz.the code is on GitHub search for PiTubeDirect. I have the last few bit to do to the jitter. Soon it should be merged into master.

You can't buy the Pizero Silcon unless you talk to broadcom directly and want to buy a lot of them AFAIK.
by dp11
Wed Oct 20, 2021 8:52 pm
Forum: Emulation and Simulation
Topic: 6502 emulation: looking for microcontroller recommendations
Replies: 45
Views: 26861

Re: 6502 emulation: looking for microcontroller recommendati

My Rp2040 6502 core referred to earlier has the aim to be fast but not cycle accurate. On average the 6502 clock rate is 1/4 of the arm M0 clock rate. My pi jit 6502 core is 1/2.5 of the arm clock for a pizero, 1/1.4 for a pi3b and 1 to 1 ish for a pi4. Self modifying code reduces these figures. The ...
by dp11
Thu Jul 15, 2021 1:14 pm
Forum: Emulation and Simulation
Topic: Raspberry Pi Pico 6502 emulator
Replies: 49
Views: 55600

Re: Raspberry Pi Pico 6502 emulator

Hoglet has kindly tested this and fixed a few issues. I have also fixed my build, but haven't tested it yet.
by dp11
Wed Jul 14, 2021 8:07 pm
Forum: Emulation and Simulation
Topic: Raspberry Pi Pico 6502 emulator
Replies: 49
Views: 55600

Re: Raspberry Pi Pico 6502 emulator

I've committed a fix. I haven't managed to test it as I have broken my build else where.
by dp11
Wed Jul 14, 2021 4:58 am
Forum: Emulation and Simulation
Topic: Raspberry Pi Pico 6502 emulator
Replies: 49
Views: 55600

Re: Raspberry Pi Pico 6502 emulator

Yep that's broken, I'll fix it. Thanks for the report
by dp11
Mon Jul 12, 2021 5:13 pm
Forum: Emulation and Simulation
Topic: Raspberry Pi Pico 6502 emulator
Replies: 49
Views: 55600

Re: Raspberry Pi Pico 6502 emulator

Just to check I'm see what you are seeing can you let me know the error output ?
by dp11
Sat Jul 10, 2021 8:44 am
Forum: Emulation and Simulation
Topic: Raspberry Pi Pico 6502 emulator
Replies: 49
Views: 55600

Re: Raspberry Pi Pico 6502 emulator

Sorry for the delay. I was pretty sure the core passed the tests. I'll take a look next week.
by dp11
Mon Jun 28, 2021 8:40 pm
Forum: Emulation and Simulation
Topic: Raspberry Pi Pico 6502 emulator
Replies: 49
Views: 55600

Re: Raspberry Pi Pico 6502 emulator

You might like to check out my 6502 core for the BBC tube interface.

https://github.com/dp111/PicoTube
by dp11
Sat Aug 29, 2020 6:45 pm
Forum: Programming
Topic: Code optimization technique
Replies: 15
Views: 2288

Re: Code optimization technique

You can move stx up in the code then peep hole can spot tax stx and just do sta.
by dp11
Thu Apr 23, 2020 8:39 am
Forum: Programming
Topic: Most efficient way to toggle a bit (flag) in memory
Replies: 22
Views: 9860

Re: Most efficient way to toggle a bit (flag) in memory

Yes it does add jitter, it does save a few cycles .
by dp11
Thu Apr 23, 2020 7:15 am
Forum: Programming
Topic: Most efficient way to toggle a bit (flag) in memory
Replies: 22
Views: 9860

Re: Most efficient way to toggle a bit (flag) in memory

All the above I think leads to now removing the zp sample location which make the average case even quicker

NMI_Handler:
PHA

; load sample into SID
@sample:
LDA $FFFF ; self-mod pointer to sample - overwrite this operand during init

; alternate high/low nybble
ASL flag
BCC @writeSID
INC ...