|  | libbladeRF
    2.2.1-git
    Nuand bladeRF library | 
These functions provide the ability to query various pieces of information from an attached device.
These functions are thread-safe.
| Data Structures | |
| struct | bladerf_range | 
| struct | bladerf_serial | 
| struct | bladerf_version | 
| Enumerations | |
| enum | bladerf_fpga_size { BLADERF_FPGA_UNKNOWN = 0, BLADERF_FPGA_40KLE = 40, BLADERF_FPGA_115KLE = 115, BLADERF_FPGA_A4 = 49, BLADERF_FPGA_A9 = 301 } | 
| enum | bladerf_dev_speed { BLADERF_DEVICE_SPEED_UNKNOWN, BLADERF_DEVICE_SPEED_HIGH, BLADERF_DEVICE_SPEED_SUPER } | 
| enum | bladerf_fpga_source { BLADERF_FPGA_SOURCE_UNKNOWN = 0, BLADERF_FPGA_SOURCE_FLASH = 1, BLADERF_FPGA_SOURCE_HOST = 2 } | 
| enum bladerf_dev_speed | 
This enum describes the USB Speed at which the bladeRF is connected. Speeds not listed here are not supported.
Definition at line 412 of file libbladeRF.h.
| enum bladerf_fpga_size | 
FPGA device variant (size)
| Enumerator | |
|---|---|
| BLADERF_FPGA_UNKNOWN | Unable to determine FPGA variant | 
| BLADERF_FPGA_40KLE | 40 kLE FPGA | 
| BLADERF_FPGA_115KLE | 115 kLE FPGA | 
| BLADERF_FPGA_A4 | 49 kLE FPGA (A4) | 
| BLADERF_FPGA_A9 | 301 kLE FPGA (A9) | 
Definition at line 400 of file libbladeRF.h.
| enum bladerf_fpga_source | 
FPGA configuration source
Note: the numbering of this enum must match NuandFpgaConfigSource in firmware_common/bladeRF.h
| Enumerator | |
|---|---|
| BLADERF_FPGA_SOURCE_UNKNOWN | Uninitialized/invalid | 
| BLADERF_FPGA_SOURCE_FLASH | Last FPGA load was from flash | 
| BLADERF_FPGA_SOURCE_HOST | Last FPGA load was from host | 
Definition at line 424 of file libbladeRF.h.
| API_EXPORT bladerf_dev_speed CALL_CONV bladerf_device_speed | ( | struct bladerf * | dev | ) | 
Obtain the bus speed at which the device is operating
| dev | Device handle | 
| API_EXPORT int CALL_CONV bladerf_fpga_version | ( | struct bladerf * | dev, | 
| struct bladerf_version * | version | ||
| ) | 
Query FPGA version
| dev | Device handle | |
| [out] | version | Updated to contain firmware version | 
| API_EXPORT int CALL_CONV bladerf_fw_version | ( | struct bladerf * | dev, | 
| struct bladerf_version * | version | ||
| ) | 
Query firmware version
| dev | Device handle | |
| [out] | version | Updated to contain firmware version | 
| API_EXPORT const char* CALL_CONV bladerf_get_board_name | ( | struct bladerf * | dev | ) | 
Get the board name
| dev | Device handle | 
bladerf1 for a bladeRF x40/x115, or bladerf2 for a bladeRF Micro. | API_EXPORT int CALL_CONV bladerf_get_flash_size | ( | struct bladerf * | dev, | 
| uint32_t * | size, | ||
| bool * | is_guess | ||
| ) | 
Query a device's Flash size
| dev | Device handle | |
| [out] | size | Will be updated with the size of the onboard flash, in bytes. If an error occurs, no data will be written to this pointer. | 
| [out] | is_guess | True if the flash size is a guess (using FPGA size). False if the flash ID was queried and its size was successfully decoded. | 
| API_EXPORT int CALL_CONV bladerf_get_fpga_bytes | ( | struct bladerf * | dev, | 
| size_t * | size | ||
| ) | 
Query a device's expected FPGA bitstream length, in bytes
| dev | Device handle | |
| [out] | size | Will be updated with expected bitstream length. If an error occurs, no data will be written to this pointer. | 
| API_EXPORT int CALL_CONV bladerf_get_fpga_size | ( | struct bladerf * | dev, | 
| bladerf_fpga_size * | size | ||
| ) | 
Query a device's FPGA size
| dev | Device handle | |
| [out] | size | Will be updated with the on-board FPGA's size. If an error occurs, no data will be written to this pointer. | 
| API_EXPORT int CALL_CONV bladerf_get_fpga_source | ( | struct bladerf * | dev, | 
| bladerf_fpga_source * | source | ||
| ) | 
Query FPGA configuration source
Determine whether the FPGA image was loaded from flash, or if it was loaded from the host, by asking the firmware for the last-known FPGA configuration source.
| dev | Device handle | |
| [out] | source | Source of the configuration | 
| API_EXPORT int CALL_CONV bladerf_get_serial | ( | struct bladerf * | dev, | 
| char * | serial | ||
| ) | 
Query a device's serial number (deprecated)
| dev | Device handle | |
| [out] | serial | This user-supplied buffer, which must be at least BLADERF_SERIAL_LENGTH bytes, will be updated to contain a NUL-terminated serial number string. If an error occurs (as indicated by a non-zero return value), no data will be written to this buffer. | 
| API_EXPORT int CALL_CONV bladerf_get_serial_struct | ( | struct bladerf * | dev, | 
| struct bladerf_serial * | serial | ||
| ) | 
Query a device's serial number
| dev | Device handle | |
| [out] | serial | Pointer to a bladerf_serial structure, which will be populated with a serialstring on success. | 
Example code:
| API_EXPORT int CALL_CONV bladerf_is_fpga_configured | ( | struct bladerf * | dev | ) | 
Check FPGA configuration status
| dev | Device handle | 
 1.8.15
 1.8.15