/Designs/ROBOTS/TEFO01A/SW/TEFO_motor_test.py
27,9 → 27,10
# spi.SPI_write_byte(self.CS, 0xFF)
# spi.SPI_write_byte(self.CS, 0x13) # Over Current Treshold setup
# spi.SPI_write_byte(self.CS, 0xFF)
#spi.SPI_write_byte(self.CS, 0x15) # Full Step speed
#spi.SPI_write_byte(self.CS, 0x00)
#spi.SPI_write_byte(self.CS, 0x30)
spi.SPI_write_byte(self.CS, 0x15) # Full Step speed
spi.SPI_write_byte(self.CS, 0x00)
spi.SPI_write_byte(self.CS, 0xF0)
spi.SPI_write_byte(self.CS, 0x09) # KVAL_HOLD
spi.SPI_write_byte(self.CS, 0xFF)
 
39,9 → 40,9
spi.SPI_write_byte(self.CS, 0x0B) # KVAL_ACC
spi.SPI_write_byte(self.CS, 0xFF)
 
spi.SPI_write_byte(self.CS, 0x18) # Config register
spi.SPI_write_byte(self.CS, 0b11000000)
spi.SPI_write_byte(self.CS, 0x88)
# spi.SPI_write_byte(self.CS, 0x18) # Config register
# spi.SPI_write_byte(self.CS, 0b11000000)
# spi.SPI_write_byte(self.CS, 0x88)
def MaxSpeed(self, speed):
' Setup of maximum speed '