stretch input further

This commit is contained in:
Alwin Berger 2025-05-21 16:36:46 +00:00
parent 34987ecb95
commit 0f1293a9f4

View File

@ -22,7 +22,7 @@
// Supervisor task
#define HYPER_PERIOD 100
#define SIMULATE_PERIODS 2
#define SIMULATE_PERIODS 1
static TickType_t initial_release_time = 0;
static TaskHandle_t xTaskTimeSupervisor = NULL;
static void timing_supervisor_task( void * pvParameters ) {
@ -252,7 +252,7 @@ static void task_0_fn(void *pvParameters) {
chaininp = (INPUT_CHAR_NEXT);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_5(tmp);
tmp = TRANSLATE_5(tmp, ((int)7632.0), 76320);
tmp = WC_SWITCH(tmp, 76320);
@ -283,7 +283,7 @@ static void task_1_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c17 << 4 | input_c30);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_10(tmp);
tmp = TRANSLATE_10(tmp, ((int)180482.0), 1804820);
tmp = WC_SWITCH(tmp, 1804820);
@ -316,7 +316,7 @@ static void task_2_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c22 << 4 | input_c28);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_5(tmp);
tmp = TRANSLATE_5(tmp, ((int)52546.4), 525464);
tmp = WC_SWITCH(tmp, 525464);
@ -343,7 +343,7 @@ static void task_3_fn(void *pvParameters) {
chaininp = (INPUT_CHAR_NEXT);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_9(tmp);
tmp = TRANSLATE_9(tmp, ((int)61613.7), 616137);
tmp = WC_SWITCH(tmp, 616137);
@ -376,7 +376,7 @@ static void task_4_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c13 << 4 | input_c19);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_9(tmp);
tmp = TRANSLATE_9(tmp, ((int)29219.2), 292192);
tmp = WC_SWITCH(tmp, 292192);
@ -409,7 +409,7 @@ static void task_5_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c2 << 4 | input_c30);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_1(tmp);
tmp = TRANSLATE_1(tmp, ((int)79674.9), 796749);
tmp = WC_SWITCH(tmp, 796749);
@ -441,7 +441,7 @@ static void task_6_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c13 << 4 | 0xFF);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_5(tmp);
tmp = TRANSLATE_5(tmp, ((int)10619.7), 106197);
tmp = WC_SWITCH(tmp, 106197);
@ -480,7 +480,7 @@ static void task_7_fn(void *pvParameters) {
chaininp = (uint8_t)(cond_44 | cond_30<<1 | cond_28<<2 | cond_17<<3 | cond_28<<4 | cond_44<<5 | cond_44<<6 | cond_17<<7);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_6(tmp);
tmp = TRANSLATE_6(tmp, ((int)56231.7), 562317);
tmp = WC_SWITCH(tmp, 562317);
@ -517,7 +517,7 @@ static void task_8_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c13 << 4 | input_c23);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_2(tmp);
tmp = TRANSLATE_2(tmp, ((int)5771.0), 57710);
tmp = WC_SWITCH(tmp, 57710);
@ -557,7 +557,7 @@ static void task_9_fn(void *pvParameters) {
chaininp = (uint8_t)(cond_19 | cond_13<<1 | cond_44<<2 | cond_41<<3 | cond_30<<4 | cond_44<<5 | cond_44<<6 | cond_13<<7);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_9(tmp);
tmp = TRANSLATE_9(tmp, ((int)22409.1), 224091);
tmp = WC_SWITCH(tmp, 224091);
@ -597,7 +597,7 @@ static void task_10_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c1 << 4 | input_c13);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_10(tmp);
tmp = TRANSLATE_10(tmp, ((int)12126.3), 121263);
tmp = WC_SWITCH(tmp, 121263);
@ -632,7 +632,7 @@ static void task_11_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c34 << 4 | input_c36);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_3(tmp);
tmp = TRANSLATE_3(tmp, ((int)43715.0), 437150);
tmp = WC_SWITCH(tmp, 437150);
@ -668,7 +668,7 @@ static void task_12_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c7 << 4 | input_c8);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_6(tmp);
tmp = TRANSLATE_6(tmp, ((int)37534.5), 375345);
tmp = WC_SWITCH(tmp, 375345);
@ -702,7 +702,7 @@ static void task_13_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c6 << 4 | input_c7);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_2(tmp);
tmp = TRANSLATE_2(tmp, ((int)4132.9), 41329);
tmp = WC_SWITCH(tmp, 41329);
@ -735,7 +735,7 @@ static void task_14_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c24 << 4 | input_c36);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_6(tmp);
tmp = TRANSLATE_6(tmp, ((int)33574.8), 335748);
tmp = WC_SWITCH(tmp, 335748);
@ -767,7 +767,7 @@ static void task_15_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c36 << 4 | 0xFF);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_2(tmp);
tmp = TRANSLATE_2(tmp, ((int)118933.0), 1189330);
tmp = WC_SWITCH(tmp, 1189330);
@ -794,7 +794,7 @@ static void task_16_fn(void *pvParameters) {
chaininp = (INPUT_CHAR_NEXT);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_2(tmp);
tmp = TRANSLATE_2(tmp, ((int)85798.0), 857980);
tmp = WC_SWITCH(tmp, 857980);
@ -826,7 +826,7 @@ static void task_17_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c5 << 4 | input_c7);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_5(tmp);
tmp = TRANSLATE_5(tmp, ((int)181050.2), 1810502);
tmp = WC_SWITCH(tmp, 1810502);
@ -866,7 +866,7 @@ static void task_18_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c5 << 4 | input_c7);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_4(tmp);
tmp = TRANSLATE_4(tmp, ((int)45921.5), 459215);
tmp = WC_SWITCH(tmp, 459215);
@ -900,7 +900,7 @@ static void task_19_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c8 << 4 | input_c34);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_7(tmp);
tmp = TRANSLATE_7(tmp, ((int)12037.4), 120374);
tmp = WC_SWITCH(tmp, 120374);
@ -943,7 +943,7 @@ static void task_20_fn(void *pvParameters) {
chaininp = (uint8_t)(cond_8 | cond_16<<1 | cond_42<<2 | cond_15<<3 | cond_15<<4 | cond_42<<5 | cond_8<<6 | cond_16<<7);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_4(tmp);
tmp = TRANSLATE_4(tmp, ((int)2467.5), 24675);
tmp = WC_SWITCH(tmp, 24675);
@ -991,7 +991,7 @@ static void task_21_fn(void *pvParameters) {
chaininp = (uint8_t)(cond_8 | cond_19<<1 | cond_50<<2 | cond_25<<3 | cond_15<<4 | cond_50<<5 | cond_50<<6 | cond_50<<7);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_8(tmp);
tmp = TRANSLATE_8(tmp, ((int)5124.1), 51241);
tmp = WC_SWITCH(tmp, 51241);
@ -1051,7 +1051,7 @@ static void task_22_fn(void *pvParameters) {
chaininp = (uint8_t)(cond_3 | cond_13<<1 | cond_42<<2 | cond_25<<3 | cond_19<<4 | cond_43<<5 | cond_16<<6 | cond_19<<7);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_8(tmp);
tmp = TRANSLATE_8(tmp, ((int)21865.9), 218659);
tmp = WC_SWITCH(tmp, 218659);
@ -1089,7 +1089,7 @@ static void task_23_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c42 << 4 | 0xFF);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_9(tmp);
tmp = TRANSLATE_9(tmp, ((int)55368.2), 553682);
tmp = WC_SWITCH(tmp, 553682);
@ -1125,7 +1125,7 @@ static void task_24_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c21 << 4 | input_c26);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_9(tmp);
tmp = TRANSLATE_9(tmp, ((int)423.9), 4239);
tmp = WC_SWITCH(tmp, 4239);
@ -1157,7 +1157,7 @@ static void task_25_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c19 << 4 | 0xFF);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_3(tmp);
tmp = TRANSLATE_3(tmp, ((int)4884.6), 48846);
tmp = WC_SWITCH(tmp, 48846);
@ -1193,7 +1193,7 @@ static void task_26_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c19 << 4 | input_c21);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_9(tmp);
tmp = TRANSLATE_9(tmp, ((int)35951.2), 359512);
tmp = WC_SWITCH(tmp, 359512);
@ -1233,7 +1233,7 @@ static void task_27_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c13 << 4 | input_c23);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_9(tmp);
tmp = TRANSLATE_9(tmp, ((int)97043.5), 970435);
tmp = WC_SWITCH(tmp, 970435);
@ -1274,7 +1274,7 @@ static void task_28_fn(void *pvParameters) {
chaininp = (uint8_t)(cond_13 | cond_29<<1 | cond_26<<2 | cond_12<<3 | cond_29<<4 | cond_29<<5 | cond_12<<6 | cond_29<<7);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_8(tmp);
tmp = TRANSLATE_8(tmp, ((int)33427.1), 334271);
tmp = WC_SWITCH(tmp, 334271);
@ -1310,7 +1310,7 @@ static void task_29_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c12 << 4 | input_c19);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_6(tmp);
tmp = TRANSLATE_6(tmp, ((int)35262.6), 352626);
tmp = WC_SWITCH(tmp, 352626);
@ -1345,7 +1345,7 @@ static void task_30_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c19 << 4 | input_c39);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_6(tmp);
tmp = TRANSLATE_6(tmp, ((int)7860.9), 78609);
tmp = WC_SWITCH(tmp, 78609);
@ -1378,7 +1378,7 @@ static void task_31_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c21 << 4 | input_c47);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_9(tmp);
tmp = TRANSLATE_9(tmp, ((int)72668.5), 726685);
tmp = WC_SWITCH(tmp, 726685);
@ -1401,7 +1401,7 @@ static void task_32_fn(void *pvParameters) {
chaininp = (INPUT_CHAR_NEXT);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_5(tmp);
tmp = TRANSLATE_5(tmp, ((int)96338.4), 963384);
tmp = WC_SWITCH(tmp, 963384);
@ -1429,7 +1429,7 @@ static void task_33_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c26 << 4 | 0xFF);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_2(tmp);
tmp = TRANSLATE_2(tmp, ((int)58608.4), 586084);
tmp = WC_SWITCH(tmp, 586084);
@ -1455,7 +1455,7 @@ static void task_34_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c26 << 4 | 0xFF);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_1(tmp);
tmp = TRANSLATE_1(tmp, ((int)36444.1), 364441);
tmp = WC_SWITCH(tmp, 364441);
@ -1487,7 +1487,7 @@ static void task_35_fn(void *pvParameters) {
chaininp = (uint8_t)(input_c23 << 4 | 0xFF);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_9(tmp);
tmp = TRANSLATE_9(tmp, ((int)51214.0), 512140);
tmp = WC_SWITCH(tmp, 512140);
@ -1522,7 +1522,7 @@ static void task_36_fn(void *pvParameters) {
chaininp = (uint8_t)(cond_29 | cond_46<<1 | cond_23<<2 | cond_42<<3 | cond_42<<4 | cond_29<<5 | cond_46<<6 | cond_29<<7);
byteinp = INPUT_SHORT_NEXT;
tmp = STRETCH_i32(chaininp) + byteinp;
tmp = STRETCH_i32(chaininp) + STRETCH_i32(byteinp);
tmp = FUNCTION_8(tmp);
tmp = TRANSLATE_8(tmp, ((int)75425.6), 754256);
tmp = WC_SWITCH(tmp, 754256);