Gocator API
 All Classes Files Functions Variables Typedefs Macros Modules Pages
kStatus GoSensor_Upgrade ( GoSensor  sensor,
const kChar sourcePath,
GoUpgradeFx  onUpdate,
kPointer  context 
)

Upgrades sensor firmware.

This function will block until the upgrade is completed. For sensors upgrading from a 4.X firmware, an automatic reboot is required in order for the upgrade to take effect. Otherwise, a manual reboot must be called.

Version
Introduced in firmware 4.0.10.27
Parameters
sensorGoSensor object.
sourcePathLocal file system path to the upgrade file.
onUpdateCallback function to receive progress updates, or kNULL.
contextContext handle to be passed to the upgrade callback.
Returns
Operation status.
See also
GoSensor_Reset
Remarks
Calling this function will result in writing operations to flash storage. Should the process be disrupted due to power loss or other factors, the sensor may enter Rescue mode.