diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/common/includes/GPIO/pio.h | 5 | ||||
-rw-r--r-- | src/glutt-o-logique/pio.c | 8 | ||||
-rw-r--r-- | src/simulator/src/GPIO/pio.c | 4 | ||||
-rw-r--r-- | src/simulator/src/Gui/gui.c | 10 |
4 files changed, 11 insertions, 16 deletions
diff --git a/src/common/includes/GPIO/pio.h b/src/common/includes/GPIO/pio.h index 6f047f9..a9a506d 100644 --- a/src/common/includes/GPIO/pio.h +++ b/src/common/includes/GPIO/pio.h @@ -29,16 +29,11 @@ #include <stdint.h> #include "Core/fsm.h" -/* Analog inputs */ -// TODO: SWR forward power -// TODO: SWR reflected power - void pio_init(void); void pio_set_tx(int on); void pio_set_mod_off(int mod_off); void pio_set_qrp(int on); - void pio_set_gps_epps(int on); void pio_set_fsm_signals(struct fsm_input_signals_t* sig); diff --git a/src/glutt-o-logique/pio.c b/src/glutt-o-logique/pio.c index 003b50b..7220b80 100644 --- a/src/glutt-o-logique/pio.c +++ b/src/glutt-o-logique/pio.c @@ -1,7 +1,7 @@ /* * The MIT License (MIT) * - * Copyright (c) 2015 Matthias P. Braendli + * Copyright (c) 2016 Matthias P. Braendli * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal @@ -36,7 +36,7 @@ #define GPIO_PIN_U GPIO_Pin_8 #define GPIO_PIN_QRP_out GPIO_Pin_9 #define GPIO_PIN_D GPIO_Pin_11 -#define GPIO_PIN_REPLIE_n GPIO_Pin_13 +#define GPIO_PIN_REPLIE GPIO_Pin_13 #define GPIO_PIN_FAX GPIO_Pin_14 #define GPIO_PIN_GPS_EPPS GPIO_Pin_15 @@ -57,7 +57,7 @@ GPIO_PIN_SQ_n | \ GPIO_PIN_U | \ GPIO_PIN_D | \ - GPIO_PIN_REPLIE_n | \ + GPIO_PIN_REPLIE | \ GPIO_PIN_FAX | \ 0 ) @@ -146,7 +146,7 @@ void read_fsm_input_task(void __attribute__ ((unused))*pvParameters) GPIO_ReadInputDataBit(GPIOC, GPIO_PIN_D) ? 1 : 0; pio_signals.wind_generator_ok = - GPIO_ReadInputDataBit(GPIOC, GPIO_PIN_REPLIE_n) ? 1 : 0; + GPIO_ReadInputDataBit(GPIOC, GPIO_PIN_REPLIE) ? 0 : 1; pio_signals.sstv_mode = GPIO_ReadInputDataBit(GPIOC, GPIO_PIN_FAX) ? 1 : 0; diff --git a/src/simulator/src/GPIO/pio.c b/src/simulator/src/GPIO/pio.c index 4aa013b..a8622c2 100644 --- a/src/simulator/src/GPIO/pio.c +++ b/src/simulator/src/GPIO/pio.c @@ -35,7 +35,7 @@ extern int gui_in_1750_n; extern int gui_in_sq_n; extern int gui_in_u; extern int gui_in_d; -extern int gui_in_replie_n; +extern int gui_in_replie; extern int gui_in_fax_n; extern char led_gps; @@ -65,7 +65,7 @@ void pio_set_fsm_signals(struct fsm_input_signals_t* sig) { sig->sq = gui_in_sq_n ? 0 : 1; sig->discrim_u = gui_in_u ? 1 : 0; sig->discrim_d = gui_in_d ? 1 : 0; - sig->wind_generator_ok = gui_in_replie_n ? 1 : 0; + sig->wind_generator_ok = gui_in_replie ? 0 : 1; sig->sstv_mode = gui_in_fax_n ? 0 : 1; } diff --git a/src/simulator/src/Gui/gui.c b/src/simulator/src/Gui/gui.c index 457248f..2e5c3f0 100644 --- a/src/simulator/src/Gui/gui.c +++ b/src/simulator/src/Gui/gui.c @@ -152,8 +152,8 @@ int gui_in_1750_n = 1; int gui_in_sq_n = 1; int gui_in_u = 0; int gui_in_d = 0; -int gui_in_replie_n = 1; -static const char *replie_status[] = {"RepliƩ", "In vent"}; +int gui_in_replie = 0; +static const char *replie_status[] = {"In vent", "RepliƩ"}; int gui_in_fax_n = 1; int in_button = 0; @@ -830,15 +830,15 @@ void main_gui() { gui_in_fax_n = in_fax_n; } - if (gui_in_replie_n) { + if (gui_in_replie) { c = color_on; } else { c = color_off; } nk_layout_row_dynamic(ctx, 18, 2); - nk_label_colored(ctx, "REPLIE_n", NK_TEXT_LEFT, c); - gui_in_replie_n = nk_combo(ctx, replie_status, LEN(replie_status), gui_in_replie_n, 30); + nk_label_colored(ctx, "REPLIE", NK_TEXT_LEFT, c); + gui_in_replie = nk_combo(ctx, replie_status, LEN(replie_status), gui_in_replie, 30); nk_label_colored(ctx, "Voltage", NK_TEXT_LEFT, c); nk_property_float(ctx, "V", 0.0f, &gui_measured_voltage, 24.0f, 0.5f, 0.5f); |