OpenWrt Forum Archive

Topic: How to generate PWM pulse with GPIO on fonera

The content of this topic has been archived on 2 May 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Is possible?

Regards,
Elia

Please... if possible, help me.
My idea is a circuit control for a Fuel Cell to produce HHO in my car.
I see motor stepper controlled by Fonera, but no one explains how.

Regards,
Elia

I use thi script:

#!/bin/sh
g=/proc/gpio/0_out
v=12500
i=0
 
while [ $i != 100 ]
do
i=`expr $i + 1`
 
echo $i
 
echo 1 > $g
usleep $v
echo 0 > $g
usleep $v
 
done

but I can't over 12500usec and nanosleep isn't in firmware, only usleep is present...
... a way to generate PWM?

The discussion might have continued from here.