Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: Vector3
Revision 21:712076ece407, committed 2022-06-21
- Comitter:
- NaotoMorita
- Date:
- Tue Jun 21 04:59:05 2022 +0000
- Parent:
- 20:efa07b922ba7
- Commit message:
- without verctor3
Changed in this revision
| GPSUBX_UART.cpp | Show annotated file Show diff for this revision Revisions of this file |
| GPSUBX_UART.hpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/GPSUBX_UART.cpp Thu Mar 31 02:15:19 2022 +0000
+++ b/GPSUBX_UART.cpp Tue Jun 21 04:59:05 2022 +0000
@@ -208,12 +208,18 @@
//twelite.printf("%f %f %f \r\n",_n,_e,_d);
}
-void GPSUBX_UART::Calculate()
+void GPSUBX_UART::Calculate(float& posN,float& posE,float& posD,float& velN,float& velE,float& velD)
{
UniversalPosition = ToUniversal();
Vector3 relative = UniversalPosition - UniversalZeroPosition;
Vector3 _position(relative % UniversalZeroUnitN, relative % UniversalZeroUnitE, relative % UniversalZeroUnitD);
PositionNED = _position;
+ posN = _position.x;
+ posE = _position.y;
+ posD = _position.z;
+ velN = VelocityNED.x;
+ velE = VelocityNED.y;
+ velD = VelocityNED.z;
}
Vector3 GPSUBX_UART::Calculate(Vector3 position)
--- a/GPSUBX_UART.hpp Thu Mar 31 02:15:19 2022 +0000
+++ b/GPSUBX_UART.hpp Tue Jun 21 04:59:05 2022 +0000
@@ -242,7 +242,7 @@
void CalculateUnit();
/**call Calculate() before calculating PositionNED
*/
- void Calculate();
+ void Calculate(float& posN,float& posE,float& posD,float& velN,float& velE,float& velD);
Vector3 Calculate(Vector3 position);
static void Checksum(char payload[], int n, char* ck_a, char* ck_b);