summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorknolax <1339802534.kk@gmail.com>2017-12-23 13:12:44 -0500
committerknolax <1339802534.kk@gmail.com>2017-12-23 13:12:44 -0500
commit641863393b0482b56465f0efc846a5c40be6fb88 (patch)
tree9b673c9c5e6b87b93fd59004702a2a92ac194bd7
parent88f06d42d69444de281e1a57736acf8d5abdaac1 (diff)
fixed testing setup
-rw-r--r--skey.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/skey.c b/skey.c
index 3f21384..13ce0ae 100644
--- a/skey.c
+++ b/skey.c
@@ -70,19 +70,18 @@ int skey_update_thread (void *data) {
int i = 0;
int j = 0;
while (1) {
- if (!i) {
+ if /*(!i) {
printk(KERN_INFO "skey: update thread printed to kernel log every 1s\n");
//reports the a button pressed
input_report_key(skey_dev,KEY_CAPSLOCK,j);
input_sync(skey_dev);
j = !j;
- gpio_set_value(row_pins[0],j);
- }
+ }*/
if (USE_GPIO) {
//reads the keyboard
int row_index = 0;
int column_index = 0;
- /*while (row_index < 3) {
+ while (row_index < 3) {
//sets the column pin high for reading
gpio_set_value_cansleep(row_pins[row_index], 0);
//gives it some buffer time
@@ -101,7 +100,7 @@ int skey_update_thread (void *data) {
gpio_set_value_cansleep(row_pins[row_index], 1);
usleep_range(10,10);
row_index++;
- }*/
+ }
}
//sleep 2000us= 2ms = 0.002 seconds
//usleep_range(2000, 2000);