]> git.tnoah.ca Git - lora-radio.git/commitdiff
Well that was embarassing...
authorjacob.eva <x00010@disroot.org>
Wed, 11 Sep 2024 20:49:27 +0000 (21:49 +0100)
committerjacob.eva <x00010@disroot.org>
Wed, 11 Sep 2024 20:49:27 +0000 (21:49 +0100)
Config.h
RNode_Firmware_CE.ino

index 7f4c505a546900fc07fdda0d6ebc3957a73da094..9a468782f13b1109c5209883372bbb43e2c85376 100644 (file)
--- a/Config.h
+++ b/Config.h
        bool pmu_ready     = false;
        bool promisc       = false;
        bool implicit      = false;
-    volatile bool packet_ready  = false;
        uint8_t implicit_l = 0;
 
+    volatile bool packet_ready  = false;
+    volatile uint8_t packet_interface = 0xFF;
+
        uint8_t op_mode   = MODE_HOST;
        uint8_t model     = 0x00;
        uint8_t hwrev     = 0x00;
index 2ead632a077bea70629354179fbba87dc545064a..96e084917d7ce23fb04d161f0ba480f283098e99 100644 (file)
@@ -359,6 +359,7 @@ void receive_callback(uint8_t index, int packet_size) {
       getPacketData(selected_radio, packet_size);
 
       seq = SEQ_UNSET;
+      packet_interface = index;
       packet_ready = true;
 
     } else if (isSplitPacket(header) && seq != sequence) {
@@ -384,6 +385,8 @@ void receive_callback(uint8_t index, int packet_size) {
       }
 
       getPacketData(selected_radio, packet_size);
+
+      packet_interface = index;
       packet_ready = true;
     }
   } else {
@@ -392,6 +395,8 @@ void receive_callback(uint8_t index, int packet_size) {
     read_len = 0;
 
     getPacketData(selected_radio, packet_size);
+
+    packet_interface = index;
     packet_ready = true;
   }
 
@@ -1167,7 +1172,7 @@ void loop() {
         #endif
         kiss_indicate_stat_rssi();
         kiss_indicate_stat_snr();
-        kiss_write_packet(1);
+        kiss_write_packet(packet_interface);
   }
 
     bool ready = false;