Skip to content

Commit 46fd770

Browse files
authored
Update bytes saved number
1 parent 4da05f0 commit 46fd770

File tree

1 file changed

+36
-36
lines changed

1 file changed

+36
-36
lines changed
Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,37 @@
1-
/*
2-
SoftwareSerial TX Only test
3-
4-
If your application is transmit only then setting
5-
#define _SS_TX_ONLY 1
6-
Will stop the library allocating a GPIO interrupt and save 1364 bytes of memory
7-
*/
8-
#define _SS_TX_ONLY 1 // Transmit only (Rx pin is unused/unassigned, but still needs a number)
9-
#define _SS_MAX_RX_BUFF 128 // Increase the Rx buffer to 128 bytes (default is 64 bytes)
10-
#include <SoftwareSerial.h>
11-
12-
SoftwareSerial SoftSerial(2, 3); // RX, TX
13-
14-
uint32_t t;
15-
bool hb_state = false; // heartbeat
16-
17-
void setup()
18-
{
19-
pinMode(LED_BUILTIN, OUTPUT);
20-
SoftSerial.begin(9600);
21-
SoftSerial.println(__FILE__);
22-
SoftSerial.println(__TIME__);
23-
t = millis();
24-
}
25-
26-
void loop()
27-
{
28-
if (millis() - t > 1000)
29-
{
30-
t = millis();
31-
digitalWrite(LED_BUILTIN, hb_state);
32-
hb_state = !hb_state;
33-
SoftSerial.print(".");
34-
}
35-
36-
yield();
1+
/*
2+
SoftwareSerial TX Only test
3+
4+
If your application is transmit only then setting
5+
#define _SS_TX_ONLY 1
6+
Will stop the library allocating a GPIO interrupt and save 1432 bytes of memory
7+
*/
8+
#define _SS_TX_ONLY 1 // Transmit only (Rx pin is unused/unassigned, but still needs a number)
9+
#define _SS_MAX_RX_BUFF 128 // Increase the Rx buffer to 128 bytes (default is 64 bytes)
10+
#include <SoftwareSerial.h>
11+
12+
SoftwareSerial SoftSerial(2, 3); // RX, TX
13+
14+
uint32_t t;
15+
bool hb_state = false; // heartbeat
16+
17+
void setup()
18+
{
19+
pinMode(LED_BUILTIN, OUTPUT);
20+
SoftSerial.begin(9600);
21+
SoftSerial.println(__FILE__);
22+
SoftSerial.println(__TIME__);
23+
t = millis();
24+
}
25+
26+
void loop()
27+
{
28+
if (millis() - t > 1000)
29+
{
30+
t = millis();
31+
digitalWrite(LED_BUILTIN, hb_state);
32+
hb_state = !hb_state;
33+
SoftSerial.print(".");
34+
}
35+
36+
yield();
3737
}

0 commit comments

Comments
 (0)