LMS API Documentation
|
Data Structures | |
struct | lms_dev_info_t |
Typedefs | |
typedef bool(* | lms_prog_callback_t) (int bsent, int btotal, const char *progressMsg) |
Enumerations | |
enum | lms_prog_md_t { LMS_PROG_MD_RAM = 0, LMS_PROG_MD_FLASH = 1, LMS_PROG_MD_RST = 2 } |
enum | lms_prog_trg_t { LMS_PROG_TRG_FX3 = 0, LMS_PROG_TRG_FPGA, LMS_PROG_TRG_MCU, LMS_PROG_TRG_HPM7 } |
Functions | |
API_EXPORT int CALL_CONV | LMS_Program (lms_device_t *device, const char *data, size_t size, lms_prog_trg_t target, lms_prog_md_t mode, lms_prog_callback_t callback) |
API_EXPORT int CALL_CONV | LMS_ProgramUpdate (lms_device_t *dev, bool download, lms_prog_callback_t callback) |
API_EXPORT const lms_dev_info_t *CALL_CONV | LMS_GetDeviceInfo (lms_device_t *device) |
API_EXPORT const char * | LMS_GetLibraryVersion () |
Returns API library version. | |
API_EXPORT const char *CALL_CONV | LMS_GetLastErrorMessage (void) |
The functions in this section provides ability to check device version and perform updates
typedef bool(* lms_prog_callback_t) (int bsent, int btotal, const char *progressMsg) |
Callback from programming processes
bsent | number of bytes transferred |
btotal | total number of bytes to send |
progressMsg | string describing current progress state |
Definition at line 1225 of file LimeSuite.h.
enum lms_prog_md_t |
Enumeration of programming mode
Enumerator | |
---|---|
LMS_PROG_MD_RAM | load firmware/bitstream to volatile storage |
LMS_PROG_MD_FLASH | load firmware/bitstream to non-volatile storage |
LMS_PROG_MD_RST | reset and boot from flash |
Definition at line 1202 of file LimeSuite.h.
enum lms_prog_trg_t |
Enumeration of programmable board modules
Enumerator | |
---|---|
LMS_PROG_TRG_FX3 | program FX3 firmware |
LMS_PROG_TRG_FPGA | program FPGA gateware |
LMS_PROG_TRG_MCU | program LMS7 MCU firmware |
Definition at line 1210 of file LimeSuite.h.
API_EXPORT const lms_dev_info_t* CALL_CONV LMS_GetDeviceInfo | ( | lms_device_t * | device | ) |
Get device serial number and version information
device | Device handle previously obtained by LMS_Open(). |
API_EXPORT const char* CALL_CONV LMS_GetLastErrorMessage | ( | void | ) |
Get the error message detailing why the last error occurred.
API_EXPORT int CALL_CONV LMS_Program | ( | lms_device_t * | device, |
const char * | data, | ||
size_t | size, | ||
lms_prog_trg_t | target, | ||
lms_prog_md_t | mode, | ||
lms_prog_callback_t | callback | ||
) |
Write binary firmware/bitsteam image to specified device component.
device | Device handle previously obtained by LMS_Open(). |
data | Pointer to memory containing firmware/bitsteam image |
size | Size of firmware/bitsteam image in bytes. |
target | device component to program lms_prog_trg_t |
mode | programming mode lms_prog_md_t |
callback | callback function for monitoring progress |
API_EXPORT int CALL_CONV LMS_ProgramUpdate | ( | lms_device_t * | dev, |
bool | download, | ||
lms_prog_callback_t | callback | ||
) |
Automatically update device firmware
dev | Device handle previously obtained by LMS_Open(). |
download | True to download missing images from the web. |
callback | callback function for monitoring progress |