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: net lpc1768 crypto clock web log
web-derived/nmea/web-nmea-ajax.c@55:a1bd0572c8b6, 2019-04-28 (annotated)
- Committer:
- andrewboyson
- Date:
- Sun Apr 28 08:31:50 2019 +0000
- Revision:
- 55:a1bd0572c8b6
- Parent:
- http-derived/nmea/http-nmea-ajax.c@49:115a5e4fac0c
- Child:
- 58:3f3e000151cc
Update web-base library and renamed http-derived to web-derived
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| andrewboyson | 48:9f1ab7784067 | 1 | #include <stdint.h> |
| andrewboyson | 48:9f1ab7784067 | 2 | #include <stdio.h> |
| andrewboyson | 48:9f1ab7784067 | 3 | |
| andrewboyson | 48:9f1ab7784067 | 4 | #include "http.h" |
| andrewboyson | 55:a1bd0572c8b6 | 5 | #include "web-base.h" |
| andrewboyson | 48:9f1ab7784067 | 6 | #include "gps.h" |
| andrewboyson | 48:9f1ab7784067 | 7 | #include "nmea.h" |
| andrewboyson | 48:9f1ab7784067 | 8 | #include "settings.h" |
| andrewboyson | 48:9f1ab7784067 | 9 | |
| andrewboyson | 55:a1bd0572c8b6 | 10 | void WebNmeaAjax() |
| andrewboyson | 48:9f1ab7784067 | 11 | { |
| andrewboyson | 48:9f1ab7784067 | 12 | HttpOk("text/plain; charset=UTF-8", "no-cache", NULL, NULL); |
| andrewboyson | 48:9f1ab7784067 | 13 | |
| andrewboyson | 48:9f1ab7784067 | 14 | char nibble; |
| andrewboyson | 48:9f1ab7784067 | 15 | |
| andrewboyson | 48:9f1ab7784067 | 16 | nibble = 0; |
| andrewboyson | 48:9f1ab7784067 | 17 | if (GpsTrace ) nibble |= 1; // 0 |
| andrewboyson | 48:9f1ab7784067 | 18 | if (GpsVerbose ) nibble |= 2; // 0 |
| andrewboyson | 48:9f1ab7784067 | 19 | if (NmeaMsgTrace) nibble |= 4; // 0 |
| andrewboyson | 48:9f1ab7784067 | 20 | if (NmeaCmdTrace) nibble |= 8; // 0 |
| andrewboyson | 48:9f1ab7784067 | 21 | HttpAddNibbleAsHex(nibble); |
| andrewboyson | 48:9f1ab7784067 | 22 | |
| andrewboyson | 48:9f1ab7784067 | 23 | HttpAddInt32AsHex(NmeaLatAv); // 1 |
| andrewboyson | 48:9f1ab7784067 | 24 | HttpAddInt32AsHex(NmeaLngAv); // 9 |
| andrewboyson | 48:9f1ab7784067 | 25 | HttpAddInt32AsHex(NmeaHgtAv); //17 |
| andrewboyson | 48:9f1ab7784067 | 26 | |
| andrewboyson | 48:9f1ab7784067 | 27 | HttpAddInt32AsHex(NmeaHeightDevAboveMslAv); //25 |
| andrewboyson | 48:9f1ab7784067 | 28 | |
| andrewboyson | 49:115a5e4fac0c | 29 | HttpAddInt32AsHex(NmeaHeightMslAboveWgs); //33 |
| andrewboyson | 49:115a5e4fac0c | 30 | HttpAddInt32AsHex(NmeaDop); //41 |
| andrewboyson | 49:115a5e4fac0c | 31 | HttpAddInt32AsHex(NmeaSatelliteCount); //49 |
| andrewboyson | 49:115a5e4fac0c | 32 | HttpAddInt32AsHex(NmeaFixQuality); //57 |
| andrewboyson | 49:115a5e4fac0c | 33 | HttpAddInt32AsHex(GetSensorHeight()); //65 |
| andrewboyson | 48:9f1ab7784067 | 34 | |
| andrewboyson | 49:115a5e4fac0c | 35 | HttpAddInt32AsHex(NmeaTimeBucketGetSize()); //73 |
| andrewboyson | 49:115a5e4fac0c | 36 | for (int i = 0; i < NmeaTimeBucketGetSize(); i++) //81 |
| andrewboyson | 48:9f1ab7784067 | 37 | { |
| andrewboyson | 48:9f1ab7784067 | 38 | HttpAddInt32AsHex(NmeaTimeBucketGetItem(i)); |
| andrewboyson | 48:9f1ab7784067 | 39 | } |
| andrewboyson | 48:9f1ab7784067 | 40 | } |
| andrewboyson | 48:9f1ab7784067 | 41 |