Merge branch 'externalAmp' into master

This commit is contained in:
Jm Casler 2020-11-16 19:54:06 -08:00 committed by GitHub
commit a02979d564
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 18 additions and 0 deletions

View File

@ -162,6 +162,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
// This string must exactly match the case used in release file names or the android updater won't work
#define HW_VENDOR "tbeam"
// Jm's TXRX Deduplexer
#define RADIO_TXRX 2
// #define BUTTON_NEED_PULLUP // if set we need to turn on the internal CPU pullup during sleep
#define I2C_SDA 21

View File

@ -245,6 +245,16 @@ void setup()
SEGGER_RTT_ConfigUpBuffer(SEGGER_STDOUT_CH, NULL, NULL, 1024, SEGGER_RTT_MODE_NO_BLOCK_TRIM);
#endif
// Jm's TXRX Deduplexer
// if 0 - receive
// 1 - transmit
pinMode(RADIO_TXRX, OUTPUT);
digitalWrite(RADIO_TXRX, 0);
#ifdef USE_SEGGER
SEGGER_RTT_ConfigUpBuffer(0, NULL, NULL, 0, SEGGER_RTT_MODE_NO_BLOCK_TRIM);
#endif
// Debug
#ifdef DEBUG_PORT
DEBUG_PORT.init(); // Set serial baud rate and init our mesh console

View File

@ -197,6 +197,8 @@ void RadioLibInterface::completeSending()
txGood++;
printPacket("Completed sending", p);
digitalWrite(RADIO_TXRX, 0);
// We are done sending that packet, release it
packetPool.release(p);
// DEBUG_MSG("Done with send\n");
@ -258,6 +260,8 @@ void RadioLibInterface::handleReceiveInterrupt()
/** start an immediate transmit */
void RadioLibInterface::startSend(MeshPacket *txp)
{
digitalWrite(RADIO_TXRX, 1);
printPacket("Starting low level send", txp);
setStandby(); // Cancel any already in process receives