i2cslave %10100000, i2cfast, i2cword
writei2c 0, (%00000000, %00000000, %10000001, %00000000, %00110101)
pause 10
writei2c 8, (%00000000, %00010000, %00000101, %00000000, %00101000)
pause 10
writei2c 16, (%00000000, %00011110, %01000001, %00000000, %00110101)
pause 10
writei2c 24, (%00000000, %00010000, %00000101, %00000000, %00101000)
pause 10
writei2c 32, (%00000000, %00011101, %00001001, %00000000, %00110101)
pause 10
writei2c 40, (%00000000, %00010001, %00000101, %00000000, %00101000)
pause 10
writei2c 48, (%00000000, %00011101, %10000001, %00000000, %00110101)
pause 10
[...]
i2cslave %10100000, i2cfast, i2cword
main:
if pin2 = 1 then playsong
goto main
playsong:
w3 = 0
do until w3 > 4224
readi2c w3, (b3, b2, b1, b5, b4)
pause w1
let pins = b1
pause w2
let pins = %00000001
w3 = w3 + 8
loop
goto main
Timer2? SFR?By twiddling with Timer2 via SFR's you should be able to get a fairly accurate timebase. Unfortunately that means delving into the depths of PICmicro datasheets.
I just read over the entire thread. There's a couple more options which I could explore, but I'm still going to try my best to fudge it with the EEPROM!Now might be a good time to back to the begining of this thread and read it all through again. The answers (and warnings) to your latest observations are all there.
I'm curious. How does one do this?I've now successfully managed to extract note charts from the Guitar Hero game.
Here's a suggestion. If you need a variable amount of delay, put a 10k (or so) potentiometer between VDD and GND and put the middle terminal into one of the ADC input pins on the PICAXE. This is nothing more than a continuously-variable voltage divider.I'm hoping that with a bit of fiddling with the time delays, and some trial and error, I'll be able to get it working - this worked first time round!
each tick = 16us
1ms = 1000us
62.5 minor ticks = 1ms
preload value = 65473.5