Skip to content

Commit b24aff9

Browse files
Fix grammatical errors
1. at the top _of_ your sketch 2. such as a project with an LCD ~display~ 3. this is ~in~ actually an example
1 parent 1bf53be commit b24aff9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Language/Variables/Utilities/PROGMEM.adoc

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ Store data in flash (program) memory instead of SRAM. There's a description of t
2121

2222
The `PROGMEM` keyword is a variable modifier, it should be used only with the datatypes defined in pgmspace.h. It tells the compiler "put this information into flash memory", instead of into SRAM, where it would normally go.
2323

24-
PROGMEM is part of the link:http://www.nongnu.org/avr-libc/user-manual/group\__avr__pgmspace.html[pgmspace.h] library. It is included automatically in modern versions of the IDE. However, if you are using an IDE version below 1.0 (2011), you'll first need to include the library at the top your sketch, like this:
24+
PROGMEM is part of the link:http://www.nongnu.org/avr-libc/user-manual/group\__avr__pgmspace.html[pgmspace.h] library. It is included automatically in modern versions of the IDE. However, if you are using an IDE version below 1.0 (2011), you'll first need to include the library at the top of your sketch, like this:
2525

2626
`#include <avr/pgmspace.h>`
2727
While `PROGMEM` could be used on a single variable, it is really only worth the fuss if you have a larger block of data that needs to be stored, which is usually easiest in an array, (or another C++ data structure beyond our present discussion).
@@ -101,7 +101,7 @@ void loop() {
101101
----
102102
*Arrays of strings*
103103

104-
It is often convenient when working with large amounts of text, such as a project with an LCD display, to setup an array of strings. Because strings themselves are arrays, this is in actually an example of a two-dimensional array.
104+
It is often convenient when working with large amounts of text, such as a project with an LCD, to setup an array of strings. Because strings themselves are arrays, this is actually an example of a two-dimensional array.
105105

106106
These tend to be large structures so putting them into program memory is often desirable. The code below illustrates the idea.
107107

@@ -146,7 +146,7 @@ void setup() {
146146
void loop() {
147147
/* Using the string table in program memory requires the use of special functions to retrieve the data.
148148
The strcpy_P function copies a string from program space to a string in RAM ("buffer").
149-
Make sure your receiving string in RAM is large enough to hold whatever
149+
Make sure your receiving string in RAM is large enough to hold whatever
150150
you are retrieving from program space. */
151151
152152

0 commit comments

Comments
 (0)