Forums › SM Series Discussions › SM200C get NMEA messages
- This topic has 1 reply, 1 voice, and was last updated 2 years, 6 months ago by
Jacks.
- AuthorPosts
JacksParticipant- This topic was modified 2 years, 6 months ago by
Jacks.
Good afternoon!
There is SM200C, we need to receive NMEA messages. Now the SMGetGPSInfo function returns the coordinates and height, respectively, the gps works. But there is no data in the NMEA messages, i.e. the array is not filled, although the size is clearly changing.
What could be the problem?
We think that problems can be of the following type:
1. NMEA messages are disabled by default. And then they need to be turned on. How?
2. Some problems with api. We use C#, and everything is done according to the examples from C++, and before that there were no problems.
JacksParticipantAnswer to my question.
This was a bad example for C# in API. More precisely, the wrong import of the library. Correct like this:
[DllImport(DLL_NAME_Win32, EntryPoint = “smGetGPSInfo”, CallingConvention = CallingConvention.Cdecl)]
private static extern SmStatus smGetGPSInfo_Win32(int device, SmBool refresh,
ref SmBool updated, ref long secSinceEpoch, ref double latitude,
ref double longitude, ref double altitude, [Out] char[] nmea, ref int nmeaLen);- This topic was modified 2 years, 6 months ago by
- AuthorPosts
You must be logged in to reply to this topic.