Changes

FPGAmstrad

2,327 bytes added, 25 May
/* NAMES */
== Last news about this project ==
In August 2025, I refactor the OSD menu, adding also an 3rd palette : orange.
 
In MaY 2020, I add Sorgelig formula for WAIT_n=quick, no more table of instruction time in code, just a simple WAIT_n formula.
*'''Edge_Grinder.dsk''': screen not stable horizontally, music change speed during game ? Does pass on Sorgelig fork.
*'''Welcome To Amstrad CPC 6128.dsk''': does display "Incompatible BASIC installed" message.
*'''phX.dsk''': does begin to pass on r005.8.16. Does pass completly on Sorgelig fork (scandoubler). Does finish on amstrad_180804_r005.8.16.5. Does show vertical bars with CRTC0, no display during end scroll part. Does freeze at middle on amstrad_180804_r005.8.16.6 (doesn't launch the read of disk), does pass on Sorgelig fork but song is 2 times slown down before reaching this part. Did pass one time on amstrad_200527_r005.8.16.8.5c1.rbf (CRTC0 WAIT_n:quick (Sorgelig GA simple formula)), but I was lucky. Perhaps stabilizing Moustache testbench Did pass one time on FPGAmstrad shall correct amstrad_200527_r005.8.16.8.5c2.rbf (CRTC1 WAIT_n:quick) except vertical bars of begin. Seems that bug, alignement launching Pinball Dreams CRTC1 (until menu of clocks after the Z80 boards) before (soft reset?(page up key) and) PhX CRTC0 does unlock PhX.
*'''Ghouls'n'Ghost.dsk''': does fail on r005.8.16.2 : time going to zero in 3 seconds, is fine in r005.8.15.2, fine also on Sorgelig fork... also unlocked by Sorgelig in r005.8.16.3 !
* '''Ultimate Megademo (Face Hugger).dsk''': First part is better using CRTC0. Ending part (one just after Lemmings part), a double VSYNC problem (a small scrolling text instead of... a lot of things), music OK during this ending.
In ZX-Uno FPGAmstrad, I implemented CRTC0.
CRTC1 has double sized VSYNC against CRTC0 (moustache test)
==== VGA: VRAM ====
=== bootloader ===
==== SCARD ====MISO MOSI on bootloader component is the SDCARD protocolSDRAM_SPIMASTER has a state machine : case step_cmd is when 0=> ... step_cmd:=1; when 1=> ... step_cmd:=2; when 2=> ... step_cmd:=3;It's implementing SDCARD protocol, and manage ROM+DSK in RAMmemory==== FAT32 ====SDRAM_FAT32_LOADER has also a state machine : case data_step is when 0=> ... data_step:=1; when 1=> ... data_step:=2; when 2=> ... data_step:=3;It's implementing FAT32 protocol, and manage ROM+DSK in RAM memory==== NAMES ====
(nothing to say here'''megashark''' does fight against DSK, really ???component simple_DSK does implementation, '''memshark''' is linked with megashark. '''jacquie''' does fight against CDT, component simple_CDT does implementation, '''michel''' is linked with jacquie. '''transmiter''' does fight against RAM. RAM is divided into differents part (ROM RAM DSK CDTsure SDRAM_SPIMASTER is slave of SDRAM_FAT32_LOADER, for explanation : -- megashark_do ask if SDRAM_SPIMASTER has finish, confirmation is megashark_done wire
=== GA ===
==== DSK: FAT32 fragmented files support ====
Since advanced FDC, dsk files have to be defragmented. Only ROMs are safe with a not defragemented sdcard...
 
To defrag SDCARD, I use "WinContig" from sourceforge. Select Menu>File>Add Object>Folder, then Select a disc>click "select a folder" and then "Close". Menu>Action>defrag.
ZX-Uno is using simple FDC, not impacted here.
http://www.youtube.com/watch?v=fh4v4OXridc
USB is just a state machine (welcome how are you today, show me your state, show me your state, show me your state....), encoding (have to read USB manual), you can use some usb sniffer softwares software to decode them (wireshark unix version does it fine). Sniffer software does not show low level messages (ack ko ok) but does show the high level messages (ones that show that a button is pressed or not)
As it is just encoding, you can capture signals and show that they differ only when you do unpress or press a button.
TODO : alternative color, but cool ones : yellow (green) blue orange pink.
 
===== VIDEO: Orange option =====
It is not a Monochrome, it's just another palette.
 
Before :
XX00 red
XX00 green
XX00 blue
 
After :
XX00 red
0XX0 green
00XX blue
[[File:FPGAmstrad orange.png|thumbnail|Orange screen]]
 
===== VIDEO: C64 option =====
Mapping of C64 palette on CPC (VIC 2)
 
C64 is using YUV.
 
As first step, I convert RBG into YUV, then I inverse U and V, and then convert back to RGB.
As it, I extend C64 16 colors palette into 32.
I call it first step, because I thing we can add cos/sin in equation.
 
[[File:FPGAmstrad_C64_VIC_2_palette.png|thumbnail|C64 palette doc]]
 
[[File:PaletteC64.png|thumbnail|Palette C64 generator]]
 
[[File:FPGAmstrad lair C64 palette.JPG|thumbnail|Wizards Lair C64 palette]]
 
Known C64 conversion better with this C64 palette option :
* Wizard's Lair
* R-Type
 
https://github.com/renaudhelias/CoreAmstrad/tree/master/C64_to_CPC_palette%5BEclipse_Java%5D
===== VIDEO: Monochrome OSD =====
1,218
edits