Пример #1
0
func main() {
	embd.InitLED()
	defer embd.CloseLED()

	embd.LEDOn(3)
	time.Sleep(1 * time.Second)
	embd.LEDOff(3)
}
Пример #2
0
func (b *BeagleBone) LedsCycle(repeat int) {
	b.LedsOff()
	for i := 0; i < repeat; i++ {
		for _, l := range b.LEDs {
			embd.LEDOn(l)
			time.Sleep(50 * time.Millisecond)
			embd.LEDOff(l)
		}
	}
}
Пример #3
0
func (b *BeagleBone) LedsOff() {
	for _, l := range b.LEDs {
		embd.LEDOff(l)
	}
}