BLUFirmwareImage Class Reference
Inherits from | NSObject |
---|---|
Declared in | BLUFirmwareImage.h |
Overview
BLUFirmwareImage
objects are used to update a beacon’s firmware.
A firmware image instance can be created from any valid firmware file provided as NSData.
The firmware image object can be used to start a firmware update by calling updateFirmwareWithImage:progress:completion:
on a BLUConfigurableBeacon
instance.
There are two possible types of firmware images: Normal firmware and loader images. Certain normal images are too large in size to be installed onto a beacon directly. In such a case a loader image needs to be installed first to free up enough space on the beacon for the installation of the targeted firmware. Normal firmware images are considered invalid for beacons that require a loader image first. Please make sure to provide the firmware files for a beacon in the correct sequence.
Initialization
+ firmwareImageForData:configurableBeacon:
Initializes an instance of BLUFirmwareImage for the specified configurable beacon with the provided firmware data.
+ (BLUFirmwareImage *)firmwareImageForData:(NSData *)firmwareData configurableBeacon:(BLUConfigurableBeacon *)configurableBeacon
Parameters
firmwareData |
An NSData object containing the firmware update image. |
---|---|
configurableBeacon |
A BLUConfigurableBeacon object representing the beacon that will be updated. |
Return Value
Returns a newly initialized BLUFirmwareImage instance or nil
if the data does not contain
a valid firmware image for the given beacon.
Discussion
Initializes an instance of BLUFirmwareImage for the specified configurable beacon with the provided firmware data.
Declared In
BLUFirmwareImage.h
+ firmwareImagesForData:configurableBeacon:
Returns all firmware images for the specified configurable beacon that are contained in the provided firmware data.
+ (NSArray<BLUFirmwareImage*> *)firmwareImagesForData:(NSData *)firmwareData configurableBeacon:(BLUConfigurableBeacon *)configurableBeacon
Parameters
firmwareData |
An NSData object containing the firmware update image. |
---|---|
configurableBeacon |
A BLUConfigurableBeacon object representing the beacon that the firmware images are needed for. |
Return Value
Returns an array of BLUFirmwareImage
instances or nil
if the data does not contain
any firmware images for the given beacon. The array contains all compatible firmware images within the provided data -
regardless of their size and validity.
Discussion
Returns all firmware images for the specified configurable beacon that are contained in the provided firmware data.
Declared In
BLUFirmwareImage.h
+ firmwareRevisionForData:configurableBeacon:
Reads a firmware file provided as NSData and returns its firmware revision if the data is compatible with the specified configurable beacon.
+ (NSNumber *)firmwareRevisionForData:(NSData *)firmwareData configurableBeacon:(BLUConfigurableBeacon *)configurableBeacon
Parameters
firmwareData |
An NSData object containing the firmware update image. |
---|---|
configurableBeacon |
A BLUConfigurableBeacon object that the firmware revision is needed for. |
Return Value
Returns the firmware revision of the specified data or nil
if the data does not contain
a valid firmware image for the given beacon.
Discussion
Reads a firmware file provided as NSData and returns its firmware revision if the data is compatible with the specified configurable beacon.
Declared In
BLUFirmwareImage.h
Properties
firmwareName
The title of the firmware image.
@property (nonatomic, readonly) NSString *firmwareName
Discussion
The title of the firmware image.
Declared In
BLUFirmwareImage.h
firmwareDescription
The description of the firmware image.
@property (nonatomic, readonly) NSString *firmwareDescription
Discussion
The description of the firmware image.
Declared In
BLUFirmwareImage.h
size
The size of the firmware image in bytes.
@property (nonatomic, readonly) NSNumber *size
Discussion
The size of the firmware image in bytes.
Declared In
BLUFirmwareImage.h
revisionNumber
The revision number of the firmware image.
@property (nonatomic, readonly) NSNumber *revisionNumber
Discussion
The revision number of the firmware image.
Declared In
BLUFirmwareImage.h
revisionString
The revision string of the firmware image.
@property (nonatomic, readonly) NSString *revisionString
Discussion
The revision string of the firmware image.
Declared In
BLUFirmwareImage.h
isLoaderImage
A boolean specifying whether the firmware image is a loader image. Certain firmware images are too large in size to be installed onto a beacon directly. In such a case a loader image needs to be installed first to clear enough space on the beacon for the installation of the targeted firmware.
@property (nonatomic, readonly) BOOL isLoaderImage
Discussion
A boolean specifying whether the firmware image is a loader image. Certain firmware images are too large in size to be installed onto a beacon directly. In such a case a loader image needs to be installed first to clear enough space on the beacon for the installation of the targeted firmware.
Declared In
BLUFirmwareImage.h