Sming Framework API
Sming - Open Source framework for high efficiency WiFi SoC ESP8266 native development with C++ language.
Servo Class Reference

Public Member Functions

 Servo ()
 Instantiate servo object
public global instance of Servo is available as variable servo
no additional instance is allowed because ServoChannel instances use servo. More...
 
bool addChannel (ServoChannel *channel)
 add a servo channel to the servo object
locks interrupt to change configuration without timing problem, may result in a chort glitch More...
 
bool removeChannel (ServoChannel *channel)
 remove a servo channel from the servo object
locks interrupt to change configuration without timing problem, may result in a chort glitch More...
 
void calcTiming ()
 calculation of all the internal timings
has to be called when min of max is changed and setDegree is used More...
 

Constructor & Destructor Documentation

Servo::Servo ( )

Instantiate servo object
public global instance of Servo is available as variable servo
no additional instance is allowed because ServoChannel instances use servo.

Member Function Documentation

bool Servo::addChannel ( ServoChannel channel)

add a servo channel to the servo object
locks interrupt to change configuration without timing problem, may result in a chort glitch

Parameters
channelpointer to the servo channel object
Return values
boolTrue on success
void Servo::calcTiming ( )

calculation of all the internal timings
has to be called when min of max is changed and setDegree is used

bool Servo::removeChannel ( ServoChannel channel)

remove a servo channel from the servo object
locks interrupt to change configuration without timing problem, may result in a chort glitch

Parameters
channelpointer to the servo channel object
Return values
boolTrue on success