aboutsummaryrefslogtreecommitdiff
path: root/source/sdd1emu.c
diff options
context:
space:
mode:
Diffstat (limited to 'source/sdd1emu.c')
-rw-r--r--source/sdd1emu.c84
1 files changed, 42 insertions, 42 deletions
diff --git a/source/sdd1emu.c b/source/sdd1emu.c
index 5634960..fc2e809 100644
--- a/source/sdd1emu.c
+++ b/source/sdd1emu.c
@@ -36,52 +36,52 @@ static struct
uint8_t LPS_next;
} evolution_table[] =
{
- /* 0 */ { 0, 25, 25},
- /* 1 */ { 0, 2, 1},
- /* 2 */ { 0, 3, 1},
- /* 3 */ { 0, 4, 2},
- /* 4 */ { 0, 5, 3},
- /* 5 */ { 1, 6, 4},
- /* 6 */ { 1, 7, 5},
- /* 7 */ { 1, 8, 6},
- /* 8 */ { 1, 9, 7},
- /* 9 */ { 2, 10, 8},
- /* 10 */ { 2, 11, 9},
- /* 11 */ { 2, 12, 10},
- /* 12 */ { 2, 13, 11},
- /* 13 */ { 3, 14, 12},
- /* 14 */ { 3, 15, 13},
- /* 15 */ { 3, 16, 14},
- /* 16 */ { 3, 17, 15},
- /* 17 */ { 4, 18, 16},
- /* 18 */ { 4, 19, 17},
- /* 19 */ { 5, 20, 18},
- /* 20 */ { 5, 21, 19},
- /* 21 */ { 6, 22, 20},
- /* 22 */ { 6, 23, 21},
- /* 23 */ { 7, 24, 22},
- /* 24 */ { 7, 24, 23},
- /* 25 */ { 0, 26, 1},
- /* 26 */ { 1, 27, 2},
- /* 27 */ { 2, 28, 4},
- /* 28 */ { 3, 29, 8},
- /* 29 */ { 4, 30, 12},
- /* 30 */ { 5, 31, 16},
- /* 31 */ { 6, 32, 18},
- /* 32 */ { 7, 24, 22}
+ /* 0 */ { 0, 25, 25 },
+ /* 1 */ { 0, 2, 1 },
+ /* 2 */ { 0, 3, 1 },
+ /* 3 */ { 0, 4, 2 },
+ /* 4 */ { 0, 5, 3 },
+ /* 5 */ { 1, 6, 4 },
+ /* 6 */ { 1, 7, 5 },
+ /* 7 */ { 1, 8, 6 },
+ /* 8 */ { 1, 9, 7 },
+ /* 9 */ { 2, 10, 8 },
+ /* 10 */ { 2, 11, 9 },
+ /* 11 */ { 2, 12, 10 },
+ /* 12 */ { 2, 13, 11 },
+ /* 13 */ { 3, 14, 12 },
+ /* 14 */ { 3, 15, 13 },
+ /* 15 */ { 3, 16, 14 },
+ /* 16 */ { 3, 17, 15 },
+ /* 17 */ { 4, 18, 16 },
+ /* 18 */ { 4, 19, 17 },
+ /* 19 */ { 5, 20, 18 },
+ /* 20 */ { 5, 21, 19 },
+ /* 21 */ { 6, 22, 20 },
+ /* 22 */ { 6, 23, 21 },
+ /* 23 */ { 7, 24, 22 },
+ /* 24 */ { 7, 24, 23 },
+ /* 25 */ { 0, 26, 1 },
+ /* 26 */ { 1, 27, 2 },
+ /* 27 */ { 2, 28, 4 },
+ /* 28 */ { 3, 29, 8 },
+ /* 29 */ { 4, 30, 12 },
+ /* 30 */ { 5, 31, 16 },
+ /* 31 */ { 6, 32, 18 },
+ /* 32 */ { 7, 24, 22 }
};
static uint8_t run_table[128] =
{
- 128, 64, 96, 32, 112, 48, 80, 16, 120, 56, 88, 24, 104, 40, 72,
- 8, 124, 60, 92, 28, 108, 44, 76, 12, 116, 52, 84, 20, 100, 36,
- 68, 4, 126, 62, 94, 30, 110, 46, 78, 14, 118, 54, 86, 22, 102,
- 38, 70, 6, 122, 58, 90, 26, 106, 42, 74, 10, 114, 50, 82, 18,
- 98, 34, 66, 2, 127, 63, 95, 31, 111, 47, 79, 15, 119, 55, 87,
- 23, 103, 39, 71, 7, 123, 59, 91, 27, 107, 43, 75, 11, 115, 51,
- 83, 19, 99, 35, 67, 3, 125, 61, 93, 29, 109, 45, 77, 13, 117,
- 53, 85, 21, 101, 37, 69, 5, 121, 57, 89, 25, 105, 41, 73, 9,
- 113, 49, 81, 17, 97, 33, 65, 1
+ 128, 64, 96, 32, 112, 48, 80, 16, 120, 56, 88, 24, 104, 40, 72,
+ 8, 124, 60, 92, 28, 108, 44, 76, 12, 116, 52, 84, 20, 100, 36,
+ 68, 4, 126, 62, 94, 30, 110, 46, 78, 14, 118, 54, 86, 22, 102,
+ 38, 70, 6, 122, 58, 90, 26, 106, 42, 74, 10, 114, 50, 82, 18,
+ 98, 34, 66, 2, 127, 63, 95, 31, 111, 47, 79, 15, 119, 55, 87,
+ 23, 103, 39, 71, 7, 123, 59, 91, 27, 107, 43, 75, 11, 115, 51,
+ 83, 19, 99, 35, 67, 3, 125, 61, 93, 29, 109, 45, 77, 13, 117,
+ 53, 85, 21, 101, 37, 69, 5, 121, 57, 89, 25, 105, 41, 73, 9,
+ 113, 49, 81, 17, 97, 33, 65, 1
};
static inline uint8_t GetCodeword(int32_t bits)