From 46988319a1e9e3477a7ac0a0930beba621a3da6a Mon Sep 17 00:00:00 2001 From: wolfv6 Date: Sat, 12 Nov 2016 14:42:10 -0700 Subject: [PATCH] rename print_microseconds_per_scan() to printMicrosecondsPerScan, rename print_scans_per_second() to printScansPerSecond --- .../PCA9655E_5_keybrd/keybrd_PCA9655E.ino | 4 ++-- examples/keybrd_MCP23018/keybrd_MCP23018.ino | 4 ++-- src/ScanDelay.h | 4 ++-- .../keybrd_4c_split_keyboard_with_IOE.ino | 4 ++-- tutorials/keybrd_5b_LED_on_IOE/keybrd_5b_LED_on_IOE.ino | 4 ++-- tutorials/tutorial_5a_LED_on_uC.md | 2 +- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/examples/IOE_PCA9655E_development/PCA9655E_5_keybrd/keybrd_PCA9655E.ino b/examples/IOE_PCA9655E_development/PCA9655E_5_keybrd/keybrd_PCA9655E.ino index 7c997c7..dd90774 100644 --- a/examples/IOE_PCA9655E_development/PCA9655E_5_keybrd/keybrd_PCA9655E.ino +++ b/examples/IOE_PCA9655E_development/PCA9655E_5_keybrd/keybrd_PCA9655E.ino @@ -107,6 +107,6 @@ void loop() row_R1.process(); scanDelay.delay(); - //debug.print_scans_per_second(); - //debug.print_microseconds_per_scan(); + //debug.printScansPerSecond(); + //debug.printMicrosecondsPerScan(); } diff --git a/examples/keybrd_MCP23018/keybrd_MCP23018.ino b/examples/keybrd_MCP23018/keybrd_MCP23018.ino index aff64a2..94029ff 100644 --- a/examples/keybrd_MCP23018/keybrd_MCP23018.ino +++ b/examples/keybrd_MCP23018/keybrd_MCP23018.ino @@ -121,6 +121,6 @@ void loop() row_R1.process(); scanDelay.delay(); - //debug.print_scans_per_second(); - //debug.print_microseconds_per_scan(); + //debug.printScansPerSecond(); + //debug.printMicrosecondsPerScan(); } diff --git a/src/ScanDelay.h b/src/ScanDelay.h index 7f61e98..93e3ec6 100644 --- a/src/ScanDelay.h +++ b/src/ScanDelay.h @@ -12,10 +12,10 @@ Follow these step to tune DELAY_MICROSECONDS for maximum scan rate for a given S Intantiate DELAY_MICROSECONDS in your sketch: ScanDelay scanDelay(1000); Add this to the sketch's loop() function: - debug.print_microseconds_per_scan(); + debug.printMicrosecondsPerScan(); Compile and load the sketch into the microcontroller; microseconds_per_scan is printed every second. Adjust the value of DELAY_MICROSECONDS and repeat until: - debug.print_microseconds_per_scan() <= DEBOUNCE_TIME / SAMPLE_COUNT_MACRO + debug.printMicrosecondsPerScan() <= DEBOUNCE_TIME / SAMPLE_COUNT_MACRO DEBOUNCE_TIME can be obtained from the switch's datasheet. Some switch bounce times are: Cherry MX specifies 5msec bounce time http://www.cherrycorp.com/english/switches/key/mx.htm diff --git a/tutorials/keybrd_4c_split_keyboard_with_IOE/keybrd_4c_split_keyboard_with_IOE.ino b/tutorials/keybrd_4c_split_keyboard_with_IOE/keybrd_4c_split_keyboard_with_IOE.ino index cb0201e..3f88669 100644 --- a/tutorials/keybrd_4c_split_keyboard_with_IOE/keybrd_4c_split_keyboard_with_IOE.ino +++ b/tutorials/keybrd_4c_split_keyboard_with_IOE/keybrd_4c_split_keyboard_with_IOE.ino @@ -114,6 +114,6 @@ void loop() row_R1.process(); scanDelay.delay(); - //debug.print_scans_per_second(); - //debug.print_microseconds_per_scan(); + //debug.printScansPerSecond(); + //debug.printMicrosecondsPerScan(); } diff --git a/tutorials/keybrd_5b_LED_on_IOE/keybrd_5b_LED_on_IOE.ino b/tutorials/keybrd_5b_LED_on_IOE/keybrd_5b_LED_on_IOE.ino index dfb42a5..bb93316 100644 --- a/tutorials/keybrd_5b_LED_on_IOE/keybrd_5b_LED_on_IOE.ino +++ b/tutorials/keybrd_5b_LED_on_IOE/keybrd_5b_LED_on_IOE.ino @@ -150,6 +150,6 @@ void loop() row_R1.process(); scanDelay.delay(); - //debug.print_scans_per_second(); - //debug.print_microseconds_per_scan(); + //debug.printScansPerSecond(); + //debug.printMicrosecondsPerScan(); } diff --git a/tutorials/tutorial_5a_LED_on_uC.md b/tutorials/tutorial_5a_LED_on_uC.md index f35091b..2264d34 100644 --- a/tutorials/tutorial_5a_LED_on_uC.md +++ b/tutorials/tutorial_5a_LED_on_uC.md @@ -70,7 +70,7 @@ For Forward Current, use the smaller of: current capacity of output pin If = 20 mA continuous Forward Current of LED If = 30 mA -minimum current limiting restiance is R = (Vs - Vf) / If = 55 Ohms +minimum current limiting resistance is R = (Vs - Vf) / If = 55 Ohms ``` Add a safety margin for resistor tolerances (1%, 2%, 5%, 10%), and round up to a standard value. http://www.rfcafe.com/references/electrical/resistor-values.htm