Skip to content

Commit

Permalink
Plugin_003 : removed not needed radio change mode
Browse files Browse the repository at this point in the history
  • Loading branch information
cpainchaud committed Feb 13, 2023
1 parent c561f26 commit c8954c5
Showing 1 changed file with 3 additions and 18 deletions.
21 changes: 3 additions & 18 deletions RFLink/Plugins/Plugin_003.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -710,8 +710,9 @@ boolean PluginTX_003(byte function, const char *string)
// ==========================================================================
if (strncasecmp(InputBuffer_Serial + 3, "AB400D;", 7) == 0)
{ // KAKU Command eg. Kaku;A1;On
if (InputBuffer_Serial[16] != ';')
return false;
if (InputBuffer_Serial[16] != ';') {
return false;
}
x = 17; // character pointer
InputBuffer_Serial[12] = 0x30;
InputBuffer_Serial[13] = 0x78; // Get home from hexadecimal value
Expand Down Expand Up @@ -923,9 +924,6 @@ void Arc_Send(unsigned long bitstream)
uint32_t fdatamask = 0x00000001;
uint32_t fsendbuff;

noInterrupts();
Radio::set_Radio_mode(Radio::States::Radio_TX);

for (int nRepeat = 0; nRepeat <= fretrans; nRepeat++)
{
fsendbuff = bitstream;
Expand Down Expand Up @@ -967,9 +965,6 @@ void Arc_Send(unsigned long bitstream)
digitalWrite(Radio::pins::TX_DATA, LOW); // and lower the signal
delayMicroseconds(fpulse * 31);
}

Radio::set_Radio_mode(Radio::States::Radio_RX);
interrupts();
}

void NArc_Send(unsigned long bitstream)
Expand All @@ -980,9 +975,6 @@ void NArc_Send(unsigned long bitstream)
uint32_t fdatamask = 0x00000001;
uint32_t fsendbuff;

noInterrupts();
Radio::set_Radio_mode(Radio::States::Radio_TX);

for (int nRepeat = 0; nRepeat <= fretrans; nRepeat++)
{
fsendbuff = bitstream;
Expand Down Expand Up @@ -1025,8 +1017,6 @@ void NArc_Send(unsigned long bitstream)
delayMicroseconds(fpulse * 31);
}

Radio::set_Radio_mode(Radio::States::Radio_RX);
interrupts();
}

void TriState_Send(unsigned long bitstream)
Expand All @@ -1037,9 +1027,6 @@ void TriState_Send(unsigned long bitstream)
uint32_t fdatamask = 0x00000003;
uint32_t fsendbuff;

noInterrupts();
Radio::set_Radio_mode(Radio::States::Radio_TX);

// reverse data bits (2 by 2)
for (unsigned short i = 0; i < 12; i++)
{ // reverse data bits (12 times 2 bits = 24 bits in total)
Expand Down Expand Up @@ -1100,7 +1087,5 @@ void TriState_Send(unsigned long bitstream)
delayMicroseconds(fpulse * 31);
}

Radio::set_Radio_mode(Radio::States::Radio_RX);
interrupts();
}
#endif //PLUGIN_TX_003

0 comments on commit c8954c5

Please sign in to comment.