|
MetaWear C# SDK
1.2.0
C# API for MbientLab's sensor platform
|
Configures Bluetooth settings and auxiliary hardware and firmware features More...
Public Member Functions | |
| Task< BleAdvertisementConfig > | ReadBleAdConfigAsync () |
| Read the current ble advertising configuration More... | |
| Task< BleConnectionParameters > | ReadBleConnParamsAsync () |
| Read the current ble connection parameters More... | |
| Task< sbyte > | ReadTxPowerAsync () |
| Reads the radio's current transmitting power More... | |
| void | SetTxPower (sbyte power) |
| Sets the radio's transmitting power More... | |
| void | EditBleConnParams (float minConnInterval=7.5f, float maxConnInterval=125f, ushort slaveLatency=0, ushort supervisorTimeout=6000) |
| Edit the ble connection parameters More... | |
| void | EditBleAdConfig (string name=null, byte? timeout=null, ushort? interval=null, byte[] scanResponse=null) |
| Edit the ble advertising configuration More... | |
| void | StartBleAdvertising () |
| Starts ble advertising More... | |
| Task< IObserver > | OnDisconnectAsync (Action commands) |
| Programs a task to the board that will be executed when a disconnect occurs More... | |
Properties | |
| IForcedDataProducer | Battery [get] |
| Data producer representing the battery state More... | |
| IActiveDataProducer< byte > | PowerStatus [get] |
| Data producer representing the power status. More... | |
| IActiveDataProducer< byte > | ChargeStatus [get] |
Configures Bluetooth settings and auxiliary hardware and firmware features
| void MbientLab.MetaWear.Core.ISettings.EditBleAdConfig | ( | string | name = null, |
| byte? | timeout = null, |
||
| ushort? | interval = null, |
||
| byte [] | scanResponse = null |
||
| ) |
Edit the ble advertising configuration
| name | Advertising name, max of 8 ASCII characters |
| timeout | Time between advertise events, in milliseconds (ms) |
| interval | How long to advertise for, between [0, 180] seconds where 0 indicates no timeout |
| scanResponse | Custom scan response packet |
| void MbientLab.MetaWear.Core.ISettings.EditBleConnParams | ( | float | minConnInterval = 7.5f, |
| float | maxConnInterval = 125f, |
||
| ushort | slaveLatency = 0, |
||
| ushort | supervisorTimeout = 6000 |
||
| ) |
Edit the ble connection parameters
| minConnInterval | Lower bound of the connection interval, min 7.5ms |
| maxConnInterval | Upper bound of the connection interval, max 4000ms |
| slaveLatency | Number of connection intervals to skip, between [0, 1000] |
| supervisorTimeout | Maximum amount of time between data exchanges until the connection is considered to be lost, between [10, 32000] ms |
| Task<IObserver> MbientLab.MetaWear.Core.ISettings.OnDisconnectAsync | ( | Action | commands | ) |
Programs a task to the board that will be executed when a disconnect occurs
| commands | MetaWear commands composing the task |
| Task<BleAdvertisementConfig> MbientLab.MetaWear.Core.ISettings.ReadBleAdConfigAsync | ( | ) |
Read the current ble advertising configuration
| Task<BleConnectionParameters> MbientLab.MetaWear.Core.ISettings.ReadBleConnParamsAsync | ( | ) |
Read the current ble connection parameters
| NotSupportedException | If the firmware revision does not support ble connection parameters |
| Task<sbyte> MbientLab.MetaWear.Core.ISettings.ReadTxPowerAsync | ( | ) |
Reads the radio's current transmitting power
| void MbientLab.MetaWear.Core.ISettings.SetTxPower | ( | sbyte | power | ) |
Sets the radio's transmitting power
| power | One of: 4, 0, -4, -8, -12, -16, -20, or -30 |
| void MbientLab.MetaWear.Core.ISettings.StartBleAdvertising | ( | ) |
Starts ble advertising
|
get |
Data producer representing the battery state
This property returns null if the current board or firmware does not report battery information
|
get |
This property returns null if the current board or firmware does not support charge status notifications
|
get |
Data producer representing the power status.
This property returns null if the current board or firmware does not support power status notifications
1.8.14