From 251e4d21ad9932d9dc703a4206c7f2662f279dc0 Mon Sep 17 00:00:00 2001 From: Edgar Bonet Date: Fri, 5 Nov 2021 23:39:57 +0100 Subject: [PATCH 1/3] Add missing space in ASCII DOC line break --- Language/Functions/USB/Keyboard/keyboardPrintln.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Language/Functions/USB/Keyboard/keyboardPrintln.adoc b/Language/Functions/USB/Keyboard/keyboardPrintln.adoc index 1ae3551ce..3a6b8b5cc 100644 --- a/Language/Functions/USB/Keyboard/keyboardPrintln.adoc +++ b/Language/Functions/USB/Keyboard/keyboardPrintln.adoc @@ -23,7 +23,7 @@ Sends a keystroke to a connected computer, followed by a newline and carriage re [float] === Syntax `Keyboard.println()` + -`Keyboard.println(character)`+ +`Keyboard.println(character)` + `Keyboard.println(characters)` From dc145796273217bb435519965461c46c20889b22 Mon Sep 17 00:00:00 2001 From: Edgar Bonet Date: Fri, 5 Nov 2021 23:54:51 +0100 Subject: [PATCH 2/3] Copy edit keyboardPrint{,ln}.adoc - a string is sent as multiple keystrokes, not as a single keystroke - these functions return the number of keystrokes sent, which is far smaller than the number of bytes. --- Language/Functions/USB/Keyboard/keyboardPrint.adoc | 6 +++--- Language/Functions/USB/Keyboard/keyboardPrintln.adoc | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Language/Functions/USB/Keyboard/keyboardPrint.adoc b/Language/Functions/USB/Keyboard/keyboardPrint.adoc index 1f5014d73..f93530145 100644 --- a/Language/Functions/USB/Keyboard/keyboardPrint.adoc +++ b/Language/Functions/USB/Keyboard/keyboardPrint.adoc @@ -14,7 +14,7 @@ title: Keyboard.print() [float] === Description -Sends a keystroke to a connected computer. +Sends one or more keystrokes to a connected computer. `Keyboard.print()` must be called after initiating link:../keyboardbegin[Keyboard.begin()]. [%hardbreaks] @@ -29,12 +29,12 @@ Sends a keystroke to a connected computer. [float] === Parameters `character`: a char or int to be sent to the computer as a keystroke. + -`characters`: a string to be sent to the computer as a keystroke. +`characters`: a string to be sent to the computer as keystrokes. [float] === Returns -Number of bytes sent. Data type: `size_t`. +Number of keystrokes sent. Data type: `size_t`. -- // OVERVIEW SECTION ENDS diff --git a/Language/Functions/USB/Keyboard/keyboardPrintln.adoc b/Language/Functions/USB/Keyboard/keyboardPrintln.adoc index 3a6b8b5cc..43deaf2fa 100644 --- a/Language/Functions/USB/Keyboard/keyboardPrintln.adoc +++ b/Language/Functions/USB/Keyboard/keyboardPrintln.adoc @@ -14,7 +14,7 @@ title: Keyboard.println() [float] === Description -Sends a keystroke to a connected computer, followed by a newline and carriage return. +Sends one or more keystrokes to a connected computer, followed by a newline and carriage return. `Keyboard.println()` must be called after initiating link:../keyboardbegin[Keyboard.begin()]. [%hardbreaks] @@ -30,12 +30,12 @@ Sends a keystroke to a connected computer, followed by a newline and carriage re [float] === Parameters `character`: a char or int to be sent to the computer as a keystroke, followed by newline and carriage return. + -`characters`: a string to be sent to the computer as a keystroke, followed by a newline and carriage return. +`characters`: a string to be sent to the computer as keystrokes, followed by a newline and carriage return. [float] === Returns -Number of bytes sent. Data type: `size_t`. +Number of keystrokes sent. Data type: `size_t`. -- // OVERVIEW SECTION ENDS From 8c498c1836c99b95707bab3ae77cf0c7dc58f7bb Mon Sep 17 00:00:00 2001 From: Edgar Bonet Date: Sat, 6 Nov 2021 00:01:15 +0100 Subject: [PATCH 3/3] Clarify the end of lines sent by Keyboard.println There is no such thing as the "newline" or "carriage return" keys. Instead, Keyboard.println() hits the Return key, more commonly known as the Enter key. --- Language/Functions/USB/Keyboard/keyboardPrintln.adoc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Language/Functions/USB/Keyboard/keyboardPrintln.adoc b/Language/Functions/USB/Keyboard/keyboardPrintln.adoc index 43deaf2fa..062b9c92f 100644 --- a/Language/Functions/USB/Keyboard/keyboardPrintln.adoc +++ b/Language/Functions/USB/Keyboard/keyboardPrintln.adoc @@ -14,7 +14,7 @@ title: Keyboard.println() [float] === Description -Sends one or more keystrokes to a connected computer, followed by a newline and carriage return. +Sends one or more keystrokes to a connected computer, followed by a keystroke on the Enter key. `Keyboard.println()` must be called after initiating link:../keyboardbegin[Keyboard.begin()]. [%hardbreaks] @@ -29,8 +29,8 @@ Sends one or more keystrokes to a connected computer, followed by a newline and [float] === Parameters -`character`: a char or int to be sent to the computer as a keystroke, followed by newline and carriage return. + -`characters`: a string to be sent to the computer as keystrokes, followed by a newline and carriage return. +`character`: a char or int to be sent to the computer as a keystroke, followed by Enter. + +`characters`: a string to be sent to the computer as keystrokes, followed by Enter. [float]