implement cannode hardpoint commands#26334
Conversation
Signed-off-by: dirksavage88 <dirksavage88@gmail.com>
|
|
||
| config UAVCANNODE_HARDPOINT_COMMAND | ||
| bool "Include hardpoint commands" | ||
| default n |
There was a problem hiding this comment.
do we want to enable it on any board?
There was a problem hiding this comment.
Yes, I have been testing on the ark cannode. It seems to have enough flash onboard
There was a problem hiding this comment.
added to the ark cannode
|
|
||
| } // end else | ||
|
|
||
| } // end else |
There was a problem hiding this comment.
instead of separate if/else blocks with duplicate logic you could instead get clever with the for loop, when it's broadcast you set the bounds from 0 to actuator_servos_s::NUM_CONTROLS and when it's targeted you'd set the bounds from servo_id to servo_id+1 (therefore the loop starts at the servo_id and ends immediately after)
There was a problem hiding this comment.
I made some changes to hopefully simplify
Co-authored-by: Jacob Dahl <37091262+dakejahl@users.noreply.github.com>
Co-authored-by: Jacob Dahl <37091262+dakejahl@users.noreply.github.com>
|
I assume this will need docs? |
…dcast Signed-off-by: dirksavage88 <dirksavage88@gmail.com>
|
@dakejahl the hardpoint id is never set in the payload deliverer module. According to mavlink spec, hardpoint id of 0 is broadcast. and that is what I am seeing as the default as it is never explicitly set (param1): Mavlink spec for gripper: https://mavlink.io/en/messages/common.html#MAV_CMD_DO_GRIPPER |
Yes, there are no docs currently on hardpoint via dronecan |
|
@alexcekay would you mind looking this over? I think Jacob Dahl is on vacation. |
@dirksavage88 Great. I will leave for you to create and I will subedit. So "hardpoint" means "autopilot-connected" with a specific identity? |
Solved Problem
UAVCANNODE in px4 does not handle the hardpoint commands currently, only servo and motor array commands
Solution
Create a separate hardpoint command subscriber in the cannode driver
Changelog Entry
For release notes:
Alternatives
Test coverage
Context