College of DuPage Lunabotics Documentation  2025
src.keyboard_teleop Namespace Reference

Functions

def getKey (settings)
 
def saveTerminalSettings ()
 
def restoreTerminalSettings (old_settings)
 
def vels (speed, turn)
 
def main ()
 

Variables

string msg
 
dictionary moveBindings
 
dictionary speedBindings
 
dictionary bladeBindings
 

Function Documentation

◆ getKey()

def src.keyboard_teleop.getKey (   settings)

◆ main()

def src.keyboard_teleop.main ( )

◆ restoreTerminalSettings()

def src.keyboard_teleop.restoreTerminalSettings (   old_settings)

◆ saveTerminalSettings()

def src.keyboard_teleop.saveTerminalSettings ( )

◆ vels()

def src.keyboard_teleop.vels (   speed,
  turn 
)

Variable Documentation

◆ bladeBindings

dictionary src.keyboard_teleop.bladeBindings
Initial value:
1 = {
2  "\x1b[A": -0.025,
3  "\x1b[B": 0.025,
4  "\x1b[D": -0.025,
5  "\x1b[C": 0.025,
6 }

◆ moveBindings

dictionary src.keyboard_teleop.moveBindings
Initial value:
1 = {
2  "w": (1, 0, 0, 0),
3  "s": (-1, 0, 0, 0),
4  "a": (0, 0, 0, 1),
5  "d": (0, 0, 0, -1),
6 }

◆ msg

string src.keyboard_teleop.msg
Initial value:
1 = """
2 ---------------------------
3 Drive around with WASD:
4  w
5  a s d
6 
7 Max speed: 0.75
8 Adjust speed:
9 q : Increase linear speed
10 z : Decrease linear speed
11 e : Increase angular speed
12 c : Decrease angular speed
13 
14 Lift the blade with Up/Down arrows:
15 Up Arrow: Increase position
16 Down Arrow: Decrease position
17 
18 Tilt the blade with Left/Right arrows:
19 Left Arrow: Counter-clockwise
20 Right Arrow: Clockwise
21 
22 CTRL-C to quit
23 """

◆ speedBindings

dictionary src.keyboard_teleop.speedBindings
Initial value:
1 = {
2  "q": (1.1, 1.0),
3  "e": (1.0, 1.1),
4  "z": (0.9, 1.0),
5  "c": (1.0, 0.9),
6 }