shift register works
[bort-panel.git] / pins.h
diff --git a/pins.h b/pins.h
old mode 100644 (file)
new mode 100755 (executable)
index fe53ef5..cb30477
--- a/pins.h
+++ b/pins.h
@@ -54,12 +54,12 @@ void set(char *name, int val) {
        int fd;
 
        p = pin(name);
-       op.gp_pin = p->pin;
+       strlcpy(op.gp_name, name, GPIOPINMAXNAME);
        op.gp_value = val;
        fd = num2fd(p->dev);
 
-       //printf("given name: %s\nderived name: %s\nderived pin: %d\nval: %d\nfd: %d\nreal fd: %d\n", name, p->name,
-       //      p->pin, op.gp_value, fd, g1);
+//     printf("given name: %s\nderived name: %s\nderived pin: %d\nval: %d\nfd: %d\nreal fd: %d\n", name, p->name,
+//             p->pin, op.gp_value, fd, g1);
 
 //     printf("g0: %d g1: %d g2: %d\n", g0, g1, g2);
 
@@ -80,7 +80,6 @@ void pcfg(int devno, int pin, int val, uint8_t mode, char *name) {
        char *nm   = calloc(1, 255);
        char *md   = calloc(1, 255);
 
-       usleep(1000 * 500);
        strlcpy(nm, name, GPIOPINMAXNAME);
 
        if (mode & OUTPUT)