csp; dg x=60 y=5 w=200 h=3 c=0,0,100 ga=h gd=s gi=5; dt a=c x=160 y=10 t="PWM generator" f=18b; dg x=60 y=30 w=200 h=3 c=0,0,100 ga=h gd=s gi=5; db x=80 y=38 c=0,0,100 w=77 h=40 t="Init" a="PWM i=1"; db x=158 y=38 c=0,0,100 w=77 h=40 t="Disable" a="G8 m=d"; dt x=160 y=83 t="Parameters" bw=300 a=c ld=l; db x=4 y=99 c=0,0,100 w=77 h=40 t="Set T1" a="PWM t1=%s"; db x=82 y=99 c=0,0,100 w=77 h=40 t="Set T2" a="PWM t2=%s"; db x=160 y=99 c=0,0,100 w=77 h=40 t="Set DC" a="PWM dc=%d+es id=0 v=%_"; db x=238 y=99 c=0,0,100 w=77 h=40 t="Set rate(Hz)" a="PWM r=%dHz"; dt x=44 y=154 t="Polarity" bw=70 a=c ld=l; dc x=4 y=172 w=80 h=40 ta="PWM p=1" ua="PWM p=0" t="Inverted" is=100 ot=1 bc=40,40,40 utc=60,60,60 to=c id=0; dt x=225 y=154 bw=170 t="Lock parameter" a=c ld=l; dc x=135 y=172 w=60 h=40 ta="PWM l=r+ec id=2 s=0+ec id=3 s=0" ua="PWM l=n" t="Rate" is=100 ot=1 bc=40,40,40 utc=60,60,60 to=c id=1; dc x=195 y=172 w=60 h=40 ta="PWM l=t1+ec id=1 s=0+ec id=3 s=0" ua="PWM l=n" t="T1" is=100 ot=1 bc=40,40,40 utc=60,60,60 to=c id=2; dc x=255 y=172 w=60 h=40 ta="PWM l=t2+ec id=1 s=0+ec id=2 s=0" ua="PWM l=n" t="T2" is=100 ot=1 bc=40,40,40 utc=60,60,60 to=c id=3; dt x=44 y=232 bw=70 t="Update lock" a=c ld=l; dc x=4 y=248 w=80 h=40 ta="PWM ul=1" ua="PWM ul=0" t="Locked" is=100 ot=1 bc=40,40,40 utc=60,60,60 to=c; dt x=225 y=232 bw=170 t="Idle state (low=default)" a=c ld=l; dc x=135 y=248 w=60 h=40 ta="PWM is=hiz+ec id=6 s=0+ec id=7 s=0" ua="PWM is=low+ec id=6 s=1" t="Hi-z" is=100 ot=1 bc=40,40,40 utc=60,60,60 to=c id=5; dc x=195 y=248 w=60 h=40 ta="PWM is=low+ec id=5 s=0+ec id=7 s=0" ua="PWM is=low+ec id=6 s=1" t="Low" is=100 ot=1 s=1 bc=40,40,40 utc=60,60,60 to=c id=6; dc x=255 y=248 w=60 h=40 ta="PWM is=high+ec id=5 s=0+ec id=6 s=0" ua="PWM is=low+ec id=6 s=1" t="High" is=100 ot=1 bc=40,40,40 utc=60,60,60 to=c id=7; dt x=160 y=300 t="Duty cycle" bw=300 a=c ld=l; ds x=4 y=316 w=312 h=40 a="PWM dc=%d" min=0 max=100 v=50 id=0; dt x=160 y=404 bw=300 t="Start/stop" a=c ld=l; db x=4 y=420 c=0,0,100 w=109 h=40 t="Start continuous" a="PWM os=0 cc=1"; db x=114 y=420 c=0,0,100 w=109 h=40 t="Start one-shot" a="PWM cc=0 os=1"; db x=224 y=420 c=0,0,100 w=90 h=40 t="Stop" a="PWM os=0 cc=0"; dg x=10 y=463 w=300 h=1 c=50,50,50; df x=0 y=465 w=320 h=15 ft=vo pm="%s\r\n";