[go: nahoru, domu]

Skip to content

Commit

Permalink
Merge pull request #6569 from cyberbotics/sync-released-0c0e31c77
Browse files Browse the repository at this point in the history
Merge released into master
  • Loading branch information
omichel committed Jul 1, 2024
2 parents 69681a9 + 006a6b7 commit c2ea36b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/reference/compass.md
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ Now if the [Compass](#compass) node is in *upright* position, meaning that its z
double get_bearing_in_degrees() {
const double *north = wb_compass_get_values(tag);
double rad = atan2(north[1], north[0]);
double bearing = (rad - 1.5708) / M_PI * 180.0;
double bearing = (rad / M_PI) * 180.0;
if (bearing < 0.0)
bearing = bearing + 360.0;
return bearing;
Expand Down

0 comments on commit c2ea36b

Please sign in to comment.