version 1.1

This commit is contained in:
cally22
2023-07-09 20:04:44 +02:00
parent c55b7fc4ed
commit 2547e14592
7 changed files with 42 additions and 40 deletions
+2 -12
View File
@@ -8,27 +8,17 @@ void RadioController::setup(int cepin, int cspin) {
Serial.println("Error initializing radio");
} else {
Serial.println("Succesfully initializing radio");
// radio.openWritingPipe(writePipe);
// radio.openReadingPipe(1, readPipe);
// radio.setPALevel(RF24_PA_MAX);
// radio.disableDynamicPayloads();
// radio.setAutoAck(false);
// radio.setRetries(5, 15);
// radio.setDataRate( RF24_250KBPS );
// radio.openReadingPipe(1, readPipe);
// radio.enableAckPayload();
// radio.startListening();
radio.setDataRate( RF24_250KBPS );
uint8_t address[][6] = { "1Node", "2Node" };
// Set the PA Level low to try preventing power supply related problems
// because these examples are likely run with nodes in close proximity to
// each other.
radio.setPALevel(RF24_PA_LOW); // RF24_PA_MAX is default.
radio.setPALevel(RF24_PA_HIGH); // RF24_PA_MAX is default.
// to use ACK payloads, we need to enable dynamic payload lengths (for all nodes)
radio.enableDynamicPayloads(); // ACK payloads are dynamically sized