ARMmbed / ble-examples

BLE demos using mbed OS 3 and yotta.
Apache License 2.0
24 stars 27 forks source link

Cleanup eddystone code to not pass pointers #38

Closed andresag01 closed 8 years ago

andresag01 commented 8 years ago

Clean up the eddystone example code to pass a EddystoneParams_t using a reference to the structure rather than passing a pointer when calling getEddystoneParams(). @pan- @rgrover

andresag01 commented 8 years ago

@pan- perhaps it would also be good to pass by reference to saveEddystoneServiceConfigParams() and loadEddystoneServiceConfigParams(), but I am not sure this would be idea because that code interacts with C code i.e. pstorage, and there we dont have a choice but to pass the pointers.

pan- commented 8 years ago

Looks good for me. I don't understand why it would be a bad idea to use references for saveEddystoneServiceConfigParams and loadEddystoneServiceConfigParams. The fact that it call c functions is an implementation detail.

andresag01 commented 8 years ago

saveEddystoneServiceConfigParams and loadEddystoneServiceConfigParams will be fixed in a separate pull request.