feat: add j3,j4,j5
This commit is contained in:
+51
-12
@@ -27,22 +27,61 @@ MainLoop::MainLoop() noexcept:
|
|||||||
-38.0,
|
-38.0,
|
||||||
85.0,
|
85.0,
|
||||||
180.0,
|
180.0,
|
||||||
50,
|
0,
|
||||||
172,
|
172,
|
||||||
565
|
565
|
||||||
),
|
),
|
||||||
AdafruitServoMotor(
|
AdafruitServoMotor(
|
||||||
pwmBoard,
|
pwmBoard,
|
||||||
2,
|
2, // index
|
||||||
1.0,
|
1.0, // gearbox
|
||||||
1.0,
|
1.0, // scale calibration
|
||||||
123.0,
|
40.0, // zero offset
|
||||||
-123.0,
|
-90.0, // min
|
||||||
57.0,
|
90.0, // max
|
||||||
180.0,
|
180.0, // spec range
|
||||||
-123,
|
0, // initial pos
|
||||||
172,
|
172, // min pulse
|
||||||
565
|
565 // max pulse
|
||||||
|
),
|
||||||
|
AdafruitServoMotor(
|
||||||
|
pwmBoard,
|
||||||
|
3, // index
|
||||||
|
1.0, // gearbox
|
||||||
|
1.0, // scale calibration
|
||||||
|
90.0, // zero offset
|
||||||
|
-90.0, // min
|
||||||
|
90.0, // max
|
||||||
|
180.0, // spec range
|
||||||
|
0, // initial pos
|
||||||
|
80, // min pulse
|
||||||
|
600 // max pulse
|
||||||
|
),
|
||||||
|
AdafruitServoMotor(
|
||||||
|
pwmBoard,
|
||||||
|
4, // index
|
||||||
|
1.0, // gearbox
|
||||||
|
1.0, // scale calibration
|
||||||
|
90.0, // zero offset
|
||||||
|
-90.0, // min
|
||||||
|
90.0, // max
|
||||||
|
180.0, // spec range
|
||||||
|
0, // initial pos
|
||||||
|
80, // min pulse
|
||||||
|
600 // max pulse
|
||||||
|
),
|
||||||
|
AdafruitServoMotor(
|
||||||
|
pwmBoard,
|
||||||
|
5, // index
|
||||||
|
1.0, // gearbox
|
||||||
|
1.0, // scale calibration
|
||||||
|
90.0, // zero offset
|
||||||
|
-90.0, // min
|
||||||
|
90.0, // max
|
||||||
|
180.0, // spec range
|
||||||
|
0, // initial pos
|
||||||
|
80, // min pulse
|
||||||
|
600 // max pulse
|
||||||
),
|
),
|
||||||
})
|
})
|
||||||
{
|
{
|
||||||
@@ -65,7 +104,7 @@ MainLoop& MainLoop::getInstance() noexcept
|
|||||||
void MainLoop::setup() noexcept
|
void MainLoop::setup() noexcept
|
||||||
{
|
{
|
||||||
UartHandler::getInstance().init(9600);
|
UartHandler::getInstance().init(9600);
|
||||||
for (uint8_t i = 0; i < 3; i++) {
|
for (uint8_t i = 0; i < 5; i++) {
|
||||||
motors[i].commitMoveImmediately();
|
motors[i].commitMoveImmediately();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -20,5 +20,5 @@ class MainLoop
|
|||||||
~MainLoop() noexcept;
|
~MainLoop() noexcept;
|
||||||
|
|
||||||
AdafruitPWMBoard pwmBoard;
|
AdafruitPWMBoard pwmBoard;
|
||||||
AdafruitServoMotor motors[3];
|
AdafruitServoMotor motors[6];
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user