How to use the plotink.ebb_serial.command function in plotink

To help you get started, we’ve selected a few plotink examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github evil-mad / plotink / plotink / ebb_motion.py View on Github external
def setPenUpRate(port_name, pen_up_rate):
    if port_name is not None:
        ebb_serial.command(port_name, 'SC,11,{0}\r'.format(pen_up_rate))
        # Set the rate of change of the servo when going up.
github evil-mad / plotink / plotink / ebb_motion.py View on Github external
def setEBBLV(port_name, ebb_lv):
    # Set the EBB "Layer" Variable, an 8-bit number we can read and write.
    # (Unrelated to our plot layers; name is an historical artifact.)
    if port_name is not None:
        ebb_serial.command(port_name, 'SL,{0}\r'.format(ebb_lv))
github evil-mad / plotink / plotink / ebb_motion.py View on Github external
def setPenDownRate(port_name, pen_down_rate):
    if port_name is not None:
        ebb_serial.command(port_name, 'SC,12,{0}\r'.format(pen_down_rate))
        # Set the rate of change of the servo when going down.
github evil-mad / plotink / plotink / ebb_motion.py View on Github external
def setPenUpPos(port_name, servo_min):
    if port_name is not None:
        ebb_serial.command(port_name, 'SC,4,{0}\r'.format(servo_min))
        # servo_min may be in the range 1 to 65535, in units of 83 ns intervals. This sets the "Pen Up" position.
github evil-mad / plotink / plotink / ebb_motion.py View on Github external
def PBOutValue(port_name, pin, state):
    # Set state of the I/O pin. Pin: {0,1,2, or 3}. State: {0 or 1}.
    # Set the pin as an output with OutputPinBConfigure before using this.
    if port_name is not None:
        str_output = 'PO,B,{0},{1}\r'.format(pin, state)
        ebb_serial.command(port_name, str_output)
github evil-mad / plotink / plotink / ebb_motion.py View on Github external
def TogglePen(port_name):
    if port_name is not None:
        ebb_serial.command(port_name, 'TP\r')
github evil-mad / plotink / plotink / ebb_motion.py View on Github external
def sendPenDown(port_name, pen_delay):
    if port_name is not None:
        str_output = 'SP,0,{0}\r'.format(pen_delay)
        ebb_serial.command(port_name, str_output)
github evil-mad / plotink / plotink / ebb_motion.py View on Github external
def doXYMove(port_name, delta_x, delta_y, duration):
    # Move X/Y axes as: "SM,,,"
    # Typically, this is wired up such that axis 1 is the Y axis and axis 2 is the X axis of motion.
    # On EggBot, Axis 1 is the "pen" motor, and Axis 2 is the "egg" motor.
    if port_name is not None:
        str_output = 'SM,{0},{1},{2}\r'.format(duration,delta_y,delta_x)
        ebb_serial.command(port_name, str_output)

plotink

Helper routines for use with plotters

MIT
Latest version published 5 months ago

Package Health Score

61 / 100
Full package analysis

Similar packages