mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-06-30 02:52:04 +08:00
params put in locationd async (#20713)
* params put in locationd async * remove reference in thread call old-commit-hash: ed8acfa28447472c282c1c94c929ababb4632305
This commit is contained in:
@@ -365,7 +365,10 @@ int Localizer::locationd_thread() {
|
||||
VectorXd posGeo = this->get_position_geodetic();
|
||||
std::string lastGPSPosJSON = util::string_format(
|
||||
"{\"latitude\": %.15f, \"longitude\": %.15f, \"altitude\": %.15f}", posGeo(0), posGeo(1), posGeo(2));
|
||||
params.put("LastGPSPosition", lastGPSPosJSON); // TODO write async
|
||||
|
||||
std::thread([¶ms] (const std::string gpsjson) {
|
||||
params.put("LastGPSPosition", gpsjson);
|
||||
}, lastGPSPosJSON).detach();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user