Optimized RF24Network Layer v2.0.1
2024 - Optimized RF24 Network Layer for NRF24L01 & NRF52x radios
Loading...
Searching...
No Matches
Macros
RF24Network_config.h File Reference

Go to the source code of this file.

Macros

#define NETWORK_DEFAULT_ADDRESS   04444
 A reserved valid address for use with RF24Mesh (when a mesh node requests an assigned address)
 
#define NETWORK_MULTICAST_ADDRESS   0100
 A sentinel address value for multicasting purposes.
 
#define NETWORK_AUTO_ROUTING   070
 A sentinel value for internally indicating that the frame should be automatically routed as necessary.
 
#define SLOW_ADDR_POLL_RESPONSE   10
 Adds a delay to node prior to transmitting NETWORK_ADDR_RESPONSE messages.
 
#define RF24NetworkMulticast
 When defined, this will allow the use of multicasting messages.
 
#define MAX_PAYLOAD_SIZE   144
 Maximum size of fragmented network frames and fragmentation cache.
 
#define MAIN_BUFFER_SIZE   (MAX_PAYLOAD_SIZE + FRAME_HEADER_SIZE)
 The allocated size of the incoming frame buffer.
 
#define ENABLE_DYNAMIC_PAYLOADS
 
#define NUM_PIPES   6
 

Macro Definition Documentation

◆ NETWORK_DEFAULT_ADDRESS

#define NETWORK_DEFAULT_ADDRESS   04444

A reserved valid address for use with RF24Mesh (when a mesh node requests an assigned address)

◆ NETWORK_MULTICAST_ADDRESS

#define NETWORK_MULTICAST_ADDRESS   0100

A sentinel address value for multicasting purposes.

◆ NETWORK_AUTO_ROUTING

#define NETWORK_AUTO_ROUTING   070

A sentinel value for internally indicating that the frame should be automatically routed as necessary.

◆ SLOW_ADDR_POLL_RESPONSE

#define SLOW_ADDR_POLL_RESPONSE   10

Adds a delay to node prior to transmitting NETWORK_ADDR_RESPONSE messages.

By default this is undefined for speed. This defined number of milliseconds is only applied to the master node when replying to a child trying to connect to the mesh network.

Note
It is advised to define this if any child node is running CircuitPython because the execution speed in pure python is inherently slower than it is in C++.

◆ RF24NetworkMulticast

#define RF24NetworkMulticast

When defined, this will allow the use of multicasting messages.

◆ MAX_PAYLOAD_SIZE

#define MAX_PAYLOAD_SIZE   144

Maximum size of fragmented network frames and fragmentation cache.

Note
This buffer can now be any size > 24. Previously this needed to be a multiple of 24 (changed in v1.0.15).
If used with RF24Ethernet, this value is used to set the buffer sizes.
For nodes driven by an ATTiny based chip, this is set to 72. However, defining DISABLE_FRAGMENTION truncates the actual transmitted payload to 24 bytes (which is also the default behavior on ATTiny devices).
Examples
helloworld_rx_advanced.ino, and helloworld_tx_advanced.ino.

◆ MAIN_BUFFER_SIZE

#define MAIN_BUFFER_SIZE   (MAX_PAYLOAD_SIZE + FRAME_HEADER_SIZE)

The allocated size of the incoming frame buffer.

This is the user-cache, where incoming data is stored. Data is stored using Frames: Header (8 bytes) + Message_Size (2 bytes) + Message_Data (? bytes)

Note
Over-The-Air (OTA) transmissions don't include the message size in the transmitted packet.

◆ ENABLE_DYNAMIC_PAYLOADS

#define ENABLE_DYNAMIC_PAYLOADS

Enable dynamic payloads - If using different types of nRF24L01 modules, some may be incompatible when using this feature

◆ NUM_PIPES

#define NUM_PIPES   6

The number of 'pipes' available for addressing in the current device Networks with NRF24L01 devices only have 6 pipes NRF52x networks support up to 8 pipes