Search found 10 matches

by tactif-cie
Tue Jun 25, 2019 10:35 pm
Forum: Newbies
Topic: 6502 + ARM micro controller = I don't understand clock cycle
Replies: 32
Views: 6671

Re: 6502 + ARM micro controller = I don't understand clock c


Ah yes, so you do. But you're doing it before setting Phi2 low. So, you stop driving the databus just before the clock edge which the 6502 uses to sample the bus. This might be fine, but I would suggest you move this statement to after the one which drops Phi2.


Oh yeah, I see what to mean ! I ...
by tactif-cie
Sun Jun 23, 2019 12:11 pm
Forum: Newbies
Topic: 6502 + ARM micro controller = I don't understand clock cycle
Replies: 32
Views: 6671

Re: 6502 + ARM micro controller = I don't understand clock c

Somewhere you need to set the DB back to input mode...

I do, setting the DB in input mode is the first line of my ISR routine

How do your timings compare to what's in the data sheet?

Unfortunately I don't know. The Teensy 3.6 is a fast micro controller and I have no solution to know how to ...
by tactif-cie
Sat Jun 22, 2019 4:12 pm
Forum: Newbies
Topic: 6502 + ARM micro controller = I don't understand clock cycle
Replies: 32
Views: 6671

Re: 6502 + ARM micro controller = I don't understand clock c

That's what I tried before and got no result

Like in


set DATABUS in input mode // 6502 drives the bus
if flag
set PHI2 HI
get RW
get ADDR
if RW == READ
set DATABUS in output mode // Micro controller drives the bus
write DATABUS with value from ADDR
else
read DATABUS and store in ADDR ...
by tactif-cie
Sat Jun 22, 2019 2:30 pm
Forum: Newbies
Topic: 6502 + ARM micro controller = I don't understand clock cycle
Replies: 32
Views: 6671

Re: 6502 + ARM micro controller = I don't understand clock c

I tried several scenarios, the last one in pseudo code is


set DATABUS in input mode // 6502 drives the bus
if flag
set PHI2 HI
get RW
get ADDR
else
if RW == READ
set DATABUS in output mode // Micro controller drives the bus
write DATABUS with value from ADDR
else
read DATABUS and store ...
by tactif-cie
Sat Jun 22, 2019 2:00 pm
Forum: Newbies
Topic: 6502 + ARM micro controller = I don't understand clock cycle
Replies: 32
Views: 6671

Re: 6502 + ARM micro controller = I don't understand clock c

I just checked again, $FFFE/$FFFF contains EA so the 6502 should jump to EAEA address and that never happen

I'm certainly doing something wrong, but I really don't see where is the mistake - I checked all the wires, checked again my interrupt routine, port reading and writing

I suspect a problem ...
by tactif-cie
Sat Jun 22, 2019 1:22 pm
Forum: Newbies
Topic: 6502 + ARM micro controller = I don't understand clock cycle
Replies: 32
Views: 6671

Re: 6502 + ARM micro controller = I don't understand clock c

I switched to a CMD G65SC02, the behavior of the cpu seems more reliable, even if it's still not ok because now I'm facing another problem :

VCC is 3.3v
The emulated ram contains only NOPs (EA) opcodes
The NMI, RDY and IRQ pins are tied up to VCC through 4.7K resistors

After RESET the cpu never ...
by tactif-cie
Thu Jun 13, 2019 10:38 am
Forum: Newbies
Topic: 6502 + ARM micro controller = I don't understand clock cycle
Replies: 32
Views: 6671

Re: 6502 + ARM micro controller = I don't understand clock c

Before giving up with the NMOS at 3.3v and ordering a 65C02, I would really appreciate your advice about the code of my interrupt service routine. Can you see something I do the wrong way ?

Meaningful code blocks are

On micro controller start :


pinMode(SIG_RESET, OUTPUT);
pinMode(SIG_CLOCK ...
by tactif-cie
Mon Jun 10, 2019 11:35 am
Forum: Newbies
Topic: 6502 + ARM micro controller = I don't understand clock cycle
Replies: 32
Views: 6671

Re: 6502 + ARM micro controller = I don't understand clock c

Welcome! Certainly you need to reconcile your CPU choice and your voltage. The Teensy 3.5 runs at 5V, so that's another way to get the Teensy and the 6502 working together. Using your Teensy 3.6 with a modern CMOS 6502 is also a good idea - especially if you can be extra-sure of getting a genuine ...
by tactif-cie
Mon Jun 10, 2019 9:44 am
Forum: Newbies
Topic: 6502 + ARM micro controller = I don't understand clock cycle
Replies: 32
Views: 6671

Re: 6502 + ARM micro controller = I don't understand clock c

Thanks a lot for your answers, I'm not alone anymore :-) But now I have more questions and I must rephrase some points of my initial post

Wilson, I know http://wilsonminesco.com/6502primer and theses pages are very valuable, I've read most of them during the last weeks but I still struggle to ...
by tactif-cie
Sun Jun 09, 2019 2:05 pm
Forum: Newbies
Topic: 6502 + ARM micro controller = I don't understand clock cycle
Replies: 32
Views: 6671

6502 + ARM micro controller = I don't understand clock cycle

Hi there !

I'm a hobbist, and newbie in electronics.

I've an NMOS 6502 wired to a modern micro controller (a Teensy 3.6, running at 180 mhz)
Data bus, address bus, Phi1, Phi2, Phi0, Rw and RST are wired
RDY, NMI, IRQ are tied up to VCC with 5.1k resistors (I did not had the recommended 3K)
I've ...