Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Sphero Go

Sphero Go

Zombie robot hack night: http://edmontongo.org/2014-08/

Nathan Youngman

August 25, 2014
Tweet

More Decks by Nathan Youngman

Other Decks in Technology

Transcript

  1. Channels Make a channel
 channel := make(chan int) Take a

    value from the channel
 num := <- channel Check if channel is closed
 num, ok := <- channel Tick returns a channel
 channel := time.Tick(1 * time.Second)
  2. Select Wait on multiple channels
 select {
 case <-ticker:
 /

    / do this
 case event := <-robot.Events:
 / / do that
 }