Soo. First update goes:
k-ww tipped me off how to read the am27c256 EPROM chip on the controller and this post is about my try to this exact thing.
To read it i need a MCU with 15 adress lines and 8 data lines. For this i used a Atmel ATmega32 and my STK500 board.
Hooked-up it looks like this:
As of now my code is as follows
- Code: Select all
#define F_CPU 3686400UL
char tegn = 0x00;
uint16_t output = 0;
DDRA = 0xFF;
DDRB = 0xFF;
DDRC = 0x00;
PORTA = 0x00;
PORTB = 0x00;
PORTA = output;
PORTB = (output >> 8);
if(output == 0b1000000000000000) //I have to blocks of debug-code in here as the output to the serial line seems strange somehow.
if(output == 0b0000000000000000)
tegn = PINC;
Some of my problems with this is that it newer sends the "16bit" message and not always the "15bit" one
For further debugging i hooked up my Logic16 logic analyzer:
And got this output:
I'd really appreciate if you can help me figure out what is "off" here!
IE to me it seems that the IC is sent 0b10001100 at T=60ms but sends 0b01000010 (0x42) to the PC...
Note that the parallel data and the serial data is off by almost a whole data packet off course.
Anyway. Off to bed. I've been at work all night