Maniacbug- Network Layer for RF24L01+ Radios

fca:
Hi i opened a new topic because these will be focused on the Network Layer for RF24 Radios ...

This library
http://maniacbug.github.com/RF24Network/index.html

Oh no! The network layer leaks out :open_mouth: I've intentionally not publicized RF24Network because I'm not totally sure it's ready for prime-time yet. That said, I have gobs o' nodes using it and it works great. Just be warned you're the first person other than me who has tried to put it to use, at least that I know of.

fca:

This means if i need a node as relay i will put all the nodes that can't reach the base as child of the node that reach the base ??

So with this there is no formal declaration of the leaf, relay, or base ?

You got it. If a node cannot reach base, but can reach node 01, then make it node 011. Or 021. Or 031, etc. "Relay" is purely a semantic notion as far as the library is concerned. It just means "A node that has both children and a parent."

EDIT: Just realized a problem with your diagram. "Node 012" in your diagram should be "Node 021". Node 021 is a child of Node 01, while Node 012 is a child of Node 02.

fca:
i will always put on the network.write the final destination the network layer will find the way trough all the child's, correct ?

Yup, that's the whole point. 'Write' to the node where you want the message ultimately delivered. The network will handle getting it there.

 RF24NetworkHeader header(/*to node*/ other_node);

bool ok = network.write(header,hello,strlen(hello));



my header will always be the final destination, in this example the node 011 will always have the destination of the base and not the parent, correct ?

How to enable the serial debug i'm doing this

"#define SERIAL_DEBUG"
but still not all the debug is enabled i see in "RF24Network_config.h" this..

Right, you need to change the "#undef SERIAL_DEBUG" to "#define SERIAL_DEBUG" in RF24Network_config.h. I've found the serial debug output to be absolutely critical in understanding what's going on. I just added a pile of unit tests, and absolutely would not have gotten it working without poring over the serial debug logs.

One thing to be careful of to not starve the network. RF24Network::update() needs to get called all the time, so don't block anywhere in delay() loops. Also, remember that the unit cannot both send and receive at the same time. So it's wise to chill for a little bit after every send.

fca:
Maniacbug Thanks again for your great work

Hey, yer welcome. Good luck with your project! It will not shock me if you run into bugs. You can go ahead and report them as issues on github.