From 5e0b3c129cbef1f980be2f41c692311cb58357c8 Mon Sep 17 00:00:00 2001 From: Richard Li Date: Thu, 8 Aug 2024 16:28:37 +0800 Subject: [PATCH] Updated naming of switches and pots according to what is printed in the radio --- radio/src/targets/pl18/switch_driver.cpp | 8 ++++---- radio/util/hw_defs/legacy_names.py | 4 ++-- radio/util/hw_defs/switch_config.py | 4 ++-- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/radio/src/targets/pl18/switch_driver.cpp b/radio/src/targets/pl18/switch_driver.cpp index 24624469d..77f62ab70 100644 --- a/radio/src/targets/pl18/switch_driver.cpp +++ b/radio/src/targets/pl18/switch_driver.cpp @@ -34,25 +34,25 @@ static const stm32_switch_t _switch_defs[] = { /* { - "S1A", + "SW1L", nullptr, 0, nullptr, 0, SWITCH_HW_2POS, 0 }, { - "S1B", + "SW1R", nullptr, 0, nullptr, 0, SWITCH_HW_2POS, 0 },*/ { - "S2", + "SW2", nullptr, 0, nullptr, 0, SWITCH_HW_2POS, 0 }, { - "S3", + "SW3", nullptr, 0, nullptr, 0, SWITCH_HW_2POS, 0 diff --git a/radio/util/hw_defs/legacy_names.py b/radio/util/hw_defs/legacy_names.py index 68e0cc84d..ebb4598ad 100644 --- a/radio/util/hw_defs/legacy_names.py +++ b/radio/util/hw_defs/legacy_names.py @@ -697,14 +697,14 @@ LEGACY_NAMES = [ "P1": { "yaml": "POT1", "lua": "s1", - "label": "S1", + "label": "VR1L", "short_label": "1", "description": "Potentiometer 1" }, "P2": { "yaml": "POT2", "lua": "s2", - "label": "S2", + "label": "VR1R", "short_label": "2", "description": "Potentiometer 2" }, diff --git a/radio/util/hw_defs/switch_config.py b/radio/util/hw_defs/switch_config.py index 866e1fad7..424e0f421 100644 --- a/radio/util/hw_defs/switch_config.py +++ b/radio/util/hw_defs/switch_config.py @@ -66,8 +66,8 @@ SWITCH_CONFIG = { "SJ": { "default": "3POS" } }, "nb4p": { - "S2" : { "default": "TOGGLE" }, - "S3" : { "default": "TOGGLE" } + "SW2" : { "default": "TOGGLE" }, + "SW3" : { "default": "TOGGLE" } }, "lr3pro": { # left side