Remove support for no busy pin set

This commit is contained in:
jacob.eva 2024-05-21 17:15:21 +01:00
parent 055083ffba
commit ebdec7f3e0
No known key found for this signature in database
GPG Key ID: 0B92E083BBCCAA1E
4 changed files with 15 additions and 18 deletions

View File

@ -202,7 +202,6 @@ void sx126x::loraMode() {
void sx126x::waitOnBusy() {
unsigned long time = millis();
if (_busy != -1) {
while (digitalRead(_busy) == HIGH)
{
if (millis() >= (time + 100)) {
@ -210,7 +209,6 @@ void sx126x::waitOnBusy() {
}
// do nothing
}
}
}
void sx126x::executeOpcode(uint8_t opcode, uint8_t *buffer, uint8_t size)

View File

@ -9,14 +9,14 @@
#include <Arduino.h>
#include <SPI.h>
#include "Modem.h"
#include "Interfaces.h"
#define LORA_DEFAULT_SS_PIN 10
#define LORA_DEFAULT_RESET_PIN 9
#define LORA_DEFAULT_DIO0_PIN 2
#define LORA_DEFAULT_RXEN_PIN -1
#define LORA_DEFAULT_TXEN_PIN -1
#define LORA_DEFAULT_BUSY_PIN -1
#define LORA_DEFAULT_BUSY_PIN 11
#define PA_OUTPUT_RFO_PIN 0
#define PA_OUTPUT_PA_BOOST_PIN 1
@ -139,6 +139,7 @@ private:
uint8_t _packet[255];
bool _preinit_done;
void (*_onReceive)(int);
bool _tcxo;
};
extern sx126x sx126x_modem;

View File

@ -206,7 +206,6 @@ void sx128x::loraMode() {
void sx128x::waitOnBusy() {
unsigned long time = millis();
if (_busy != -1) {
while (digitalRead(_busy) == HIGH)
{
if (millis() >= (time + 100)) {
@ -214,7 +213,6 @@ void sx128x::waitOnBusy() {
}
// do nothing
}
}
}
void sx128x::executeOpcode(uint8_t opcode, uint8_t *buffer, uint8_t size)

View File

@ -9,14 +9,14 @@
#include <Arduino.h>
#include <SPI.h>
#include "Modem.h"
#include "Interfaces.h"
#define LORA_DEFAULT_SS_PIN 10
#define LORA_DEFAULT_RESET_PIN 9
#define LORA_DEFAULT_DIO0_PIN 2
#define LORA_DEFAULT_RXEN_PIN -1
#define LORA_DEFAULT_TXEN_PIN -1
#define LORA_DEFAULT_BUSY_PIN -1
#define LORA_DEFAULT_BUSY_PIN 11
#define PA_OUTPUT_RFO_PIN 0
#define PA_OUTPUT_PA_BOOST_PIN 1