Created
April 11, 2012 10:17
-
-
Save akshar100/2358416 to your computer and use it in GitHub Desktop.
Xbee and Python
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def init(port): | |
import zigbee; | |
zigbee.init(port); | |
def forward(): | |
import zigbee; | |
zigbee.sendString("a"); | |
def stop(): | |
import zigbee; | |
zigbee.sendString(" "); | |
def backward(): | |
import zigbee; | |
zigbee.sendString("s"); | |
def left(): | |
import zigbee; | |
zigbee.sendString("a"); | |
def right(): | |
import zigbee; | |
zigbee.sendString("d"); | |
def buzzer_on(): | |
import zigbee; | |
zigbee.sendString("h"); | |
def buzzer_off(): | |
import zigbee; | |
zigbee.sendString("m"); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment