<s> """<STR_LIT>""" <EOL> import math <EOL> from DobotDriver import DobotDriver <EOL> driver = DobotDriver ( '<STR_LIT>' , <NUM_LIT> ) <EOL> driver . Open ( ) <EOL> offsets = ( <NUM_LIT> , <NUM_LIT> ) <EOL> def toEndEffectorHeight ( rear , fore ) : <EOL> return <NUM_LIT> - <NUM_LIT> * math . sin ( fore ) + <NUM_LIT> * math . sin ( rear ) <EOL> while True : <EOL> ret = driver . GetAccelerometers ( ) <EOL> if ret [ <NUM_LIT:0> ] : <EOL> print "<STR_LIT>" . format ( driver . accelToAngle ( ret [ <NUM_LIT:1> ] , offsets [ <NUM_LIT:0> ] ) , driver . accelToAngle ( ret [ <NUM_LIT:2> ] , offsets [ <NUM_LIT:1> ] ) , toEndEffectorHeight ( driver . accelToRadians ( ret [ <NUM_LIT:1> ] , offsets [ <NUM_LIT:0> ] ) , driver . accelToRadians ( ret [ <NUM_LIT:2> ] , offsets [ <NUM_LIT:1> ] ) ) , ret [ <NUM_LIT:1> ] , ret [ <NUM_LIT:2> ] ) <EOL> else : <EOL> print '<STR_LIT>' </s>
