From b5272205450caf135c74ceeff05f9f1dc9dc9782 Mon Sep 17 00:00:00 2001 From: Ryan <> Date: Tue, 30 Sep 2025 02:43:13 -0500 Subject: [PATCH] Swap file endianness to little for simulated flash --- libraries/simulated/dev_js28f128j3d75.vhd | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/libraries/simulated/dev_js28f128j3d75.vhd b/libraries/simulated/dev_js28f128j3d75.vhd index 5a0beb3..7296768 100644 --- a/libraries/simulated/dev_js28f128j3d75.vhd +++ b/libraries/simulated/dev_js28f128j3d75.vhd @@ -247,8 +247,8 @@ begin process (a, sts_ready) begin -- sts_ready is in the sensitivity list because flash_array is a variable and cannot be - array_word <= sparse_get(flash_array, to_integer(unsigned(a(a'high downto 1) & '0'))) & - sparse_get(flash_array, to_integer(unsigned(a(a'high downto 1) & '1'))) after T_OH; + array_word <= sparse_get(flash_array, to_integer(unsigned(a(a'high downto 1) & '1'))) & + sparse_get(flash_array, to_integer(unsigned(a(a'high downto 1) & '0'))) after T_OH; end process; @@ -571,8 +571,8 @@ begin if byte_n = '0' then sparse_set(flash_array, to_integer(unsigned(prog_addr)), prog_word(7 downto 0)); else - sparse_set(flash_array, to_integer(unsigned(prog_addr(prog_addr'high downto 1) & '0')), prog_word(15 downto 8)); - sparse_set(flash_array, to_integer(unsigned(prog_addr(prog_addr'high downto 1) & '1')), prog_word( 7 downto 0)); + sparse_set(flash_array, to_integer(unsigned(prog_addr(prog_addr'high downto 1) & '1')), prog_word(15 downto 8)); + sparse_set(flash_array, to_integer(unsigned(prog_addr(prog_addr'high downto 1) & '0')), prog_word( 7 downto 0)); end if; wsm_state_cur <= W_IDLE; -- 2.43.0