-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathsolo8_ISAE.py
More file actions
28 lines (22 loc) · 1.12 KB
/
solo8_ISAE.py
File metadata and controls
28 lines (22 loc) · 1.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
import numpy as np
from utils.abstractRobotHal import RobotHAL
class Solo8(RobotHAL):
''' Define the hardware interface to solo8'''
def __init__(self, interfaceName="", dt=0.001):
RobotHAL.__init__(self, interfaceName, dt)
def InitRobotSpecificParameters(self):
''' Definition of the Solo8 paramters '''
# Robot specific constants***********
self.nb_motors = 8
self.motorToUrdf = [0, 1, 3, 2, 5, 4, 6, 7]
self.gearRatio = np.array(self.nb_motors * [9.,]) # gearbox ratio
self.motorKt = np.array(self.nb_motors * [0.025,]) # Nm/A
self.motorSign = np.array([-1, -1, +1, +1, -1, -1, +1, +1])
self.maximumCurrent = 3.0 # A
# To get this offsets, run the calibration with self.encoderOffsets at 0,
# then manualy move the robot in zero config, and paste the position here (note the negative sign!)
self.encoderOffsets = - \
np.array([1.660367, -2.610352, 2.866129, 1.009784,
0.620769, -1.710268, 2.117314, -4.056512])
#self.encoderOffsets *= 0.
# ***********************************