Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Volz on AP_Periph #29058

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

peterbarker
Copy link
Contributor

Based on #29040

Adds an autotest which tests Volz-on-periph

  • creates a separate AP_Periph build with relevant support compiled in
  • creates a custom Plane build with appropriate options compiled in
  • starts the simulations

The Periph firmware receives data via ArrayCommand.

The main Plane firmware receives telemetry data back from the peripheral via com_volz_servo_ActuatorStatus

At the moment there's no connection of the desired value sent by the autopilot and the achieved angle returned by the periph (and logged into CSRV. There's no facility in the return packet for the desired value.

@IamPete1
Copy link
Member

I do have a branch for this somewhere, I did it in a similar way as you have sending the volz DroneCAN packet. Now we have the servo telem lib I wonder if we should do it using the standard DroneCAN packet. I think as you have it it doesn't actually have to be a volz servo that is reported because it is reading out of the servo telem lib (of course we might need to add support for other servo types on periph to populate that).

That is to say, should we split that addition of the volz support and then the reporting of servo telem such that they can be used independently.

@peterbarker
Copy link
Contributor Author

That is to say, should we split that addition of the volz support and then the reporting of servo telem such that they can be used independently.

Yeah, I haven't split the commits in here to allow that, but did write things with an eye to allow for differently-attached servos. OTOH, I did choose to send back the volz feedback message rather than the generic feedback message here to get the extra fields (which I think is probably a mistake, and both packets are... not good).

There's several big holes here, the most notable being logging on the main flight controller for the serially-attached servos on the peripheral. You can't sensibly log anything in the CSRV[x].PosCmd field for the data coming back from the peripheral! I think we need a companion for the uavcan_equipment_actuator_ArrayCommand message, perhaps uavcan_equipment_actuator_ArrayResponse which we can use to properly populate CSRV

(as an aside, it would nice to rename PosCmd to DesPos to match other messages ;-) )

@IamPete1
Copy link
Member

Its interesting the three DroneCAN reporting messages we support all have different data. Its also worth noting that now were going into the servo telem lib on the vehicle side we do loose some information from volz anyway. We could send back the secondary voltage and current for example, but its not implemented in the servo telem lib (we did log it for local servos prior to the merging of libs).

Out of the three the harmark one if probably the nicest, there is no reason we couldn't use it rather than the standard one I guess...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants