softpwm only a little change
Fork of SoftPWM by
Diff: SoftPWM.cpp
- Revision:
- 1:6d557e90686e
- Parent:
- 0:7918ce37626c
--- a/SoftPWM.cpp Wed Oct 23 19:31:14 2013 +0000 +++ b/SoftPWM.cpp Fri Dec 15 17:26:23 2017 +0000 @@ -9,7 +9,7 @@ else pulse = 1; positive = _positive; - interval = 0.02; + interval = 0.005; width = 0; start(); } @@ -93,7 +93,7 @@ pulse = 0; else pulse = 1; -// _timeout.detach(); + _timeout.detach();//原库中此句被注释掉 可能是作者认为此语句会占用cpu时间,但事实上注释掉后会在低占空比下消耗cpu时间并产生一些莫名其妙的问题 } ;