-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Description
I am trying to set the stanby_current, and although it says that is applied, the power supply shows that the current has not been modified. Its quite strange since the max_current changes correctly. Any idea what I'm doing wrong?
Thanks
from serial import Serial
from time import sleep
import pyTMCL
## serial-address as set on the TMCM module (Check on the TMCL-IDE).
MODULE_ADDRESS = 1
## Open the serial port (Check on the TMCL-IDE)
serial_port = Serial("/dev/tty.usbmodem1241")
## Create a Bus instance using the open serial port
bus = pyTMCL.connect(serial_port)
## Get the motor(ONLY ONE)
motor = bus.get_motor(MODULE_ADDRESS)
## Start of TMCL COMMANDS
motor.axis.stanby_current=200
motor.axis.max_current=230
print(motor.axis.stanby_current)
## Rotate motor left speed 1234 for 2 seconds
motor.rotate_left(1234)
sleep(2)
motor.stop()
## Rotate motor right speed 1234 for 2 seconds
motor.rotate_right(1234)
sleep(2)
motor.stop()
Metadata
Metadata
Assignees
Labels
No labels