diff --git a/AsciiDoc_sample/Reference_Terms/AsciiDoc_Template-Parent_Of_Entities.adoc b/AsciiDoc_sample/Reference_Terms/AsciiDoc_Template-Parent_Of_Entities.adoc index c0c06e710..4fdc98960 100644 --- a/AsciiDoc_sample/Reference_Terms/AsciiDoc_Template-Parent_Of_Entities.adoc +++ b/AsciiDoc_sample/Reference_Terms/AsciiDoc_Template-Parent_Of_Entities.adoc @@ -85,7 +85,7 @@ http://arduino.cc[serialEvent()] [role="language"] // Whenever you want to link to another Reference term, or more in general to a relative link, -// use the syntax shown below. Please note that the file format is subsituted by attribute. +// use the syntax shown below. Please note that the file format is substituted by attribute. // Please note that you always need to replace spaces that you might find in folder/file names with %20 // The entire link to Reference pages must be lower case, regardless of the case of the folders and files in this repository. * #LANGUAGE# link:../AsciiDoc_Template-Single_Entity[Single Entity] diff --git a/AsciiDoc_sample/Reference_Terms/AsciiDoc_Template-Single_Entity.adoc b/AsciiDoc_sample/Reference_Terms/AsciiDoc_Template-Single_Entity.adoc index aa4f95051..a9e23d242 100644 --- a/AsciiDoc_sample/Reference_Terms/AsciiDoc_Template-Single_Entity.adoc +++ b/AsciiDoc_sample/Reference_Terms/AsciiDoc_Template-Single_Entity.adoc @@ -110,7 +110,7 @@ image::http://arduino.cc/en/uploads/Main/ArduinoUno_R3_Front_450px.jpg[caption=" [role="language"] // Whenever you want to link to another Reference term, or more in general to a relative link, -// use the syntax shown below. Please note that the file format is subsituted by attribute. +// use the syntax shown below. Please note that the file format is substituted by attribute. // Please note that you always need to replace spaces that you might find in folder/file names with %20 // The entire link to Reference pages must be lower case, regardless of the case of the folders and files in this repository. // For language tag, items will be automatically generated for any other item of the same subcategory, diff --git a/LICENSE.md b/LICENSE.md index c90487cb0..53764dac4 100644 --- a/LICENSE.md +++ b/LICENSE.md @@ -264,7 +264,7 @@ subject to and limited by the following restrictions: UNLESS OTHERWISE MUTUALLY AGREED TO BY THE PARTIES IN WRITING, LICENSOR OFFERS THE WORK AS-IS AND MAKES NO REPRESENTATIONS OR WARRANTIES OF ANY KIND CONCERNING THE WORK, EXPRESS, IMPLIED, STATUTORY OR OTHERWISE, -INCLUDING, WITHOUT LIMITATION, WARRANTIES OF TITLE, MERCHANTIBILITY, +INCLUDING, WITHOUT LIMITATION, WARRANTIES OF TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, NONINFRINGEMENT, OR THE ABSENCE OF LATENT OR OTHER DEFECTS, ACCURACY, OR THE PRESENCE OF ABSENCE OF ERRORS, WHETHER OR NOT DISCOVERABLE. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION diff --git a/Language/Functions/Analog IO/analogWrite.adoc b/Language/Functions/Analog IO/analogWrite.adoc index d6337046a..36894922e 100644 --- a/Language/Functions/Analog IO/analogWrite.adoc +++ b/Language/Functions/Analog IO/analogWrite.adoc @@ -40,7 +40,7 @@ Writes an analog value (http://arduino.cc/en/Tutorial/PWM[PWM wave]) to a pin. C +*+ These pins are officially supported PWM pins. While some boards have additional pins capable of PWM, using them is recommended only for advanced users that can account for timer availability and potential conflicts with other uses of those pins. + +**+ In addition to PWM capabilities on the pins noted above, the MKR, Nano 33 IoT, Zero and UNO R4 boards have true analog output when using `analogWrite()` on the `DAC0` (`A0`) pin. + -+***+ In addition to PWM capabilities on the pins noted above, the Due and GIGA R1 boards have true analog output when using `analogWrite()` on pins `DAC0` and `DAC1`. ++***+ In addition to PWM capabilities on the pins noted above, the Due and GIGA R1 boards have true analog output when using `analogWrite()` on pins `DAC0` and `DAC1`. + +****+ Only 4 different pins can be used at the same time. Enabling PWM on more than 4 pins will abort the running sketch and require resetting the board to upload a new sketch again. + [%hardbreaks] diff --git a/Language/Functions/Bits and Bytes/bitWrite.adoc b/Language/Functions/Bits and Bytes/bitWrite.adoc index 82b4d6a55..b0e5ef723 100644 --- a/Language/Functions/Bits and Bytes/bitWrite.adoc +++ b/Language/Functions/Bits and Bytes/bitWrite.adoc @@ -17,7 +17,7 @@ subCategories: [ "Bits and Bytes" ] [float] === Description -Writes to a bit of a variable, e.g. `bool`, `int`, `long`. Note that `float` & `double` are not supported. You can write to a bit of variables up to an `unsigned long` (32 bits / 8 bytes). +Writes to a bit of a variable, e.g. `bool`, `int`, `long`. Note that `float` & `double` are not supported. You can write to a bit of variables up to an `unsigned long` (32 bits / 4 bytes). [%hardbreaks] diff --git a/Language/Functions/Communication/Print.adoc b/Language/Functions/Communication/Print.adoc index 31b61ba5d..a6b7a142d 100644 --- a/Language/Functions/Communication/Print.adoc +++ b/Language/Functions/Communication/Print.adoc @@ -18,11 +18,11 @@ subCategories: [ "Communication" ] === Description The Print class is an abstract base class that provides a common interface for printing data to different output devices. It defines several methods that allow printing data in different formats. -Print class is related to several libraries in Arduino that use the printing funcionality to interact with devices such as Serial Monitor, LCD Screen, printers, etc. +Print class is related to several libraries in Arduino that use the printing functionality to interact with devices such as Serial Monitor, LCD Screen, printers, etc. Some of the libraries that use the Print class are: -* link:../serial[Serial] +* link:https://www.arduino.cc/en/Reference/serial[Serial] * link:https://reference.arduino.cc/reference/en/libraries/liquidcrystal/[LiquidCrystal] * link:https://www.arduino.cc/en/Reference/Ethernet[Ethernet] * link:https://reference.arduino.cc/reference/en/libraries/wifi/wificlient/[Wifi] @@ -41,8 +41,8 @@ Some of the libraries that use the Print class are: [float] === Functions link:https://www.arduino.cc/reference/en/language/functions/communication/wire/write/[write()] + -link:https://www.arduino.cc/reference/en/language/functions/communication/serial/print/[print()] + -link:https://www.arduino.cc/reference/en/language/functions/communication/serial/println/[println()] +link:https://www.arduino.cc/en/Reference/serial/print/[print()] + +link:https://www.arduino.cc/en/Reference/serial/println/[println()] ''' @@ -58,4 +58,4 @@ link:https://www.arduino.cc/reference/en/language/functions/communication/serial === See also -- -// SEE ALSO SECTION ENDS \ No newline at end of file +// SEE ALSO SECTION ENDS diff --git a/Language/Functions/Communication/SPI.adoc b/Language/Functions/Communication/SPI.adoc index d99d60d29..a448778cf 100644 --- a/Language/Functions/Communication/SPI.adoc +++ b/Language/Functions/Communication/SPI.adoc @@ -31,16 +31,16 @@ To read more about Arduino and SPI, you can visit the https://docs.arduino.cc/le [#howtouse] -- |================================================================================================================================================ -| Boards | Default SPI Pins | Additonal SPI Pins | Notes | -| UNO R3, UNO R3 SMD, UNO WiFi Rev2, UNO Mini Ltd| 10(CS), 11(COPI), 12(CIPO), 13(SCK) | | SPI pins available on ICSP header | -| UNO R4 Minima, UNO R4 WiFi| 10(CS), 11(COPI), 12(CIPO), 13(SCK) | | SPI pins available on ICSP header | -| Leonardo, Yún Rev2, Zero| 10(CS), 11(COPI), 12(CIPO), 13(SCK) | | SPI pins available on ICSP header | -| Micro | 14(CIPO), 15(SCK), 16(COPI) | | +| Boards | Default SPI Pins | Additional SPI Pins | Notes +| UNO R3, UNO R3 SMD, UNO WiFi Rev2, UNO Mini Ltd| 10(CS), 11(COPI), 12(CIPO), 13(SCK) | | SPI pins available on ICSP header +| UNO R4 Minima, UNO R4 WiFi| 10(CS), 11(COPI), 12(CIPO), 13(SCK) | | SPI pins available on ICSP header +| Leonardo, Yún Rev2, Zero| 10(CS), 11(COPI), 12(CIPO), 13(SCK) | | SPI pins available on ICSP header +| Micro | 14(CIPO), 15(SCK), 16(COPI) | | | Nano boards | 11(COPI), 12(CIPO), 13(SCK) | | | MKR boards | 8(COPI), 9(SCK), 10(CIPO) | | -| Due | 74(CIPO), 75(MOSI), 76(SCK) | SPI pins available on dedicated SPI header | | -| GIGA R1 WiFi | 89(CIPO), 90(COPI), 91(SCK) | 12(CIPO), 11(COPI), 13(SCK), 10(CS) | Note that pin 89,90,91 are located on the SPI header | -| Mega 2560 Rev3 | 50(CIPO), 51(COPI), 52(SCK), 53(CS) | | SPI pins available on ICSP header | +| Due | 74(CIPO), 75(MOSI), 76(SCK) | SPI pins available on dedicated SPI header | +| GIGA R1 WiFi | 89(CIPO), 90(COPI), 91(SCK) | 12(CIPO), 11(COPI), 13(SCK), 10(CS) | Note that pin 89,90,91 are located on the SPI header +| Mega 2560 Rev3 | 50(CIPO), 51(COPI), 52(SCK), 53(CS) | | SPI pins available on ICSP header |================================================================================================================================================ -- diff --git a/Language/Functions/Communication/Serial.adoc b/Language/Functions/Communication/Serial.adoc index 2342f7251..9b47ddbff 100644 --- a/Language/Functions/Communication/Serial.adoc +++ b/Language/Functions/Communication/Serial.adoc @@ -17,21 +17,35 @@ Used for communication between the Arduino board and a computer or other devices [options="header"] |================================================================================================================================================ -| Board | Serial pins | Serial1 pins | Serial2 pins | Serial3 pins -| UNO R3, UNO R3 SMD Mini | 0(RX), 1(TX) | | | -| UNO R4 Minima, UNO R4 WiFi| 18(RX), 17(TX) | | | -| Leonardo, Micro, Yún Rev2 | 0(RX), 1(TX) | | | -| Uno WiFi Rev.2 | 0(RX), 1(TX) | | | -| 101 | 0(RX), 1(TX) | | | -| MKR boards | 13(RX), 14(TX) | | | -| Nano boards | 0(RX), 1(TX) | | | -| Zero | 0(RX), 1(TX) | | | -| Due | 0(RX), 1(TX) | 19(RX1), 18(TX1) | 17(RX2), 16(TX2) | 15(RX3), 14(TX3) -| GIGA R1 WiFi | 0(RX), 1(TX) | 19(RX1), 18(TX1) | 17(RX2), 16(TX2) | 15(RX3), 14(TX3) -| Mega 2560 Rev3 | 0(RX), 1(TX) | 19(RX1), 18(TX1) | 17(RX2), 16(TX2) | 15(RX3), 14(TX3) +| Board | Serial pins | Serial1 pins | Serial2 pins | Serial3 pins | Serial4 pins +| UNO R3, UNO R3 SMD Mini | 0(RX), 1(TX) | | | | +| Nano (classic) | 0(RX), 1(TX) | | | | +| UNO R4 Minima, UNO R4 WiFi| | 0(RX0), 1(TX0) | | | +| Leonardo, Micro, Yún Rev2 | | 0(RX), 1(TX) | | | +| Uno WiFi Rev.2 | | 0(RX), 1(TX) | | | +| MKR boards | | 13(RX), 14(TX) | | | +| Zero | | 0(RX), 1(TX) | | | +| GIGA R1 WiFi | | 0(RX), 1(TX) | 19(RX1), 18(TX1) | 17(RX2), 16(TX2) | 15(RX3), 14(TX3) +| Due | 0(RX), 1(TX) | 19(RX1), 18(TX1) | 17(RX2), 16(TX2) | 15(RX3), 14(TX3) | +| Mega 2560 Rev3 | 0(RX), 1(TX) | 19(RX1), 18(TX1) | 17(RX2), 16(TX2) | 15(RX3), 14(TX3) | +| Nano 33 IoT | | 0(RX0), 1(TX0) | | | +| Nano RP2040 Connect | | 0(RX0), 1(TX0) | | | +| Nano BLE / BLE Sense | | 0(RX0), 1(TX0) | | | |================================================================================================================================================ +[options="header"] + +The Nano ESP32 board is an exception due to being based on the ESP32 core. Here, `Serial0` refers to `RX0` and `TX0`, while `Serial1` and `Serial2` are additional ports that can be assigned to any free GPIO. + +|================================================================================================================================================ +| Board | Serial0 pins | Serial1 pins | Serial2 pins | Serial3 pins | Serial4 pins +| Nano ESP32 | 0(RX0), 1(TX0) | Any free GPIO | Any free GPIO | | +|================================================================================================================================================ + +You can read more about configuring the Nano ESP32's additional serial ports in https://docs.arduino.cc/tutorials/nano-esp32/cheat-sheet/#uart[this article]. + +[%hardbreaks] On older boards (Uno, Nano, Mini, and Mega), pins 0 and 1 are used for communication with the computer. Connecting anything to these pins can interfere with that communication, including causing failed uploads to the board. [%hardbreaks] You can use the Arduino environment's built-in serial monitor to communicate with an Arduino board. Click the serial monitor button in the toolbar and select the same baud rate used in the call to `begin()`. diff --git a/Language/Functions/Communication/Serial/available.adoc b/Language/Functions/Communication/Serial/available.adoc index 4c6d7a60f..14b8ab166 100644 --- a/Language/Functions/Communication/Serial/available.adoc +++ b/Language/Functions/Communication/Serial/available.adoc @@ -24,7 +24,7 @@ Get the number of bytes (characters) available for reading from the serial port. [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. [float] diff --git a/Language/Functions/Communication/Serial/availableForWrite.adoc b/Language/Functions/Communication/Serial/availableForWrite.adoc index 9989dfb66..fe76f5407 100644 --- a/Language/Functions/Communication/Serial/availableForWrite.adoc +++ b/Language/Functions/Communication/Serial/availableForWrite.adoc @@ -25,7 +25,7 @@ Get the number of bytes (characters) available for writing in the serial buffer [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. [float] diff --git a/Language/Functions/Communication/Serial/begin.adoc b/Language/Functions/Communication/Serial/begin.adoc index ea8c0f04e..ed0bf8270 100644 --- a/Language/Functions/Communication/Serial/begin.adoc +++ b/Language/Functions/Communication/Serial/begin.adoc @@ -28,7 +28,7 @@ An optional second argument configures the data, parity, and stop bits. The defa [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `speed`: in bits per second (baud). Allowed data types: `long`. + `config`: sets data, parity, and stop bits. Valid values are: + `SERIAL_5N1` + @@ -112,7 +112,7 @@ Thanks to Jeff Gray for the mega example [float] === Notes and Warnings -For USB CDC serial ports (e.g. `Serial` on the Leonardo), `Serial.begin()` is irrelevant. You can use any baud rate and configuration for serial communication with these ports. See the list of available serial ports for each board on the link:../../serial[Serial main page]. +For USB CDC serial ports (e.g. `Serial` on the Leonardo), `Serial.begin()` is irrelevant. You can use any baud rate and configuration for serial communication with these ports. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. The only `config` value supported for `Serial1` on the Arduino Nano 33 BLE and Nano 33 BLE Sense boards is `SERIAL_8N1`. [%hardbreaks] diff --git a/Language/Functions/Communication/Serial/end.adoc b/Language/Functions/Communication/Serial/end.adoc index b13b78ff5..a3b101c79 100644 --- a/Language/Functions/Communication/Serial/end.adoc +++ b/Language/Functions/Communication/Serial/end.adoc @@ -25,7 +25,7 @@ Disables serial communication, allowing the RX and TX pins to be used for genera [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. [float] diff --git a/Language/Functions/Communication/Serial/find.adoc b/Language/Functions/Communication/Serial/find.adoc index b36efdc63..9f454de0a 100644 --- a/Language/Functions/Communication/Serial/find.adoc +++ b/Language/Functions/Communication/Serial/find.adoc @@ -28,7 +28,7 @@ title: Serial.find() [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `target`: the string to search for. Allowed data types: `char`. + `length`: length of the target. Allowed data types: `size_t`. diff --git a/Language/Functions/Communication/Serial/findUntil.adoc b/Language/Functions/Communication/Serial/findUntil.adoc index f19bfa6ef..a2e9fc0d6 100644 --- a/Language/Functions/Communication/Serial/findUntil.adoc +++ b/Language/Functions/Communication/Serial/findUntil.adoc @@ -29,7 +29,7 @@ The function returns true if the target string is found, false if it times out. [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `target`: the string to search for. Allowed data types: `char`. + `terminal`: the terminal string in the search. Allowed data types: `char`. diff --git a/Language/Functions/Communication/Serial/flush.adoc b/Language/Functions/Communication/Serial/flush.adoc index 03a0b6819..fb7027f6a 100644 --- a/Language/Functions/Communication/Serial/flush.adoc +++ b/Language/Functions/Communication/Serial/flush.adoc @@ -27,7 +27,7 @@ Waits for the transmission of outgoing serial data to complete. [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. [float] diff --git a/Language/Functions/Communication/Serial/parseFloat.adoc b/Language/Functions/Communication/Serial/parseFloat.adoc index b9b0cde79..6c1f01bcd 100644 --- a/Language/Functions/Communication/Serial/parseFloat.adoc +++ b/Language/Functions/Communication/Serial/parseFloat.adoc @@ -29,7 +29,7 @@ title: Serial.parseFloat() [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `lookahead`: the mode used to look ahead in the stream for a floating point number. Allowed data types: `LookaheadMode`. Allowed `lookahead` values: * `SKIP_ALL`: all characters other than a minus sign, decimal point, or digits are ignored when scanning the stream for a floating point number. This is the default mode. diff --git a/Language/Functions/Communication/Serial/parseInt.adoc b/Language/Functions/Communication/Serial/parseInt.adoc index 962b48cbd..93c6e1563 100644 --- a/Language/Functions/Communication/Serial/parseInt.adoc +++ b/Language/Functions/Communication/Serial/parseInt.adoc @@ -35,7 +35,7 @@ In particular: [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `lookahead`: the mode used to look ahead in the stream for an integer. Allowed data types: `LookaheadMode`. Allowed `lookahead` values: * `SKIP_ALL`: all characters other than digits or a minus sign are ignored when scanning the stream for an integer. This is the default mode. diff --git a/Language/Functions/Communication/Serial/peek.adoc b/Language/Functions/Communication/Serial/peek.adoc index 7209996be..557c729af 100644 --- a/Language/Functions/Communication/Serial/peek.adoc +++ b/Language/Functions/Communication/Serial/peek.adoc @@ -27,7 +27,7 @@ Returns the next byte (character) of incoming serial data without removing it fr [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. [float] diff --git a/Language/Functions/Communication/Serial/print.adoc b/Language/Functions/Communication/Serial/print.adoc index a14c9cec1..8f09302a0 100644 --- a/Language/Functions/Communication/Serial/print.adoc +++ b/Language/Functions/Communication/Serial/print.adoc @@ -48,7 +48,7 @@ To send data without conversion to its representation as characters, use link:.. [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `val`: the value to print. Allowed data types: any data type. @@ -100,7 +100,7 @@ void loop() { for (int x = 0; x < 64; x++) { // only part of the ASCII chart, change to suit // print it out in many formats: Serial.print(x); // print as an ASCII-encoded decimal - same as "DEC" - Serial.print("\t\t"); // prints two tabs to accomodate the label length + Serial.print("\t\t"); // prints two tabs to accommodate the label length Serial.print(x, DEC); // print as an ASCII-encoded decimal Serial.print("\t"); // prints a tab diff --git a/Language/Functions/Communication/Serial/println.adoc b/Language/Functions/Communication/Serial/println.adoc index 15ef923c0..49dc2aaa1 100644 --- a/Language/Functions/Communication/Serial/println.adoc +++ b/Language/Functions/Communication/Serial/println.adoc @@ -26,7 +26,7 @@ Prints data to the serial port as human-readable ASCII text followed by a carria [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `val`: the value to print. Allowed data types: any data type. + `format`: specifies the number base (for integral data types) or number of decimal places (for floating point types). diff --git a/Language/Functions/Communication/Serial/read.adoc b/Language/Functions/Communication/Serial/read.adoc index 2a781fc7e..b721f2322 100644 --- a/Language/Functions/Communication/Serial/read.adoc +++ b/Language/Functions/Communication/Serial/read.adoc @@ -27,7 +27,7 @@ Reads incoming serial data. [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. [float] diff --git a/Language/Functions/Communication/Serial/readBytes.adoc b/Language/Functions/Communication/Serial/readBytes.adoc index da566d64b..eee28340b 100644 --- a/Language/Functions/Communication/Serial/readBytes.adoc +++ b/Language/Functions/Communication/Serial/readBytes.adoc @@ -29,7 +29,7 @@ title: Serial.readBytes() [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `buffer`: the buffer to store the bytes in. Allowed data types: array of `char` or `byte`. + `length`: the number of bytes to read. Allowed data types: `int`. diff --git a/Language/Functions/Communication/Serial/readBytesUntil.adoc b/Language/Functions/Communication/Serial/readBytesUntil.adoc index d35ff46c2..50775c471 100644 --- a/Language/Functions/Communication/Serial/readBytesUntil.adoc +++ b/Language/Functions/Communication/Serial/readBytesUntil.adoc @@ -29,7 +29,7 @@ Serial.readBytesUntil() reads characters from the serial buffer into an array. T [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `character`: the character to search for. Allowed data types: `char`. + `buffer`: the buffer to store the bytes in. Allowed data types: array of `char` or `byte`. + `length`: the number of bytes to read. Allowed data types: `int`. diff --git a/Language/Functions/Communication/Serial/readString.adoc b/Language/Functions/Communication/Serial/readString.adoc index c0fa8856c..496787c8e 100644 --- a/Language/Functions/Communication/Serial/readString.adoc +++ b/Language/Functions/Communication/Serial/readString.adoc @@ -27,7 +27,7 @@ title: Serial.readString() [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. [float] @@ -85,7 +85,7 @@ The function does not terminate early if the data contains end of line character === See also [role="language"] -* #LANGUAGE# link:../../serial[Serial] +* #LANGUAGE# link:https://www.arduino.cc/en/Reference/serial[Serial] * #LANGUAGE# link:../begin[begin()] * #LANGUAGE# link:../end[end()] * #LANGUAGE# link:../available[available()] diff --git a/Language/Functions/Communication/Serial/readStringUntil.adoc b/Language/Functions/Communication/Serial/readStringUntil.adoc index 5a699bfc2..54f24540f 100644 --- a/Language/Functions/Communication/Serial/readStringUntil.adoc +++ b/Language/Functions/Communication/Serial/readStringUntil.adoc @@ -27,7 +27,7 @@ title: Serial.readStringUntil() [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `terminator`: the character to search for. Allowed data types: `char`. @@ -62,7 +62,7 @@ If the terminator character can't be found, all read characters will be discarde === See also [role="language"] -* #LANGUAGE# link:../../serial[Serial] +* #LANGUAGE# link:https://www.arduino.cc/en/Reference/serial[Serial] * #LANGUAGE# link:../begin[begin()] * #LANGUAGE# link:../end[end()] * #LANGUAGE# link:../available[available()] diff --git a/Language/Functions/Communication/Serial/setTimeout.adoc b/Language/Functions/Communication/Serial/setTimeout.adoc index 76e73dff1..41d5f224c 100644 --- a/Language/Functions/Communication/Serial/setTimeout.adoc +++ b/Language/Functions/Communication/Serial/setTimeout.adoc @@ -27,7 +27,7 @@ title: Serial.setTimeout() [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `time`: timeout duration in milliseconds. Allowed data types: `long`. diff --git a/Language/Functions/Communication/Serial/write.adoc b/Language/Functions/Communication/Serial/write.adoc index 00f0bdc66..cfcd0b944 100644 --- a/Language/Functions/Communication/Serial/write.adoc +++ b/Language/Functions/Communication/Serial/write.adoc @@ -24,7 +24,7 @@ Writes binary data to the serial port. This data is sent as a byte or series of [float] === Parameters -`_Serial_`: serial port object. See the list of available serial ports for each board on the link:../../serial[Serial main page]. + +`_Serial_`: serial port object. See the list of available serial ports for each board on the link:https://www.arduino.cc/en/Reference/serial[Serial main page]. + `val`: a value to send as a single byte. + `str`: a string to send as a series of bytes. + `buf`: an array to send as a series of bytes. + diff --git a/Language/Functions/Communication/Wire.adoc b/Language/Functions/Communication/Wire.adoc index 4aed17dc7..50ee777b7 100644 --- a/Language/Functions/Communication/Wire.adoc +++ b/Language/Functions/Communication/Wire.adoc @@ -16,7 +16,7 @@ subCategories: [ "Communication" ] === Description -This library allows you to communicate with I2C devices, a feature that is present on all Arduino boards. I2C is a very common protocol, primarly used for reading/sending data to/from external I2C components. To learn more, visit link:https://docs.arduino.cc/learn/communication/wire[this article for Arduino & I2C]. +This library allows you to communicate with I2C devices, a feature that is present on all Arduino boards. I2C is a very common protocol, primarily used for reading/sending data to/from external I2C components. To learn more, visit link:https://docs.arduino.cc/learn/communication/wire[this article for Arduino & I2C]. Due to the hardware design and various architectural differences, the I2C pins are located in different places. The pin map just below highlights the default pins, as well as additional ports available on certain boards. diff --git a/Language/Functions/Communication/Wire/getWireTimeoutFlag.adoc b/Language/Functions/Communication/Wire/getWireTimeoutFlag.adoc index 25c5301d2..c50449a63 100644 --- a/Language/Functions/Communication/Wire/getWireTimeoutFlag.adoc +++ b/Language/Functions/Communication/Wire/getWireTimeoutFlag.adoc @@ -10,7 +10,7 @@ title: getWireTimeoutFlag() [float] === Description -Checks whether a timeout has occured since the last time the flag was cleared. +Checks whether a timeout has occurred since the last time the flag was cleared. This flag is set is set whenever a timeout occurs and cleared when `Wire.clearWireTimeoutFlag()` is called, or when the timeout is changed using `Wire.setWireTimeout()`. @@ -34,4 +34,4 @@ This function was not available in the original version of the Wire library and -- -//OVERVIEW SECTION ENDS \ No newline at end of file +//OVERVIEW SECTION ENDS diff --git a/Language/Functions/Communication/Wire/setWireTimeout.adoc b/Language/Functions/Communication/Wire/setWireTimeout.adoc index 761e6797c..3cfe18b8e 100644 --- a/Language/Functions/Communication/Wire/setWireTimeout.adoc +++ b/Language/Functions/Communication/Wire/setWireTimeout.adoc @@ -53,7 +53,7 @@ void loop() { Wire.write(123); // send command byte error = Wire.endTransmission(); // run transaction if (error) { - Serial.println("Error occured when writing"); + Serial.println("Error occurred when writing"); if (error == 5) Serial.println("It was a timeout"); } @@ -66,7 +66,7 @@ void loop() { #endif byte len = Wire.requestFrom(8, 1); // request 1 byte from device #8 if (len == 0) { - Serial.println("Error occured when reading"); + Serial.println("Error occurred when reading"); #if defined(WIRE_HAS_TIMEOUT) if (Wire.getWireTimeoutFlag()) Serial.println("It was a timeout"); @@ -88,7 +88,7 @@ If `reset_on_timeout` was set to true and the platform supports this, the Wire h When a timeout is triggered, a flag is set that can be queried with `getWireTimeoutFlag()` and must be cleared manually using `clearWireTimeoutFlag()` (and is also cleared when `setWireTimeout()` is called). -Note that this timeout can also trigger while waiting for clock stretching or waiting for a second master to complete its transaction. So make sure to adapt the timeout to accomodate for those cases if needed. A typical timeout would be 25ms (which is the maximum clock stretching allowed by the SMBus protocol), but (much) shorter values will usually also work. +Note that this timeout can also trigger while waiting for clock stretching or waiting for a second master to complete its transaction. So make sure to adapt the timeout to accommodate for those cases if needed. A typical timeout would be 25ms (which is the maximum clock stretching allowed by the SMBus protocol), but (much) shorter values will usually also work. [float] @@ -102,4 +102,4 @@ If you require the timeout to be disabled, it is recommended you disable it by d -- -//OVERVIEW SECTION ENDS \ No newline at end of file +//OVERVIEW SECTION ENDS diff --git a/Language/Functions/Communication/stream.adoc b/Language/Functions/Communication/stream.adoc index 8950da800..7258a219e 100644 --- a/Language/Functions/Communication/stream.adoc +++ b/Language/Functions/Communication/stream.adoc @@ -22,8 +22,8 @@ Stream defines the reading functions in Arduino. When using any core functionali Some of the libraries that rely on Stream include : -* link:../serial[Serial] -* link:https://www.arduino.cc/en/Reference/Wire[Wire] +* link:https://www.arduino.cc/en/Reference/serial[Serial] +* link:https://www.arduino.cc/en/Reference/wire[Wire] * link:https://www.arduino.cc/en/Reference/Ethernet[Ethernet] * link:https://www.arduino.cc/en/Reference/SD[SD] diff --git a/Language/Functions/USB/Mouse/mouseMove.adoc b/Language/Functions/USB/Mouse/mouseMove.adoc index 852938b29..f4214f85a 100644 --- a/Language/Functions/USB/Mouse/mouseMove.adoc +++ b/Language/Functions/USB/Mouse/mouseMove.adoc @@ -110,7 +110,7 @@ int readAxis(int axisNumber) { } // the Y axis needs to be inverted in order to - // map the movemment correctly: + // map the movement correctly: if (axisNumber == 1) { distance = -distance; } diff --git a/Language/Structure/Control Structure/switchCase.adoc b/Language/Structure/Control Structure/switchCase.adoc index e608c23d2..7b2fad04d 100644 --- a/Language/Structure/Control Structure/switchCase.adoc +++ b/Language/Structure/Control Structure/switchCase.adoc @@ -47,9 +47,9 @@ switch (var) { `var`: an *integer* variable whose value to compare with various cases. Any integer data type is allowed*, such as `byte`, `char`, `int`, `long`. `label1`, `label2`: constants. Any integer data type here is also allowed. -*You can also use the `bool` data type when you just two switch cases. +*You can also use the `bool` data type when you specify just two switch cases. -Note that you can also negative values as input. +Note that you can also use negative values as input. [float] === Returns @@ -72,10 +72,10 @@ Nothing ---- switch (var) { case 1: - //do something when var equals 1 + // do something when var equals 1 break; case 2: - //do something when var equals 2 + // do something when var equals 2 break; default: // if nothing else matches, do the default @@ -92,7 +92,7 @@ switch (var) { -// SEE ALSO SECTIN BEGINS +// SEE ALSO SECTION BEGINS [#see_also] -- diff --git a/Language/Variables/Constants/highLow.adoc b/Language/Variables/Constants/highLow.adoc index f7d84a9ae..1bec2b54e 100644 --- a/Language/Variables/Constants/highLow.adoc +++ b/Language/Variables/Constants/highLow.adoc @@ -12,7 +12,7 @@ subCategories: [ "Constants" ] [float] == Defining Pin Levels: HIGH and LOW -When reading or writing to a digital pin there are only two possible values a pin can take/be-set-to: `HIGH` and `LOW`. These are the same as `true` and `false`, as well as `0` and `1`. +When reading or writing to a digital pin there are only two possible values a pin can take/be-set-to: `HIGH` and `LOW`. These are the same as `true` and `false`, as well as `1` and `0`. [float] === HIGH @@ -58,4 +58,4 @@ When a pin is configured to OUTPUT with pinMode(), and set to LOW with digitalWr [role="language"] -- -// SEE ALSO SECTION ENDS \ No newline at end of file +// SEE ALSO SECTION ENDS diff --git a/Language/Variables/Data Types/array.adoc b/Language/Variables/Data Types/array.adoc index 1825020c8..d9b781b61 100644 --- a/Language/Variables/Data Types/array.adoc +++ b/Language/Variables/Data Types/array.adoc @@ -22,7 +22,7 @@ All of the methods below are valid ways to create (declare) an array. // Declare an array of a given length without initializing the values: int myInts[6]; - // Declare an array without explicitely choosing a size (the compiler + // Declare an array without explicitly choosing a size (the compiler // counts the elements and creates an array of the appropriate size): int myPins[] = {2, 4, 8, 3, 6, 4}; diff --git a/Language/Variables/Variable Scope & Qualifiers/volatile.adoc b/Language/Variables/Variable Scope & Qualifiers/volatile.adoc index 79927f386..8845e1100 100644 --- a/Language/Variables/Variable Scope & Qualifiers/volatile.adoc +++ b/Language/Variables/Variable Scope & Qualifiers/volatile.adoc @@ -55,7 +55,7 @@ There are several ways to do this: === Example Code // Describe what the example code is all about and add relevant code ►►►►► THIS SECTION IS MANDATORY ◄◄◄◄◄ -The `volatile` modifier ensures that changes to the `state` variable are immediately visible in `loop()`. Without the `volatile` modifier, the `state` variable may be loaded into a register when entering the function and would not be updated anymore until the function ends. +The `volatile` modifier ensures that changes to the `changed` variable are immediately visible in `loop()`. Without the `volatile` modifier, the `changed` variable may be loaded into a register when entering the function and would not be updated anymore until the function ends. [source,arduino] ----