embassy-rs / nrf-softdevice

Apache License 2.0
256 stars 76 forks source link

Refactor GattError #169

Closed alexmoon closed 1 year ago

alexmoon commented 1 year ago

Refactors GattError from an enum to a newtype struct with associated constants. Also add a GattStatus type and ensures GattError cannot represent a GattStatus::SUCCESS. This allows for GattErrors other than the predefined values to be constructed and used, such as error codes from the Application Error range (0x180-0x19f).