|
15 | 15 | - Configurable RF transmitter input (TX_PIN); can be any digital pin, depends board (D5 as default).
|
16 | 16 | - Support to configure a digital output so that a led blinks at valid RF code reception.
|
17 | 17 | - Support to configure send of every 'space' before 'pulse', which stripped in previous version firmware.
|
18 |
| - - Support to configure initial RX settings at boot, like as 's:20,200,3000,82000@'. |
19 |
| - - Support to configure show settings at boot, like as: 'v:20,200,3000,82000,2,1,1600@'. |
| 18 | + - Support to configure initial RX settings at boot, like as 's:20,200,4000,82000@'. |
| 19 | + - Support to configure show settings at boot, like as: 'v:20,200,4000,82000,2,1,1600@'. |
20 | 20 | - Support to configure add line feed '\n' each line output.
|
21 | 21 |
|
22 | 22 | */
|
|
28 | 28 | #define EVERY_SEC_LINE_FEED // If defined, print line feed '\n' every second, to emulate legacy firmware.
|
29 | 29 | //#define SEND_STRIPPED_SPACES // If defined, send every 'space' before 'pulse' in broadcast(), which stripped in legacy firmware.
|
30 | 30 | //#define LED_BLINK_RX LED_BUILTIN // If defined, sets the digital output to blink on valid RF code reception.
|
31 |
| -//#define DEFAULT_RX_SETTINGS // If defined, sets valid RX settings at boot, like sets 's:20,200,3000,82000@' |
32 |
| -//#define BOOT_SHOW_SETTINGS // If defined, show settings at boot, like as: 'v:20,200,3000,82000,2,1,1600@' |
| 31 | +//#define DEFAULT_RX_SETTINGS // If defined, sets valid RX settings at boot, like sets 's:20,200,4000,82000@' |
| 32 | +//#define BOOT_SHOW_SETTINGS // If defined, show settings at boot, like as: 'v:20,200,4000,82000,2,1,1600@' |
33 | 33 | //#define ADD_LINE_FEED // If defined, add line feed '\n' each line output.
|
34 | 34 |
|
35 | 35 | #define BUFFER_SIZE 256 // Warning: 256 max because buffer indexes "nrpulses" and "q" are "uint8_t" type
|
|
45 | 45 | #ifdef DEFAULT_RX_SETTINGS
|
46 | 46 | uint8_t minrawlen = 20; // Minimum number of pulses
|
47 | 47 | uint8_t maxrawlen = 200; // Maximum number of pulses
|
48 |
| -uint16_t mingaplen = 300; // Minimum length of footer pulse and maximum length of previous pulses. Used and showing multiplied by 10 |
| 48 | +uint16_t mingaplen = 400; // Minimum length of footer pulse and maximum length of previous pulses. Used and showing multiplied by 10 |
49 | 49 | #else
|
50 | 50 | uint8_t minrawlen = UINT8_MAX; // Maximum value for uint8_t from <cstdint> (stdint.h)
|
51 | 51 | uint8_t maxrawlen = 0;
|
@@ -90,7 +90,7 @@ void setup() {
|
90 | 90 | Serial.begin(BAUD);
|
91 | 91 |
|
92 | 92 | #ifdef BOOT_SHOW_SETTINGS
|
93 |
| - // Show settings at boot, like as: 'v:20,200,3000,82000,2,1,1600@' |
| 93 | + // Show settings at boot, like as: 'v:20,200,4000,82000,2,1,1600@' |
94 | 94 | sprintf(data, "v:%u,%u,%lu,%lu,%d,%d,%d@", minrawlen, maxrawlen, uint32_t(mingaplen)*10, uint32_t(maxgaplen)*10, VERSION, MIN_PULSELENGTH/10, MAX_PULSELENGTH/10);
|
95 | 95 | #ifdef ADD_LINE_FEED
|
96 | 96 | Serial.println(data);
|
|
0 commit comments