summaryrefslogtreecommitdiffstats
path: root/rf_test/send.c
diff options
context:
space:
mode:
authorSadeep Madurange <sadeep@asciimx.com>2025-02-01 11:25:19 +0800
committerSadeep Madurange <sadeep@asciimx.com>2025-02-01 11:25:19 +0800
commit50deb9d280254c8e17624b368ea778f69dd86767 (patch)
tree5ca1724ebdee3ff2a786dc37b6cc266ba9cb0585 /rf_test/send.c
parenta7644c020c4c2b72fc0f13aeea4be47ba08f1961 (diff)
downloadsmart-home-50deb9d280254c8e17624b368ea778f69dd86767.tar.gz
Start work on nRF24L01.
Diffstat (limited to 'rf_test/send.c')
-rw-r--r--rf_test/send.c34
1 files changed, 0 insertions, 34 deletions
diff --git a/rf_test/send.c b/rf_test/send.c
deleted file mode 100644
index b390cf3..0000000
--- a/rf_test/send.c
+++ /dev/null
@@ -1,34 +0,0 @@
-#include <stdlib.h>
-#include <string.h>
-
-#include <avr/io.h>
-#include <avr/interrupt.h>
-#include <util/delay.h>
-
-#include "radio.h"
-#include "serial.h"
-
-int main(void)
-{
- uint8_t n;
- struct radio_cfg cfg;
- const char *s = "hello, world!";
-
- n = strlen(s);
-
- cfg.netid = 0x01;
- cfg.nodeid = 0x02;
- cfg.payload_len = n;
-
- serial_init();
- radio_init(&cfg);
- radio_set_tx_power(18);
-
- for (;;) {
- radio_send(s, n);
- serial_write_line("sent");
- _delay_ms(1500);
- }
-
- return 0;
-}