![](/media/cache/img/default_profile.jpg.50x50_q85.jpg)
RF24Network Send example program. Tested on Nucleo-F411.
Dependencies: RF24 RF24Network mbed
Revision 3:d605536db315, committed 2015-11-05
- Comitter:
- akashvibhute
- Date:
- Thu Nov 05 05:59:18 2015 +0000
- Parent:
- 2:926b93a68399
- Commit message:
- updated with new rf24 library Nov/05/2015
Changed in this revision
--- a/RF24.lib Mon Jul 06 05:24:49 2015 +0000 +++ b/RF24.lib Thu Nov 05 05:59:18 2015 +0000 @@ -1,1 +1,1 @@ -http://developer.mbed.org/users/akashvibhute/code/RF24/#00706a42491e +http://developer.mbed.org/users/akashvibhute/code/RF24/#e94be00fd19e
--- a/RF24Network.lib Mon Jul 06 05:24:49 2015 +0000 +++ b/RF24Network.lib Thu Nov 05 05:59:18 2015 +0000 @@ -1,1 +1,1 @@ -http://developer.mbed.org/users/akashvibhute/code/RF24Network/#caf146ffe8b0 +http://developer.mbed.org/users/akashvibhute/code/RF24Network/#dfc8da7ac18c
--- a/main.cpp Mon Jul 06 05:24:49 2015 +0000 +++ b/main.cpp Thu Nov 05 05:59:18 2015 +0000 @@ -10,19 +10,19 @@ #define spi_MOSI D4 #define spi_MISO D5 -RF24 radio(spi_MOSI, spi_MISO, spi_SCK, nrf_CSN, nrf_CE); +RF24 radio(spi_MOSI, spi_MISO, spi_SCK, nrf_CE, nrf_CSN ); // Network uses that radio RF24Network network(radio); // Address of our node -const uint16_t this_node = 0; +const uint16_t this_node = 01; // Address of the other node -const uint16_t other_node = 1; +const uint16_t other_node = 00; // How often to send payload packet to the other unit -const unsigned long interval = 1000; //ms +const unsigned long interval = 100; //ms // When did we last send? unsigned long last_sent; @@ -37,8 +37,6 @@ { unsigned long ms; unsigned long counter; - - float vector_4d[4]; }; @@ -68,10 +66,6 @@ payload_t payload_tx; payload_tx.ms = t_packet.read_ms(); payload_tx.counter = packets_sent++; - for(int i=0; i<=3; i++) - { - payload_tx.vector_4d[i] = i + 1.00f; - } RF24NetworkHeader header_tx(/*to node*/ other_node);
--- a/mbed.bld Mon Jul 06 05:24:49 2015 +0000 +++ b/mbed.bld Thu Nov 05 05:59:18 2015 +0000 @@ -1,1 +1,1 @@ -http://mbed.org/users/mbed_official/code/mbed/builds/7cff1c4259d7 \ No newline at end of file +http://mbed.org/users/mbed_official/code/mbed/builds/9296ab0bfc11 \ No newline at end of file