Ok, so I have identified the problem. GPI on the beaglebone is comparatively slow to GPO when changing state, but it's no where near as bad as I thought. The actual "cutoff" for GPI changes to take effect are somewhere between 500, and 1000 uSec. Or between .5, and 1 millisecond. I tested all the way down to 10uS, and the first GPI of each half of the test was inverted to what it should have been for a correct reading. e.g. maybe slew speed could correct that ?
Now what the actual problem was: sleep() was not functioning in tenths of a second as it should be. In effect, anything less than "1" was working like sleep(0); Perhaps I need to install a package to get this functionality, but according to what I've read in the past, this shouldn't be the case. Maybe I'm remembering incorrectly. So, I instead switched to usleep() *usleep(500);* root@wgd:~/dl-i2c-test# nano tst.c root@wgd:~/dl-i2c-test# gcc -Wall -o tst tst.c root@wgd:~/dl-i2c-test# ./tst *PWM1 1 Z1IN 1* PWM2 1 Z2IN 0 PWM3 1 Z3IN 0 PWM4 1 Z4IN 0 PWM5 1 Z5IN 0 PWM6 1 Z6IN 0 PWM1 0 Z1IN 1 PWM2 0 Z2IN 1 PWM3 0 Z3IN 1 PWM4 0 Z4IN 1 PWM5 0 Z5IN 1 PWM6 0 Z6IN 1 *usleep(1000);* root@wgd:~/dl-i2c-test# nano tst.c root@wgd:~/dl-i2c-test# gcc -Wall -o tst tst.c root@wgd:~/dl-i2c-test# ./tst PWM1 1 Z1IN 0 PWM2 1 Z2IN 0 PWM3 1 Z3IN 0 PWM4 1 Z4IN 0 PWM5 1 Z5IN 0 PWM6 1 Z6IN 0 PWM1 0 Z1IN 1 PWM2 0 Z2IN 1 PWM3 0 Z3IN 1 PWM4 0 Z4IN 1 PWM5 0 Z5IN 1 PWM6 0 Z6IN 1 At this point, I got tired of "hunting and packing", so did not look any further. -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/beagleboard/CALHSORrSTZEcG0Nbh0WeriNxSJij0HPkwoMLkZc0dLZGT%2BqgJA%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
