Documentation
¶
Index ¶
Constants ¶
View Source
const ( // MaxPeriod is the maximum period a PWM can have MaxPeriod = maxPeriodNanoSec * time.Nanosecond // MinPeriod is the minimum period a PWM can have MinPeriod = minPeriodNanoSec * time.Nanosecond )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Pwm ¶
type Pwm struct {
// contains filtered or unexported fields
}
Pwm is a pulse width modulation output driver
func New ¶
New returns a new PWM for a given pwmID - See Edison Breakout documentation to figure out which one you want.
func (Pwm) IsExported ¶
IsExported returns true with the pwm is already exported and usable from sysfs.
func (*Pwm) SetPeriodAndDutyCycle ¶
SetPeriodAndDutyCycle configures the pwm for a given period and duty cycle ratio. Note this might go through a transient state if the pwm is Enabled
Click to show internal directories.
Click to hide internal directories.