Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions c/include/libsbp/ssr.h
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ typedef struct SBP_ATTR_PACKED {

See GNSS-SSR-ArrayOfCorrectionPoints field correctionPointSetID.
*/
u16 corner_nw_lat; /**< North-West corner correction point latitude.
s16 corner_nw_lat; /**< North-West corner correction point latitude.

The relation between the latitude X in the range [-90, 90] and
the coded number N is:
Expand All @@ -327,7 +327,7 @@ N = floor((X / 90) * 2^14)

See GNSS-SSR-ArrayOfCorrectionPoints field referencePointLatitude.
[encoded degrees] */
u16 corner_nw_lon; /**< North-West corner correction point longtitude.
s16 corner_nw_lon; /**< North-West corner correction point longtitude.

The relation between the longtitude X in the range [-180, 180]
and the coded number N is:
Expand Down
Binary file modified docs/sbp.pdf
Binary file not shown.
12 changes: 6 additions & 6 deletions haskell/src/SwiftNav/SBP/Ssr.hs
Original file line number Diff line number Diff line change
Expand Up @@ -636,12 +636,12 @@ data MsgSsrTileDefinition = MsgSsrTileDefinition
, _msgSsrTileDefinition_tile_id :: !Word16
-- ^ Unique identifier of this tile in the tile set. See GNSS-SSR-
-- ArrayOfCorrectionPoints field correctionPointSetID.
, _msgSsrTileDefinition_corner_nw_lat :: !Word16
, _msgSsrTileDefinition_corner_nw_lat :: !Int16
-- ^ North-West corner correction point latitude. The relation between the
-- latitude X in the range [-90, 90] and the coded number N is: N =
-- floor((X / 90) * 2^14) See GNSS-SSR-ArrayOfCorrectionPoints field
-- referencePointLatitude.
, _msgSsrTileDefinition_corner_nw_lon :: !Word16
, _msgSsrTileDefinition_corner_nw_lon :: !Int16
-- ^ North-West corner correction point longtitude. The relation between the
-- longtitude X in the range [-180, 180] and the coded number N is: N =
-- floor((X / 180) * 2^15) See GNSS-SSR-ArrayOfCorrectionPoints field
Expand Down Expand Up @@ -675,8 +675,8 @@ instance Binary MsgSsrTileDefinition where
get = do
_msgSsrTileDefinition_tile_set_id <- getWord16le
_msgSsrTileDefinition_tile_id <- getWord16le
_msgSsrTileDefinition_corner_nw_lat <- getWord16le
_msgSsrTileDefinition_corner_nw_lon <- getWord16le
_msgSsrTileDefinition_corner_nw_lat <- (fromIntegral <$> getWord16le)
_msgSsrTileDefinition_corner_nw_lon <- (fromIntegral <$> getWord16le)
_msgSsrTileDefinition_spacing_lat <- getWord16le
_msgSsrTileDefinition_spacing_lon <- getWord16le
_msgSsrTileDefinition_rows <- getWord16le
Expand All @@ -687,8 +687,8 @@ instance Binary MsgSsrTileDefinition where
put MsgSsrTileDefinition {..} = do
putWord16le _msgSsrTileDefinition_tile_set_id
putWord16le _msgSsrTileDefinition_tile_id
putWord16le _msgSsrTileDefinition_corner_nw_lat
putWord16le _msgSsrTileDefinition_corner_nw_lon
(putWord16le . fromIntegral) _msgSsrTileDefinition_corner_nw_lat
(putWord16le . fromIntegral) _msgSsrTileDefinition_corner_nw_lon
putWord16le _msgSsrTileDefinition_spacing_lat
putWord16le _msgSsrTileDefinition_spacing_lon
putWord16le _msgSsrTileDefinition_rows
Expand Down
8 changes: 4 additions & 4 deletions java/src/com/swiftnav/sbp/ssr/MsgSsrTileDefinition.java
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,8 @@ protected void parse(Parser parser) throws SBPBinaryException {
/* Parse fields from binary */
tile_set_id = parser.getU16();
tile_id = parser.getU16();
corner_nw_lat = parser.getU16();
corner_nw_lon = parser.getU16();
corner_nw_lat = parser.getS16();
corner_nw_lon = parser.getS16();
spacing_lat = parser.getU16();
spacing_lon = parser.getU16();
rows = parser.getU16();
Expand All @@ -141,8 +141,8 @@ protected void parse(Parser parser) throws SBPBinaryException {
protected void build(Builder builder) {
builder.putU16(tile_set_id);
builder.putU16(tile_id);
builder.putU16(corner_nw_lat);
builder.putU16(corner_nw_lon);
builder.putS16(corner_nw_lat);
builder.putS16(corner_nw_lon);
builder.putU16(spacing_lat);
builder.putU16(spacing_lon);
builder.putU16(rows);
Expand Down
2 changes: 1 addition & 1 deletion javascript/sbp.bundle.js

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions javascript/sbp/ssr.js
Original file line number Diff line number Diff line change
Expand Up @@ -666,10 +666,10 @@ MsgSsrGriddedCorrection.prototype.fieldSpec.push(['element', GridElement.prototy
* @field tile_set_id number (unsigned 16-bit int, 2 bytes) Unique identifier of the tile set this tile belongs to.
* @field tile_id number (unsigned 16-bit int, 2 bytes) Unique identifier of this tile in the tile set. See GNSS-SSR-
* ArrayOfCorrectionPoints field correctionPointSetID.
* @field corner_nw_lat number (unsigned 16-bit int, 2 bytes) North-West corner correction point latitude. The relation between the latitude
* @field corner_nw_lat number (signed 16-bit int, 2 bytes) North-West corner correction point latitude. The relation between the latitude
* X in the range [-90, 90] and the coded number N is: N = floor((X / 90) * 2^14)
* See GNSS-SSR-ArrayOfCorrectionPoints field referencePointLatitude.
* @field corner_nw_lon number (unsigned 16-bit int, 2 bytes) North-West corner correction point longtitude. The relation between the
* @field corner_nw_lon number (signed 16-bit int, 2 bytes) North-West corner correction point longtitude. The relation between the
* longtitude X in the range [-180, 180] and the coded number N is: N = floor((X /
* 180) * 2^15) See GNSS-SSR-ArrayOfCorrectionPoints field
* referencePointLongitude.
Expand Down Expand Up @@ -708,8 +708,8 @@ MsgSsrTileDefinition.prototype.parser = new Parser()
.endianess('little')
.uint16('tile_set_id')
.uint16('tile_id')
.uint16('corner_nw_lat')
.uint16('corner_nw_lon')
.int16('corner_nw_lat')
.int16('corner_nw_lon')
.uint16('spacing_lat')
.uint16('spacing_lon')
.uint16('rows')
Expand All @@ -718,8 +718,8 @@ MsgSsrTileDefinition.prototype.parser = new Parser()
MsgSsrTileDefinition.prototype.fieldSpec = [];
MsgSsrTileDefinition.prototype.fieldSpec.push(['tile_set_id', 'writeUInt16LE', 2]);
MsgSsrTileDefinition.prototype.fieldSpec.push(['tile_id', 'writeUInt16LE', 2]);
MsgSsrTileDefinition.prototype.fieldSpec.push(['corner_nw_lat', 'writeUInt16LE', 2]);
MsgSsrTileDefinition.prototype.fieldSpec.push(['corner_nw_lon', 'writeUInt16LE', 2]);
MsgSsrTileDefinition.prototype.fieldSpec.push(['corner_nw_lat', 'writeInt16LE', 2]);
MsgSsrTileDefinition.prototype.fieldSpec.push(['corner_nw_lon', 'writeInt16LE', 2]);
MsgSsrTileDefinition.prototype.fieldSpec.push(['spacing_lat', 'writeUInt16LE', 2]);
MsgSsrTileDefinition.prototype.fieldSpec.push(['spacing_lon', 'writeUInt16LE', 2]);
MsgSsrTileDefinition.prototype.fieldSpec.push(['rows', 'writeUInt16LE', 2]);
Expand Down
4 changes: 2 additions & 2 deletions proto/ssr.proto
Original file line number Diff line number Diff line change
Expand Up @@ -248,8 +248,8 @@ message MsgSsrGriddedCorrection {
message MsgSsrTileDefinition {
uint32 tile_set_id = 1;
uint32 tile_id = 2;
uint32 corner_nw_lat = 3;
uint32 corner_nw_lon = 4;
sint32 corner_nw_lat = 3;
sint32 corner_nw_lon = 4;
uint32 spacing_lat = 5;
uint32 spacing_lon = 6;
uint32 rows = 7;
Expand Down
4 changes: 2 additions & 2 deletions python/sbp/jit/ssr.py
Original file line number Diff line number Diff line change
Expand Up @@ -787,9 +787,9 @@ def parse_members(cls, buf, offset, length):
ret['tile_set_id'] = __tile_set_id
(__tile_id, offset, length) = get_u16(buf, offset, length)
ret['tile_id'] = __tile_id
(__corner_nw_lat, offset, length) = get_u16(buf, offset, length)
(__corner_nw_lat, offset, length) = get_s16(buf, offset, length)
ret['corner_nw_lat'] = __corner_nw_lat
(__corner_nw_lon, offset, length) = get_u16(buf, offset, length)
(__corner_nw_lon, offset, length) = get_s16(buf, offset, length)
ret['corner_nw_lon'] = __corner_nw_lon
(__spacing_lat, offset, length) = get_u16(buf, offset, length)
ret['spacing_lat'] = __spacing_lat
Expand Down
4 changes: 2 additions & 2 deletions python/sbp/ssr.py
Original file line number Diff line number Diff line change
Expand Up @@ -1505,8 +1505,8 @@ class MsgSsrTileDefinition(SBP):
_parser = construct.Struct(
'tile_set_id' / construct.Int16ul,
'tile_id' / construct.Int16ul,
'corner_nw_lat' / construct.Int16ul,
'corner_nw_lon' / construct.Int16ul,
'corner_nw_lat' / construct.Int16sl,
'corner_nw_lon' / construct.Int16sl,
'spacing_lat' / construct.Int16ul,
'spacing_lon' / construct.Int16ul,
'rows' / construct.Int16ul,
Expand Down
8 changes: 4 additions & 4 deletions rust/sbp/src/messages/ssr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1252,12 +1252,12 @@ pub struct MsgSsrTileDefinition {
/// latitude X in the range [-90, 90] and the coded number N is: N =
/// floor((X / 90) * 2^14) See GNSS-SSR-ArrayOfCorrectionPoints field
/// referencePointLatitude.
pub corner_nw_lat: u16,
pub corner_nw_lat: i16,
/// North-West corner correction point longtitude. The relation between the
/// longtitude X in the range [-180, 180] and the coded number N is: N =
/// floor((X / 180) * 2^15) See GNSS-SSR-ArrayOfCorrectionPoints field
/// referencePointLongitude.
pub corner_nw_lon: u16,
pub corner_nw_lon: i16,
/// Spacing of the correction points in the latitude direction. See GNSS-
/// SSR-ArrayOfCorrectionPoints field stepOfLatitude.
pub spacing_lat: u16,
Expand Down Expand Up @@ -1290,8 +1290,8 @@ impl MsgSsrTileDefinition {
sender_id: None,
tile_set_id: _buf.read_u16::<LittleEndian>()?,
tile_id: _buf.read_u16::<LittleEndian>()?,
corner_nw_lat: _buf.read_u16::<LittleEndian>()?,
corner_nw_lon: _buf.read_u16::<LittleEndian>()?,
corner_nw_lat: _buf.read_i16::<LittleEndian>()?,
corner_nw_lon: _buf.read_i16::<LittleEndian>()?,
spacing_lat: _buf.read_u16::<LittleEndian>()?,
spacing_lon: _buf.read_u16::<LittleEndian>()?,
rows: _buf.read_u16::<LittleEndian>()?,
Expand Down
4 changes: 2 additions & 2 deletions spec/yaml/swiftnav/sbp/ssr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,7 @@ definitions:

See GNSS-SSR-ArrayOfCorrectionPoints field correctionPointSetID.
- corner_nw_lat:
type: u16
type: s16
units: encoded degrees
desc: |
North-West corner correction point latitude.
Expand All @@ -460,7 +460,7 @@ definitions:

See GNSS-SSR-ArrayOfCorrectionPoints field referencePointLatitude.
- corner_nw_lon:
type: u16
type: s16
units: encoded degrees
desc: |
North-West corner correction point longtitude.
Expand Down