Constructor
new GnssModule(options)
Create a new GNSS module instance
Name | Type | Description |
---|---|---|
options | Object | Configuration options |
Methods
(async) configureDevice(settings) → {Promise.<boolean>}
Configure the device with specified settings
Name | Type | Description |
---|---|---|
settings | Object | Device settings to apply |
Success flag
- Type:
- Promise.<boolean>
(async) connectBluetooth(options) → {Promise.<boolean>}
Connect specifically via Bluetooth
Name | Type | Description |
---|---|---|
options | Object | Bluetooth connection options |
Connection success
- Type:
- Promise.<boolean>
(async) connectDevice(options) → {Promise.<boolean>}
Connect to a GNSS device using available methods
Name | Type | Description |
---|---|---|
options | Object | Connection options |
Connection success
- Type:
- Promise.<boolean>
(async) connectNtrip(options) → {Promise.<boolean>}
Connect to NTRIP caster
Name | Type | Description |
---|---|---|
options | Object | Connection options |
Connection success
- Type:
- Promise.<boolean>
(async) connectSerial(options) → {Promise.<boolean>}
Connect specifically via Serial
Name | Type | Description |
---|---|---|
options | Object | Serial connection options |
Connection success
- Type:
- Promise.<boolean>
(async) disconnectDevice() → {Promise.<void>}
Disconnect from device
- Type:
- Promise.<void>
(async) disconnectNtrip() → {Promise.<void>}
Disconnect from NTRIP
- Type:
- Promise.<void>
getPosition() → {Object|null}
Get current position
Current position
- Type:
- Object |
null
getSatellites() → {Array|null}
Get satellite information
Satellite information
- Type:
- Array |
null
getSettings() → {Settings}
Get the settings manager
Settings manager
- Type:
- Settings
off(event, callback)
Unsubscribe from an event
Name | Type | Description |
---|---|---|
event | string | Event name |
callback | function | Callback function |
on(event, callback) → {function}
Subscribe to an event
Name | Type | Description |
---|---|---|
event | string | Event name |
callback | function | Callback function |
Unsubscribe function
- Type:
- function