So, same kernel but RT PREEMPT enabled. The only code that's changed: sleep(.2); printf("PWM1 %u Z1IN %u\n", !!(*gpio0_out & PWM1), !!(*gpio1_in & Z1IN)); printf("PWM2 %u Z2IN %u\n", !!(*gpio0_out & PWM2), !!(*gpio1_in & Z2IN)); printf("PWM3 %u Z3IN %u\n", !!(*gpio1_out & PWM3), !!(*gpio1_in & Z3IN)); printf("PWM4 %u Z4IN %u\n", !!(*gpio0_out & PWM4), !!(*gpio1_in & Z4IN)); printf("PWM5 %u Z5IN %u\n", !!(*gpio1_out & PWM5), !!(*gpio1_in & Z5IN)); printf("PWM6 %u Z6IN %u\n", !!(*gpio0_out & PWM6), !!(*gpio1_in & Z6IN)); printf("\n"); *gpio0_out &= ~(PWM1 + PWM2 + PWM4 + PWM6); *gpio1_out &= ~(PWM3 + PWM5); sleep(.2); printf("PWM1 %u Z1IN %u\n", !!(*gpio0_out & PWM1), !!(*gpio1_in & Z1IN)); printf("PWM2 %u Z2IN %u\n", !!(*gpio0_out & PWM2), !!(*gpio1_in & Z2IN)); printf("PWM3 %u Z3IN %u\n", !!(*gpio1_out & PWM3), !!(*gpio1_in & Z3IN)); printf("PWM4 %u Z4IN %u\n", !!(*gpio0_out & PWM4), !!(*gpio1_in & Z4IN)); printf("PWM5 %u Z5IN %u\n", !!(*gpio1_out & PWM5), !!(*gpio1_in & Z5IN)); printf("PWM6 %u Z6IN %u\n", !!(*gpio0_out & PWM6), !!(*gpio1_in & Z6IN));
sleep(.2); For those of you who do not know what !! is. Think of it as a double NOT being used as a shorthand for a ternary conditional check. Anyway. . . 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 0 PWM2 0 Z2IN 1 PWM3 0 Z3IN 1 PWM4 0 Z4IN 1 PWM5 0 Z5IN 1 PWM6 0 Z6IN 1 root@wgd:~/dl-i2c-test# uname -r 4.4.55-ti-rt-r94 So what seems to be happening to me is this: There is a lazy check *somewhere* in the kernel, or kernel module code for the gpio driver(s) when changing the state of an input pin. Of course that's an assumption. After thinking about this for a long time last night, This could be one of many things. Possibly even more than one thing. It could possibly even be *something* else slowing down the input pin updating. I am using a DS18B20 1-wire temperature sensor, which since 1-wire is technically power, ground, and a GPIO data pin . . . Maybe 1-wire could potentially be interfering or slowing down the systems GPI's ? That's a pretty "thin" guess, but I suppose possible ? -- 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 beagleboard+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/beagleboard/54447544-6dee-4746-bff4-891e2918e960%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.