Esempio n. 1
0
def check_previous_data(mount):
    old_id = driver.read_pipette_id(mount)
    old_model = driver.read_pipette_model(mount)
    if old_id and old_model:
        print('Overwriting old data: id={0}, model={1}'.format(
            old_id, old_model))
    else:
        print('No old data on this pipette')
Esempio n. 2
0
def write_identifiers(mount, new_id, new_model):
    '''
    Send a bytearray to the specified mount, so that Smoothieware can
    save the bytes to the pipette's memory
    '''
    driver.write_pipette_id(mount, new_id)
    read_id = driver.read_pipette_id(mount)
    _assert_the_same(new_id, read_id)
    driver.write_pipette_model(mount, new_model)
    read_model = driver.read_pipette_model(mount)
    _assert_the_same(new_model, read_model)