Skip to content

Commit 38fd8dc

Browse files
author
ak75
committed
fix Arduino examples
use program space pointer - PSTR
1 parent 7c5214a commit 38fd8dc

File tree

6 files changed

+7
-7
lines changed

6 files changed

+7
-7
lines changed

examples/Shell_Basic/Shell_Basic.ino

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ void setup()
2727
shell_init(shell_reader, shell_writer, 0);
2828

2929
// Add commands to the shell
30-
shell_register(command_mycommand, "mycommand");
31-
shell_register(command_othercommand, "othercommand");
30+
shell_register(command_mycommand, PSTR("mycommand"));
31+
shell_register(command_othercommand, PSTR("othercommand"));
3232
}
3333

3434
void loop()

examples/Shell_Command_Args/Shell_Command_Args.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ void setup()
2727
shell_init(shell_reader, shell_writer, 0);
2828

2929
// Add commands to the shell
30-
shell_register(command_test, "test");
30+
shell_register(command_test, PSTR("test"));
3131
}
3232

3333
void loop()

examples/Shell_IO_Control/Shell_IO_Control.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ void setup()
1313
shell_init(shell_reader, shell_writer, 0);
1414

1515
// Add commands to the shell
16-
shell_register(command_ioctrl, (const char *) "ioctrl");
16+
shell_register(command_ioctrl, PSTR("ioctrl"));
1717
}
1818

1919
void loop()

examples/Shell_Minimum/Shell_Minimum.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ void setup()
2525
shell_init(shell_reader, shell_writer, 0);
2626

2727
// Add commands to the shell
28-
shell_register(command_example, "example");
28+
shell_register(command_example, PSTR("example"));
2929
}
3030

3131
void loop()

examples/Shell_RGB_Control/Shell_RGB_Control.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ void setup()
3333
shell_init(shell_reader, shell_writer, 0);
3434

3535
// Add commands to the shell
36-
shell_register(command_rgbled, "rgbled");
36+
shell_register(command_rgbled, PSTR("rgbled"));
3737
}
3838

3939
void loop()

examples/Shell_Telnet/Shell_Telnet.ino

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ void setup()
6363
shell_init(shell_reader, shell_writer, 0);
6464

6565
// Add commands to the shell
66-
shell_register(command_rgbled, "rgbled");
66+
shell_register(command_rgbled, PSTR("rgbled"));
6767

6868
}
6969

0 commit comments

Comments
 (0)