Feature #78
closedGet chameleon v2 working
Added by foft over 6 years ago. Updated over 6 years ago.
0%
Description
Get the chameleon v2 board up and running.
Files
EN25QH128A(2T).pdf (2.2 MB) EN25QH128A(2T).pdf | foft, 05/14/2019 09:12 PM |
FO Updated by foft over 6 years ago Actions #1
we have sync...
zpu is running, tested with a display of toggling background
sdram is failing with 180 degrees
FO Updated by foft over 6 years ago Actions #2
sdram test passes with 270 degrees! Still no boot though, will resume testing tomorrow.
FO Updated by foft over 6 years ago Actions #3
Fiddled with sd card... blue screen and cassette boot beep. Hmmm.
FO Updated by foft over 6 years ago Actions #4
Seems I need to remove/re-insert the sdcard to boot. PS2 doesn't seem to work, so no menu. Perhaps that is why I get the beep (consol stuck??)
FO Updated by foft over 6 years ago Actions #5
consol is stuck because of the c64 keys supplied by chameleon 2 io. Tracking down why that is stuck, it has 3 sources: ir, docking or c64 itself
FO Updated by foft over 6 years ago Actions #6
Stuck keys were because the remote is not part of chameleon io, I hadn't removed the external signals and they were defaulting to the wrong state. Removed them now and typing in basic.
FO Updated by foft over 6 years ago Actions #7
Adding the chameleon_2 shiftreg component fixed up the ps2 keyboard sometimes not working. Also plumbed the sio tx to the red led.
FO Updated by foft over 6 years ago Actions #8
Main things to fix:
i) Joystick resetting system!
ii) sd card fiddling needed on first boot
FO Updated by foft over 6 years ago Actions #9
Fixed issue (i)
FO Updated by foft over 6 years ago Actions #10
Running NUMEN as a little test ;-)
FO Updated by foft over 6 years ago Actions #11
Different sd card worked, think its a card re-initialization issue...
FO Updated by foft over 6 years ago Actions #12
Haha, this was a known issue on the old version of the chameleon (in many cores) and this one too...
FO Updated by foft over 6 years ago Actions #13
Trying to get the ir remote working, should 'just work' since its enabled in chameleon io2 but ... it doesn't
FO Updated by foft over 6 years ago Actions #14
Weird thing in chameleon_cdtv_remote, the timer counts when ena_1mhz is high AND halfway between. So is running at 2x the expected rate. Its not clear why.
FO Updated by foft over 6 years ago Actions #15
Still don't understand what the logic analyzer tells me, I'm guessing its an optimization since the hdl is pretty high level.
In any case solved the actual issue by adding a synchronizer on ir_data. Working just fine now.
FO Updated by foft over 6 years ago Actions #16
Added back the 'return to menu'
FO Updated by foft over 6 years ago Actions #17
Now trying to plumb in eclaire firmware 'properly'. e.g. settings/os load/save, video settings, 800 mode etc. Got it running as far as menus/drive emulation. Had a bit of difficulty at first because I was doing some binary editing to add version, and removing some characters from the binary by mistake!!
FO Updated by foft over 6 years ago Actions #18
Testing video mode setting (only basic stuff, rgb/vga, no pll reprogramming) and looking ok.
Tested 3rd/4th joysticks in atari800 mode. Got them working but had to change/fix a few small things.
Want to try out flash chip next...
FO Updated by foft over 6 years ago Actions #19
I have a 1MB slot. The core itself takes about 350KB compressed. So lets say we have 1/2 MB conservatively to store roms etc. The standard eclaire settings saving takes 192KB.
I guess I can also allow the rpd flashing support.
So... need to plumb in correct slot address, wire up flash pins and re-enable code in firmware (+update commands?).
FO Updated by foft over 6 years ago Actions #20
+ 3 byte header with binary length (when flashing rpd)
FO Updated by foft over 6 years ago Actions #21
I can't see which flash chip is used, guess I'll just wire it up and try reading the id!
FO Updated by foft over 6 years ago Actions #22
- File EN25QH128A(2T).pdf EN25QH128A(2T).pdf added
1c7018, which is...
EN25QH128A
datasheet attached
So, 64k blocks (erase by d8 as currently used, sector also possible)
Should just work, once I change the addresses.
FO Updated by foft over 6 years ago Actions #23
I should be passed the slot by the microcontroller, but since I'm using sof at the moment that clearly isn't working. The firmware is currently hardcoded to 0x200000. Which is slot 2 (but wrong half of it!). Will just give that a spin to test.
FO Updated by foft over 6 years ago Actions #24
OK, that works
FO Updated by foft over 6 years ago Actions #25
Picked up the slot from the micro. Computed the location of the rom. I added 256kb of blank space first to aligned to a block (this board has 64kb but some might be 256kb...). Now loading and saving is working well.
Docs on the chameleon structure of the rom are here:
https://svn.icomp.de/svn/chaco/doc/Chameleon_USB.pdf
Its a bit misleading on the core info location, since it says it starts at 3+N, while really 3+N is the end+1 of coreinfo. It describes it right after though but I didn't read that well!
So now its running pretty well. I'd like to get hotkeys working and I took a shortcut on eclaire and used the usb ones directly. So I need to plumb the ps2 keys into that logic. After which I think its 'ready'.
FO Updated by foft over 6 years ago Actions #26
Of course one more important step: try it in a C64!
FO Updated by foft over 6 years ago Actions #27
Did the keyboard plumbing. Seems to work - okish. Though can save some bytes by doing this part in vhdl I think, so might do that.
FO Updated by foft over 6 years ago Actions #28
Tried it in the c64. Keyboard works, but only sometimes! Need to work out why.
FO Updated by foft over 6 years ago Actions #29
Getting some weird behaviour tonight - cores not starting etc. Unclear what the issue is...
FO Updated by foft over 6 years ago Actions #30
Now behaving again, think Chaco had got confused and was doing weird stuff.
FO Updated by foft over 6 years ago Actions #31
Re c64 keyboard, the state machine reading it appears to get stuck and just reads DC01 repeatedly??
FO Updated by foft over 6 years ago Actions #32
Got a state capture when its working, goes through states as normal.
When it stops, no states are active!
FO Updated by foft over 6 years ago Actions #33
I wonder if ba needs a synchronizer or something like that?
FO Updated by foft over 6 years ago Actions #34
Well added a synchronizer on ba and also added a when others clause to put it back into a proper state.
Should probably discuss with Peter to see if there is a better fix.
FO Updated by foft over 6 years ago Actions #35
- Status changed from New to Closed
Chameleon 2 is working pretty well.
Moving onto Chameleon 1 backport then will check all other cores work...