aboutsummaryrefslogtreecommitdiffstats
path: root/source
diff options
context:
space:
mode:
Diffstat (limited to 'source')
-rw-r--r--source/conf.py38
-rw-r--r--source/lang/api/serialusb.rst22
2 files changed, 30 insertions, 30 deletions
diff --git a/source/conf.py b/source/conf.py
index 1ad4e57..f232b7c 100644
--- a/source/conf.py
+++ b/source/conf.py
@@ -117,25 +117,25 @@ html_theme = 'default'
# further. For a list of options available for each theme, see the
# documentation.
html_theme_options = {
- ## Sidebar placement options
- #'stickysidebar' : 'true',
- 'rightsidebar' : 'true',
- #'collapsiblesidebar' : 'true',
-
- ## Color
- 'sidebarbgcolor' : '#C8C8C8',
- 'sidebarlinkcolor' : 'green',
- 'sidebartextcolor' : 'black',
+ ## Sidebar placement options
+ #'stickysidebar' : 'true',
+ 'rightsidebar' : 'true',
+ #'collapsiblesidebar' : 'true',
+
+ ## Color
+ 'sidebarbgcolor' : '#C8C8C8',
+ 'sidebarlinkcolor' : 'green',
+ 'sidebartextcolor' : 'black',
#'sidebarbtncolor' : 'black',
- 'footerbgcolor' : 'green',
- 'relbarbgcolor' : 'green',
- 'headlinkcolor' : '#000000',
- 'linkcolor' : 'green',
- 'visitedlinkcolor' : 'green',
-
- ## Font
- 'headfont' : 'Georgia',
- 'bodyfont' : 'Lucidia'
+ 'footerbgcolor' : 'green',
+ 'relbarbgcolor' : 'green',
+ 'headlinkcolor' : '#000000',
+ 'linkcolor' : 'green',
+ 'visitedlinkcolor' : 'green',
+
+ ## Font
+ 'headfont' : 'Georgia',
+ 'bodyfont' : 'Lucidia'
}
# Add any paths that contain custom themes here, relative to this directory.
@@ -174,7 +174,7 @@ html_last_updated_fmt = '%b %d, %Y'
# re-add commented line when custom template for api finished
html_sidebars = {
'**': ['globaltoc.html', 'searchbox.html'],
- #'lang/api**':['searchbox.html', 'apilist.html'],
+ #'lang/api**':['searchbox.html', 'apilist.html'],
}
diff --git a/source/lang/api/serialusb.rst b/source/lang/api/serialusb.rst
index 87fa641..4ddfa4a 100644
--- a/source/lang/api/serialusb.rst
+++ b/source/lang/api/serialusb.rst
@@ -224,7 +224,7 @@ running from battery, or connected but not monitored. You may need to
experiment with the DTR/RTS logic for your platform and device
configuration. ::
- #define LED_PIN 13
+ #define LED_PIN BOARD_LED_PIN
void setup() {
/* Set up the LED to blink */
@@ -232,22 +232,22 @@ configuration. ::
}
void loop() {
- // LED will stay off if we are disconnected;
- // will blink quickly if USB is unplugged (battery etc)
+ // LED will stay off if we are disconnected, and will blink
+ // quickly if USB is unplugged (battery power, etc.).
if(SerialUSB.isConnected()) {
digitalWrite(LED_PIN, 1);
}
delay(100);
- // If this logic fails to detect if bytes are going to
- // be read by the USB host, then the println() will fully
- // many times, causing a very slow LED blink.
- // If the characters are printed and read, the blink will
- // only slow a small amount when "really" connected, and fast
- // when the virtual port is only configured.
+ // If this logic fails to detect if bytes are going to be read
+ // by the USB host, then the println() take a long time,
+ // causing a very slow LED blink. If the characters are
+ // printed and read, the blink will only slow a small amount
+ // when "really" connected, and will be fast fast when the
+ // virtual port is only configured.
if(SerialUSB.isConnected() && (SerialUSB.getDTR() || SerialUSB.getRTS())) {
- for(int i=0; i<10; i++) {
- SerialUSB.println(123456,BIN);
+ for(int i = 0; i < 10; i++) {
+ SerialUSB.println(123456, BIN);
}
}
digitalWrite(LED_PIN, 0);