Documentation ¶
Overview ¶
Package edison contains the Gobot adaptor for the Intel Edison.
For further information refer to intel-iot README: https://github.com/hybridgroup/gobot/blob/master/platforms/intel-iot/edison/README.md
Index ¶
- type EdisonAdaptor
- func (e *EdisonAdaptor) AnalogRead(pin string) (val int, err error)
- func (e *EdisonAdaptor) Connect() (errs []error)
- func (e *EdisonAdaptor) DigitalRead(pin string) (i int, err error)
- func (e *EdisonAdaptor) DigitalWrite(pin string, val byte) (err error)
- func (e *EdisonAdaptor) Finalize() (errs []error)
- func (e *EdisonAdaptor) I2cRead(size uint) (data []byte, err error)
- func (e *EdisonAdaptor) I2cStart(address byte) (err error)
- func (e *EdisonAdaptor) I2cWrite(data []byte) (err error)
- func (e *EdisonAdaptor) Name() string
- func (e *EdisonAdaptor) PwmWrite(pin string, val byte) (err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EdisonAdaptor ¶
type EdisonAdaptor struct {
// contains filtered or unexported fields
}
EdisonAdaptor represents an Intel Edison
func NewEdisonAdaptor ¶
func NewEdisonAdaptor(name string) *EdisonAdaptor
NewEdisonAdaptor returns a new EdisonAdaptor with specified name
func (*EdisonAdaptor) AnalogRead ¶
func (e *EdisonAdaptor) AnalogRead(pin string) (val int, err error)
AnalogRead returns value from analog reading of specified pin
func (*EdisonAdaptor) Connect ¶
func (e *EdisonAdaptor) Connect() (errs []error)
Connect initializes the Edison for use with the Arduino beakout board
func (*EdisonAdaptor) DigitalRead ¶
func (e *EdisonAdaptor) DigitalRead(pin string) (i int, err error)
DigitalRead reads digital value from pin
func (*EdisonAdaptor) DigitalWrite ¶
func (e *EdisonAdaptor) DigitalWrite(pin string, val byte) (err error)
DigitalWrite writes a value to the pin. Acceptable values are 1 or 0.
func (*EdisonAdaptor) Finalize ¶
func (e *EdisonAdaptor) Finalize() (errs []error)
Finalize releases all i2c devices and exported analog, digital, pwm pins.
func (*EdisonAdaptor) I2cRead ¶
func (e *EdisonAdaptor) I2cRead(size uint) (data []byte, err error)
I2cRead returns size bytes from the i2c device
func (*EdisonAdaptor) I2cStart ¶
func (e *EdisonAdaptor) I2cStart(address byte) (err error)
I2cStart initializes i2c device for addresss
func (*EdisonAdaptor) I2cWrite ¶
func (e *EdisonAdaptor) I2cWrite(data []byte) (err error)
I2cWrite writes data to i2c device
func (*EdisonAdaptor) Name ¶
func (e *EdisonAdaptor) Name() string
Name returns the EdisonAdaptors name