Skip to content

Commit b88f4d4

Browse files
committed
WPL 5
1 parent 5ade6bc commit b88f4d4

2 files changed

Lines changed: 9 additions & 1 deletion

File tree

Multiprotocol/Multi_Protos.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -520,7 +520,7 @@ const mm_protocol_definition multi_protocols[] = {
520520
{PROTO_WL91X, STR_WL91X, NO_SUBTYPE, 0, OPTION_NONE, 0, 0, SW_NRF, WL91X_init, WL91X_callback },
521521
#endif
522522
#if defined(WPL_NRF24L01_INO)
523-
{PROTO_WPL, STR_WPL, NO_SUBTYPE, 0, OPTION_NONE, 0, 0, SW_NRF, WPL_init, WPL_callback },
523+
{PROTO_WPL, STR_WPL, NO_SUBTYPE, 0, OPTION_OPTION, 0, 0, SW_NRF, WPL_init, WPL_callback },
524524
#endif
525525
#if defined(XERALL_NRF24L01_INO)
526526
{PROTO_XERALL, STR_XERALL, NO_SUBTYPE, 0, OPTION_NONE, 0, 0, SW_NRF, XERALL_init, XERALL_callback },

Multiprotocol/WPL_nrf24l01.ino

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ Multiprotocol is distributed in the hope that it will be useful,
1919
#include "iface_xn297.h"
2020

2121
#define FORCE_WPL_ORIGINAL_ID
22+
//#define WPL_TEST
2223

2324
#define WPL_PACKET_PERIOD 9875
2425
#define WPL_RF_NUM_CHANNELS 4
@@ -30,6 +31,9 @@ static void __attribute__((unused)) WPL_send_packet()
3031
#if 0
3132
debug("no:%d, rf:%d, ",hopping_frequency_no + (IS_BIND_IN_PROGRESS?0:4),hopping_frequency[hopping_frequency_no + (IS_BIND_IN_PROGRESS?0:4)]);
3233
#endif
34+
#ifdef WPL_TEST
35+
memset(hopping_frequency+4,option,4);
36+
#endif
3337
XN297_Hopping(hopping_frequency_no + (IS_BIND_IN_PROGRESS?0:4) );
3438
hopping_frequency_no++;
3539
hopping_frequency_no &= WPL_RF_NUM_CHANNELS-1; // 4 RF channels
@@ -87,6 +91,10 @@ static void __attribute__((unused)) WPL_initialize_txid()
8791
#ifdef FORCE_WPL_ORIGINAL_ID
8892
memcpy(rx_tx_addr,"\x96\x2A\xA9\x32\xB4",5);
8993
#endif
94+
#ifdef WPL_TEST
95+
memcpy(rx_tx_addr,"\x00\x00\x00\x00\x00",5);
96+
rx_tx_addr[0] = RX_num;
97+
#endif
9098
}
9199

92100
uint16_t WPL_callback()

0 commit comments

Comments
 (0)