Skip to content

Commit

Permalink
[modules] digital_cam: replace course by psi in DC_SHOT
Browse files Browse the repository at this point in the history
  • Loading branch information
flixr committed Dec 3, 2014
1 parent e9a87ab commit 5a3a4e2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion conf/messages.xml
Expand Up @@ -913,7 +913,7 @@
<field name="alt" type="int32" unit="mm" alt_unit="m"/>
<field name="phi" type="int16" unit="decideg"/>
<field name="theta" type="int16" unit="decideg"/>
<field name="course" type="int16" unit="decideg"/>
<field name="psi" type="int16" unit="decideg"/>
<field name="speed" type="uint16" unit="cm/s"/>
<field name="itow" type="uint32" unit="ms"/>
</message>
Expand Down
6 changes: 3 additions & 3 deletions sw/airborne/modules/digital_cam/dc.c
Expand Up @@ -94,10 +94,10 @@ uint16_t dc_photo_nr = 0;

void dc_send_shot_position(void)
{
// angles in decideg
int16_t phi = DegOfRad(stateGetNedToBodyEulers_f()->phi*10.0f);
int16_t theta = DegOfRad(stateGetNedToBodyEulers_f()->theta*10.0f);
// course in decideg
int16_t course = DegOfRad(*stateGetHorizontalSpeedDir_f()) * 10;
int16_t psi = DegOfRad(stateGetNedToBodyEulers_f()->psi*10.0f);
// ground speed in cm/s
uint16_t speed = (*stateGetHorizontalSpeedNorm_f()) * 10;
int16_t photo_nr = -1;
Expand All @@ -114,7 +114,7 @@ void dc_send_shot_position(void)
&stateGetPositionLla_i()->alt,
&phi,
&theta,
&course,
&psi,
&speed,
&gps.tow);
}
Expand Down

0 comments on commit 5a3a4e2

Please sign in to comment.