Impact Acquire SDK .NET
|
A class to perform a firmware update of a specific device. More...
Public Member Functions | |
FirmwareUpdater (mv.impact.acquire.Device pDev, bool boForceOverideSameVersion, bool boForceDowngrade, bool boKeepUserSets, bool boForceBreakingChange) | |
Creates a new mv.impact.acquire.FirmwareUpdater object. | |
virtual int | onErasingFlash (int currentProgress_pc, double timeElapsed_s) |
This function will be called once the devices flash memory is erased. | |
virtual int | onErrorMessage (double timeElapsed_s) |
This function will be called once a message is waiting to be passed to the user. | |
virtual int | onHardResetRequired (int currentProgress_pc, double timeElapsed_s) |
This function will be called once the device reboots and a manual hard reset is required. | |
virtual int | onLoadingUserSets (int currentProgress_pc, double timeElapsed_s) |
This function will be called when the settings of the device are written back after updating the firmware. | |
virtual int | onRebooting (int currentProgress_pc, double timeElapsed_s) |
This function will be called once the device reboots to make sure the new firmware is applied to the device. | |
virtual int | onSavingUserSets (int currentProgress_pc, double timeElapsed_s) |
This function will be called when the settings of the device are stored before updating the firmware. | |
virtual int | onUnzippingFirmwareArchive (int currentProgress_pc, double timeElapsed_s) |
This function will be called once firmware archive (*.mvu) is unzipped to provide the correct firmware file. | |
virtual int | onUpdatingBootProgrammer (int currentProgress_pc, double timeElapsed_s) |
The onUpdatingBootProgrammer-callback function which is called once the boot programmer of an mvBlueFOX3 camera is updated. | |
virtual int | onUploadingImage (int currentProgress_pc, double timeElapsed_s) |
This function will be called once the actual firmware file is uploaded to the device's flash memory. | |
TDMR_ERROR | update () |
A function to start the firmware update process. | |
TDMR_ERROR | update (String archivePath) |
A function to start the firmware update process. | |
TDMR_ERROR | update (String archivePath, bool boUpdateDataAsNeeded) |
A function to start the firmware update process. | |
Static Public Member Functions | |
static TDMR_ERROR | verifyFirmwareChecksum (Device pDev, String archivePath) |
A function to check the integrity of the firmware running on a device. | |
static TDMR_ERROR | verifyFirmwareChecksum (Device pDev, String archivePath, out String statusMessage) |
A function to check the integrity of the firmware running on a device. | |
Public Attributes | |
PropertyI | firmwareVersionToUpload = new PropertyI() |
An enumerated integer property containing a list of available firmware versions. | |
Properties | |
String | statusMessage [get] |
Returns the current status from the status property. | |
double | timeElapsed_s [get] |
A method to get the elapsed time in seconds since the update process has been started. | |
A class to perform a firmware update of a specific device.
This class is intended to provide an ease of use possibility to update the firmware of specific devices. It is possible to specify the behavior of the class very detailed to make sure the update suits the users expectations. It is also possible to derive from this class and override various functions in order to get custom notifications e.g. to update a GUI application.
To start a firmware update for Balluff GenICam devices the following code will be sufficient:
To start a firmware update for Balluff mvBlueFOX devices the following code will be sufficient:
A more custom behavior can be accomplished by deriving from the mv.impact.acquire.FirmwareUpdater class and re-implementing the various notification functions:
|
inline |
Creates a new mv.impact.acquire.FirmwareUpdater object.
[in] | pDev | A pointer to a mv.impact.acquire.Device object obtained from a mv.impact.acquire.DeviceManager object. |
[in] | boForceOverideSameVersion | A boolean value to configure if flashing with same version is allowed. |
[in] | boForceDowngrade | A boolean value to configure if flashing with an older version is allowed. |
[in] | boKeepUserSets | A boolean value which defines if the user sets of the device will be kept or will be deleted during the update. |
[in] | boForceBreakingChange | A boolean value to configure if flashing with a version that introduces an interface change is allowed. Setting this value to true will also update a device which after the update might have a different interface. See documentation for additional information about breaking changes in firmware versions(there are not too many)! |
This function will be called once the devices flash memory is erased.
Re-implement this function in a derived class in order to implement a custom behaviour.
[in] | currentProgress_pc | The current progress of the erase operation (in percent). |
[in] | timeElapsed_s | The total time elapsed since starting the update process (in seconds). |
This function will be called once a message is waiting to be passed to the user.
Re-implement this function in a derived class in order to implement a custom behaviour.
[in] | timeElapsed_s | The total time elapsed since starting the update process (in seconds). |
This function will be called once the device reboots and a manual hard reset is required.
Re-implement this function in a derived class in order to implement a custom behaviour.
[in] | currentProgress_pc | The current progress of the reboot operation (in percent). |
[in] | timeElapsed_s | The total time elapsed since starting the update process (in seconds). |
This function will be called when the settings of the device are written back after updating the firmware.
Re-implement this function in a derived class in order to implement a custom behaviour.
This callback will only be called when user sets shall be available after the update. This can be specified by setting the boKeepUserSets flag upon construction of this object.
[in] | currentProgress_pc | The current progress of the load operation (in percent). |
[in] | timeElapsed_s | The total time elapsed since starting the update process (in seconds). |
This function will be called once the device reboots to make sure the new firmware is applied to the device.
Re-implement this function in a derived class in order to implement a custom behaviour.
[in] | currentProgress_pc | The current progress of the reboot operation (in percent). |
[in] | timeElapsed_s | The total time elapsed since starting the update process (in seconds). |
This function will be called when the settings of the device are stored before updating the firmware.
Re-implement this function in a derived class in order to implement a custom behaviour.
This callback will only be called when user sets shall be available after the update. This can be specified by setting the boKeepUserSets flag upon construction of this object.
[in] | currentProgress_pc | The current progress of the save operation (in percent). |
[in] | timeElapsed_s | The total time elapsed since starting the update process (in seconds). |
|
inlinevirtual |
This function will be called once firmware archive (*.mvu) is unzipped to provide the correct firmware file.
Re-implement this function in a derived class in order to implement a custom behaviour.
[in] | currentProgress_pc | The current progress of the unzip operation (in percent). |
[in] | timeElapsed_s | The total time elapsed since starting the update process (in seconds). |
The onUpdatingBootProgrammer-callback function which is called once the boot programmer of an mvBlueFOX3 camera is updated.
Re-implement this function in a derived class in order to get the desired behaviour.
[in] | currentProgress_pc | The current progress of the update operation (in percent). |
[in] | timeElapsed_s | The total time elapsed since starting the update process (in seconds). |
This function will be called once the actual firmware file is uploaded to the device's flash memory.
Re-implement this function in a derived class in order to implement a custom behaviour.
[in] | currentProgress_pc | The current progress of the upload operation (in percent). |
[in] | timeElapsed_s | The total time elapsed since starting the update process (in seconds). |
|
inline |
A function to start the firmware update process.
This function is intended to be used to update Balluff devices.
|
inline |
A function to start the firmware update process.
This function is intended to be used to update Balluff devices.
[in] | archivePath | Path to the file which should be used to update the device. Can be empty if no update archives are needed for the device. |
|
inline |
A function to start the firmware update process.
This function is intended to be used to update Balluff devices.
[in] | archivePath | Path to the file which should be used to update the device. Can be empty if no update archives are needed for the device. |
[in] | boUpdateDataAsNeeded | Can be set to false in order to save time when updating multiple devices in one go. Please note that as soon as at least one GenICam device is part of these multiple devices mv.impact.acquire.DeviceManager.updateDeviceList must be called before any of those GenICam devices can be used again! |
|
inlinestatic |
A function to check the integrity of the firmware running on a device.
This function is intended to be used to check the firmware integrity of Balluff devices only. Most Balluff devices are capable of calculating a hash from the firmware image which is currently running on the device. In addition to that firmware archives provided by Balluff contain hashes for all the firmware images contained in the update archive. Comparing these 2 hashes will provide additional security when an application wants to make sure that the firmware running on the device is undamaged.
[in] | pDev | A pointer to a mvIMPACT::acquire::Device object obtained from a mvIMPACT::acquire::DeviceManager object. |
[in] | archivePath | Path to the file which should be used to compare the firmware checksum from with the firmware currently running on the device. |
|
inlinestatic |
A function to check the integrity of the firmware running on a device.
This function is intended to be used to check the firmware integrity of Balluff devices only. Most Balluff devices are capable of calculating a hash from the firmware image which is currently running on the device. In addition to that firmware archives provided by Balluff contain hashes for all the firmware images contained in the update archive. Comparing these 2 hashes will provide additional security when an application wants to make sure that the firmware running on the device is undamaged.
[in] | pDev | A pointer to a mvIMPACT::acquire::Device object obtained from a mvIMPACT::acquire::DeviceManager object. |
[in] | archivePath | Path to the file which should be used to compare the firmware checksum from with the firmware currently running on the device. |
[out] | statusMessage | A string receiving additional information about the outcome of the operation. |
An enumerated integer property containing a list of available firmware versions.
|
get |
Returns the current status from the status property.
|
get |
A method to get the elapsed time in seconds since the update process has been started.