Open eduncan911 opened 7 years ago
Ok, looking at the source it looks like you created the constants:
// Command values supported by GoPiGo.
const (
usCmd = 117 // Read the distance from the ultrasonic sensor
)
// Left turns GoPiGo left slowly.
func (p *GoPiGo) Left() error {
p.mu.Lock()
defer p.mu.Unlock()
return p.sendCmd(cmdValues(leftCmd))
}
But...
1) you kept the conts private, not able to be re-used.
2) you kept the sendCmd()
private as well, not able to be re-used.
Do you plan on extending the library to read the ultrasonic sensor and other sensors, such a the line sensor?
How would one read sensors and act upon them?
What about measuring steps of the encoders on the GoPiGo board?
Bonus points for how to use other bits of the raspberry pi GPIO pins along side the GoPiGo board.