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

Reference point HITL simulation #640

Closed
wants to merge 5 commits into from

Conversation

softsr
Copy link
Contributor

@softsr softsr commented Feb 16, 2014

This simulation is working on the rotorcrafts autopilot side (does not need any external data over telemetry), simulates the full behaviour of the AP in HOVER and NAV hotizontal (vertical) modes (assuming reference generation usage). Allows to fully simulate the flightplan with any extra modules/devices connected to the AP.
To turn it on, simply change in your airframe setup file the gps and ins subsystems to "sim_hitl":

@flixr
Copy link
Member

flixr commented Feb 16, 2014

Why have a ins_sim_hitl subsystem which is the same as just ins.makefile?
Also why use ins_int if you proceed to disable the baro and the vff? Would make more sense to use the ins_gps_passthrough in this case.

And could you please add the usual license/author/doxygen file header including brief and detailed description to gps_sim_hitl.

Maybe we can also find a more fitting name than HITL for this...

@softsr
Copy link
Contributor Author

softsr commented Feb 16, 2014

ins_sim_hitl has extra DUSE_HFF=0 flag set. But actually it coud just be used SIM_HITL define.
Is it possible to calculate UTM from NED using only state interface? I can't find any function returning local UTM origin.

@softsr
Copy link
Contributor Author

softsr commented Feb 16, 2014

Moreover ins_gps_passthrough is currently made only for fixedwings

@flixr
Copy link
Member

flixr commented Feb 16, 2014

Well, supplying -DUSE_HFF=0 has the same effect as not supplying it at all.... so no need for it.

It would make a lot more sense to update ins_gps_passthrough to also set the missing state variables for rotorcrafts, than using ins_int and proceeding to disable/overwrite everything it actually does...

See http://docs.paparazziuav.org/latest/group__state__position.html for getting the current position (e.g. as UTM representation) from state interface.
If want to convert some arbitrary other NED position to UTM, you can use e.g. UTM_OF_NED_ADD(utm_pos_f, ned_pos_f, ned_origin_in_utm_f)

@softsr
Copy link
Contributor Author

softsr commented Feb 16, 2014

Do you mean to move the ins_gps_passthrough to shared directory?
I would rather hold the rotorcrafts default ecef coordinates with extra ins_impl.ltp_def variable. So then the code in ins_gps_passthrough need to be separated to rotorcraft and fixedwing parts by defines.

@softsr softsr closed this Feb 16, 2014
@softsr
Copy link
Contributor Author

softsr commented Feb 16, 2014

It would probably be better to create an extra ins_gps_passthrough subsystem for the rotorcraft code.

@softsr softsr reopened this Feb 16, 2014
@flixr flixr added this to the v5.2 milestone Apr 5, 2014
@flixr
Copy link
Member

flixr commented Apr 5, 2014

Should now work in master with 2446fc0 and 7745958
@softsr could you please check if it work with ins gps_passthrough

@softsr
Copy link
Contributor Author

softsr commented Apr 12, 2014

@flixr it works with both commits, choosing sim_hitl for gps subsystem and gps_passthrough for ins.

@flixr
Copy link
Member

flixr commented Apr 12, 2014

Great, thanks for checking again.

@flixr flixr closed this Apr 12, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants