Skip to content

Commit

Permalink
add $D094 debug register #766
Browse files Browse the repository at this point in the history
  • Loading branch information
Paul Gardner-Stephen committed May 19, 2024
1 parent 2cb28fc commit d1402bd
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions src/vhdl/sdcardio.vhdl
Original file line number Diff line number Diff line change
Expand Up @@ -1371,12 +1371,18 @@ begin -- behavioural
fastio_rdata <= hw_errata_level_int;
when "11000" => -- @IO:GS $D090 - Read-ahead sector byte 0 (DEBUG)
fastio_rdata <= read_ahead_sector(7 downto 0);
when "11001" => -- @IO:GS $D090 - Read-ahead sector byte 1 (DEBUG)
when "11001" => -- @IO:GS $D091 - Read-ahead sector byte 1 (DEBUG)
fastio_rdata <= read_ahead_sector(15 downto 8);
when "11010" => -- @IO:GS $D090 - Read-ahead sector byte 2 (DEBUG)
when "11010" => -- @IO:GS $D092 - Read-ahead sector byte 2 (DEBUG)
fastio_rdata <= read_ahead_sector(23 downto 16);
when "11011" => -- @IO:GS $D090 - Read-ahead sector byte 3 (DEBUG)
fastio_rdata <= read_ahead_sector(31 downto 24);
when "11011" => -- @IO:GS $D094 - Read-ahead and cache flags (DEBUG)
fastio_rdata(7) <= reading_ahead;
fastio_rdata(6) <= cache_enabled;
fastio_rdata(5) <= to_std_logic(read_ahead_enable);
fastio_rdata(4) <= cache_has_match;
fastio_rdata(3) <= read_during_read_ahead;
fastio_rdata(2 downto 0) <= to_unsigned(read_ahead_count,3);
when "11100" => -- @IO:GS $D094 - Read-ahead sector byte 3 (DEBUG)
when "11011" => -- @IO:GS $D09B - FSM state of low-level SD controller (DEBUG)
fastio_rdata <= last_sd_state;
when "11100" => -- @IO:GS $D09C - Last byte low-level SD controller read from card (DEBUG)
Expand Down

0 comments on commit d1402bd

Please sign in to comment.