libbladeRF: libbladeRF.h File Reference

| libbladeRF 2.4.1-git Nuand bladeRF library

Data Structures | Macros | Typedefs | Enumerations | Functions
libbladeRF.h File Reference

## Description

bladeRF library

Copyright (C) 2013-2017 Nuand LLC

This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version.

This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA

Definition in file libbladeRF.h.

`#include <inttypes.h>`
`#include <stdint.h>`
`#include <stdlib.h>`
`#include <stdbool.h>`
`#include <bladeRF1.h>`
`#include <bladeRF2.h>`

Go to the source code of this file.

## Data Structures
struct | bladerf_devinfo
struct | bladerf_backendinfo
struct | bladerf_range
struct | bladerf_serial
struct | bladerf_version
struct | bladerf_gain_modes
struct | bladerf_rational_rate
struct | bladerf_loopback_modes
struct | bladerf_trigger
struct | bladerf_quick_tune
struct | bladerf_metadata
struct | bladerf_image

## Macros
#define | LIBBLADERF_API_VERSION (0x02040100)
#define | API_EXPORT
#define | CALL_CONV
#define | BLADERF_DESCRIPTION_LENGTH 33
#define | BLADERF_SERIAL_LENGTH 33
#define | BLADERF_CHANNEL_RX(ch) (bladerf_channel)(((ch) << 1) | 0x0)
#define | BLADERF_CHANNEL_TX(ch) (bladerf_channel)(((ch) << 1) | 0x1)
#define | BLADERF_CHANNEL_INVALID (bladerf_channel)(-1)
#define | BLADERF_CHANNEL_IS_TX(ch) (ch & BLADERF_TX)
#define | BLADERF_GAIN_AUTOMATIC BLADERF_GAIN_DEFAULT
#define | BLADERF_GAIN_MANUAL BLADERF_GAIN_MGC
#define | BLADERF_PRIuFREQ PRIu64
#define | BLADERF_PRIxFREQ PRIx64
#define | BLADERF_SCNuFREQ SCNu64
#define | BLADERF_SCNxFREQ SCNx64
#define | BLADERF_RETUNE_NOW (bladerf_timestamp)0
#define | BLADERF_PRIuTS PRIu64
#define | BLADERF_PRIxTS PRIx64
#define | BLADERF_SCNuTS SCNu64
#define | BLADERF_SCNxTS SCNx64
#define | BLADERF_META_STATUS_OVERRUN (1 << 0)
#define | BLADERF_META_STATUS_UNDERRUN (1 << 1)
#define | BLADERF_META_FLAG_TX_BURST_START (1 << 0)
#define | BLADERF_META_FLAG_TX_BURST_END (1 << 1)
#define | BLADERF_META_FLAG_TX_NOW (1 << 2)
#define | BLADERF_META_FLAG_TX_UPDATE_TIMESTAMP (1 << 3)
#define | BLADERF_META_FLAG_RX_NOW (1 << 31)
#define | BLADERF_META_FLAG_RX_HW_UNDERFLOW (1 << 0)
#define | BLADERF_META_FLAG_RX_HW_MINIEXP1 (1 << 16)
#define | BLADERF_META_FLAG_RX_HW_MINIEXP2 (1 << 17)
#define | BLADERF_STREAM_SHUTDOWN (NULL)
#define | BLADERF_STREAM_NO_DATA ((void *)(-1))
#define | BLADERF_IMAGE_MAGIC_LEN 7
#define | BLADERF_IMAGE_CHECKSUM_LEN 32
#define | BLADERF_IMAGE_RESERVED_LEN 128
#define | BLADERF_TRIGGER_REG_ARM ((uint8_t)(1 << 0))
#define | BLADERF_TRIGGER_REG_FIRE ((uint8_t)(1 << 1))
#define | BLADERF_TRIGGER_REG_MASTER ((uint8_t)(1 << 2))
#define | BLADERF_TRIGGER_REG_LINE ((uint8_t)(1 << 3))
#define | BLADERF_ERR_UNEXPECTED (-1)
#define | BLADERF_ERR_RANGE (-2)
#define | BLADERF_ERR_INVAL (-3)
#define | BLADERF_ERR_MEM (-4)
#define | BLADERF_ERR_IO (-5)
#define | BLADERF_ERR_TIMEOUT (-6)
#define | BLADERF_ERR_NODEV (-7)
#define | BLADERF_ERR_UNSUPPORTED (-8)
#define | BLADERF_ERR_MISALIGNED (-9)
#define | BLADERF_ERR_CHECKSUM (-10)
#define | BLADERF_ERR_NO_FILE (-11)
#define | BLADERF_ERR_UPDATE_FPGA (-12)
#define | BLADERF_ERR_UPDATE_FW (-13)
#define | BLADERF_ERR_TIME_PAST (-14)
#define | BLADERF_ERR_QUEUE_FULL (-15)
#define | BLADERF_ERR_FPGA_OP (-16)
#define | BLADERF_ERR_PERMISSION (-17)
#define | BLADERF_ERR_WOULD_BLOCK (-18)
#define | BLADERF_ERR_NOT_INIT (-19)

## Typedefs
typedef int | bladerf_channel
typedef int | bladerf_gain
typedef unsigned int | bladerf_sample_rate
typedef unsigned int | bladerf_bandwidth
typedef uint64_t | bladerf_frequency
typedef uint64_t | bladerf_timestamp
typedef int16_t | bladerf_correction_value
typedef void *(* | bladerf_stream_cb) (struct bladerf *dev, struct bladerf_stream *stream, struct bladerf_metadata *meta, void *samples, size_t num_samples, void *user_data)

## Enumerations
enum | bladerf_backend { BLADERF_BACKEND_ANY , BLADERF_BACKEND_LINUX , BLADERF_BACKEND_LIBUSB , BLADERF_BACKEND_CYPRESS , BLADERF_BACKEND_DUMMY = 100 }
enum | bladerf_fpga_size { BLADERF_FPGA_UNKNOWN = 0 , BLADERF_FPGA_40KLE = 40 , BLADERF_FPGA_115KLE = 115 , BLADERF_FPGA_A4 = 49 , BLADERF_FPGA_A5 = 77 , 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_direction { BLADERF_RX = 0 , BLADERF_TX = 1 }
enum | bladerf_channel_layout { BLADERF_RX_X1 = 0 , BLADERF_TX_X1 = 1 , BLADERF_RX_X2 = 2 , BLADERF_TX_X2 = 3 }
enum | bladerf_gain_mode { BLADERF_GAIN_DEFAULT , BLADERF_GAIN_MGC , BLADERF_GAIN_FASTATTACK_AGC , BLADERF_GAIN_SLOWATTACK_AGC , BLADERF_GAIN_HYBRID_AGC }
enum | bladerf_loopback { BLADERF_LB_NONE = 0 , BLADERF_LB_FIRMWARE , BLADERF_LB_BB_TXLPF_RXVGA2 , BLADERF_LB_BB_TXVGA1_RXVGA2 , BLADERF_LB_BB_TXLPF_RXLPF , BLADERF_LB_BB_TXVGA1_RXLPF , BLADERF_LB_RF_LNA1 , BLADERF_LB_RF_LNA2 , BLADERF_LB_RF_LNA3 , BLADERF_LB_RFIC_BIST }
enum | bladerf_trigger_role { BLADERF_TRIGGER_ROLE_INVALID = -1 , BLADERF_TRIGGER_ROLE_DISABLED , BLADERF_TRIGGER_ROLE_MASTER , BLADERF_TRIGGER_ROLE_SLAVE }
enum | bladerf_trigger_signal { BLADERF_TRIGGER_INVALID = -1 , BLADERF_TRIGGER_J71_4 , BLADERF_TRIGGER_J51_1 , BLADERF_TRIGGER_MINI_EXP_1 , BLADERF_TRIGGER_USER_0 = 128 , BLADERF_TRIGGER_USER_1 , BLADERF_TRIGGER_USER_2 , BLADERF_TRIGGER_USER_3 , BLADERF_TRIGGER_USER_4 , BLADERF_TRIGGER_USER_5 , BLADERF_TRIGGER_USER_6 , BLADERF_TRIGGER_USER_7 }
enum | bladerf_rx_mux { BLADERF_RX_MUX_INVALID = -1 , BLADERF_RX_MUX_BASEBAND = 0x0 , BLADERF_RX_MUX_12BIT_COUNTER = 0x1 , BLADERF_RX_MUX_32BIT_COUNTER = 0x2 , BLADERF_RX_MUX_DIGITAL_LOOPBACK = 0x4 }
enum | bladerf_correction { BLADERF_CORR_DCOFF_I , BLADERF_CORR_DCOFF_Q , BLADERF_CORR_PHASE , BLADERF_CORR_GAIN }
enum | bladerf_format { BLADERF_FORMAT_SC16_Q11 , BLADERF_FORMAT_SC16_Q11_META , BLADERF_FORMAT_PACKET_META }
enum | bladerf_image_type { BLADERF_IMAGE_TYPE_INVALID = -1 , BLADERF_IMAGE_TYPE_RAW , BLADERF_IMAGE_TYPE_FIRMWARE , BLADERF_IMAGE_TYPE_FPGA_40KLE , BLADERF_IMAGE_TYPE_FPGA_115KLE , BLADERF_IMAGE_TYPE_FPGA_A4 , BLADERF_IMAGE_TYPE_FPGA_A9 , BLADERF_IMAGE_TYPE_CALIBRATION , BLADERF_IMAGE_TYPE_RX_DC_CAL , BLADERF_IMAGE_TYPE_TX_DC_CAL , BLADERF_IMAGE_TYPE_RX_IQ_CAL , BLADERF_IMAGE_TYPE_TX_IQ_CAL , BLADERF_IMAGE_TYPE_FPGA_A5 }
enum | bladerf_vctcxo_tamer_mode { BLADERF_VCTCXO_TAMER_INVALID = -1 , BLADERF_VCTCXO_TAMER_DISABLED = 0 , BLADERF_VCTCXO_TAMER_1_PPS = 1 , BLADERF_VCTCXO_TAMER_10_MHZ = 2 }
enum | bladerf_tuning_mode { BLADERF_TUNING_MODE_INVALID = -1 , BLADERF_TUNING_MODE_HOST , BLADERF_TUNING_MODE_FPGA }
enum | bladerf_xb { BLADERF_XB_NONE = 0 , BLADERF_XB_100 , BLADERF_XB_200 , BLADERF_XB_300 }
enum | bladerf_log_level { BLADERF_LOG_LEVEL_VERBOSE , BLADERF_LOG_LEVEL_DEBUG , BLADERF_LOG_LEVEL_INFO , BLADERF_LOG_LEVEL_WARNING , BLADERF_LOG_LEVEL_ERROR , BLADERF_LOG_LEVEL_CRITICAL , BLADERF_LOG_LEVEL_SILENT }

## Functions
API_EXPORT int CALL_CONV | bladerf_open (struct bladerf **device, const char *device_identifier)
API_EXPORT void CALL_CONV | bladerf_close (struct bladerf *device)
API_EXPORT int CALL_CONV | bladerf_open_with_devinfo (struct bladerf **device, struct bladerf_devinfo *devinfo)
API_EXPORT int CALL_CONV | bladerf_get_device_list (struct bladerf_devinfo **devices)
API_EXPORT void CALL_CONV | bladerf_free_device_list (struct bladerf_devinfo *devices)
API_EXPORT void CALL_CONV | bladerf_init_devinfo (struct bladerf_devinfo *info)
API_EXPORT int CALL_CONV | bladerf_get_devinfo (struct bladerf *dev, struct bladerf_devinfo *info)
API_EXPORT int CALL_CONV | bladerf_get_backendinfo (struct bladerf *dev, struct bladerf_backendinfo *info)
API_EXPORT int CALL_CONV | bladerf_get_devinfo_from_str (const char *devstr, struct bladerf_devinfo *info)
API_EXPORT bool CALL_CONV | bladerf_devinfo_matches (const struct bladerf_devinfo *a, const struct bladerf_devinfo *b)
API_EXPORT bool CALL_CONV | bladerf_devstr_matches (const char *dev_str, struct bladerf_devinfo *info)
API_EXPORT const char *CALL_CONV | bladerf_backend_str (bladerf_backend backend)
API_EXPORT void CALL_CONV | bladerf_set_usb_reset_on_open (bool enabled)
API_EXPORT int CALL_CONV | bladerf_get_serial (struct bladerf *dev, char *serial)
API_EXPORT int CALL_CONV | bladerf_get_serial_struct (struct bladerf *dev, struct bladerf_serial *serial)
API_EXPORT int CALL_CONV | bladerf_get_fpga_size (struct bladerf *dev, bladerf_fpga_size *size)
API_EXPORT int CALL_CONV | bladerf_get_fpga_bytes (struct bladerf *dev, size_t *size)
API_EXPORT int CALL_CONV | bladerf_get_flash_size (struct bladerf *dev, uint32_t *size, bool *is_guess)
API_EXPORT int CALL_CONV | bladerf_fw_version (struct bladerf *dev, struct bladerf_version *version)
API_EXPORT int CALL_CONV | bladerf_is_fpga_configured (struct bladerf *dev)
API_EXPORT int CALL_CONV | bladerf_fpga_version (struct bladerf *dev, struct bladerf_version *version)
API_EXPORT int CALL_CONV | bladerf_get_fpga_source (struct bladerf *dev, bladerf_fpga_source *source)
API_EXPORT bladerf_dev_speed CALL_CONV | bladerf_device_speed (struct bladerf *dev)
API_EXPORT const char *CALL_CONV | bladerf_get_board_name (struct bladerf *dev)
API_EXPORT size_t CALL_CONV | bladerf_get_channel_count (struct bladerf *dev, bladerf_direction dir)
API_EXPORT int CALL_CONV | bladerf_set_gain (struct bladerf *dev, bladerf_channel ch, bladerf_gain gain)
API_EXPORT int CALL_CONV | bladerf_get_gain (struct bladerf *dev, bladerf_channel ch, bladerf_gain *gain)
API_EXPORT int CALL_CONV | bladerf_set_gain_mode (struct bladerf *dev, bladerf_channel ch, bladerf_gain_mode mode)
API_EXPORT int CALL_CONV | bladerf_get_gain_mode (struct bladerf *dev, bladerf_channel ch, bladerf_gain_mode *mode)
API_EXPORT int CALL_CONV | bladerf_get_gain_modes (struct bladerf *dev, bladerf_channel ch, const struct bladerf_gain_modes **modes)
API_EXPORT int CALL_CONV | bladerf_get_gain_range (struct bladerf *dev, bladerf_channel ch, const struct bladerf_range **range)
API_EXPORT int CALL_CONV | bladerf_set_gain_stage (struct bladerf *dev, bladerf_channel ch, const char *stage, bladerf_gain gain)
API_EXPORT int CALL_CONV | bladerf_get_gain_stage (struct bladerf *dev, bladerf_channel ch, const char *stage, bladerf_gain *gain)
API_EXPORT int CALL_CONV | bladerf_get_gain_stage_range (struct bladerf *dev, bladerf_channel ch, const char *stage, const struct bladerf_range **range)
API_EXPORT int CALL_CONV | bladerf_get_gain_stages (struct bladerf *dev, bladerf_channel ch, const char **stages, size_t count)
API_EXPORT int CALL_CONV | bladerf_set_sample_rate (struct bladerf *dev, bladerf_channel ch, bladerf_sample_rate rate, bladerf_sample_rate *actual)
API_EXPORT int CALL_CONV | bladerf_set_rational_sample_rate (struct bladerf *dev, bladerf_channel ch, struct bladerf_rational_rate *rate, struct bladerf_rational_rate *actual)
API_EXPORT int CALL_CONV | bladerf_get_sample_rate (struct bladerf *dev, bladerf_channel ch, bladerf_sample_rate *rate)
API_EXPORT int CALL_CONV | bladerf_get_sample_rate_range (struct bladerf *dev, bladerf_channel ch, const struct bladerf_range **range)
API_EXPORT int CALL_CONV | bladerf_get_rational_sample_rate (struct bladerf *dev, bladerf_channel ch, struct bladerf_rational_rate *rate)
API_EXPORT int CALL_CONV | bladerf_set_bandwidth (struct bladerf *dev, bladerf_channel ch, bladerf_bandwidth bandwidth, bladerf_bandwidth *actual)
API_EXPORT int CALL_CONV | bladerf_get_bandwidth (struct bladerf *dev, bladerf_channel ch, bladerf_bandwidth *bandwidth)
API_EXPORT int CALL_CONV | bladerf_get_bandwidth_range (struct bladerf *dev, bladerf_channel ch, const struct bladerf_range **range)
API_EXPORT int CALL_CONV | bladerf_select_band (struct bladerf *dev, bladerf_channel ch, bladerf_frequency frequency)
API_EXPORT int CALL_CONV | bladerf_set_frequency (struct bladerf *dev, bladerf_channel ch, bladerf_frequency frequency)
API_EXPORT int CALL_CONV | bladerf_get_frequency (struct bladerf *dev, bladerf_channel ch, bladerf_frequency *frequency)
API_EXPORT int CALL_CONV | bladerf_get_frequency_range (struct bladerf *dev, bladerf_channel ch, const struct bladerf_range **range)
API_EXPORT int CALL_CONV | bladerf_get_loopback_modes (struct bladerf *dev, const struct bladerf_loopback_modes **modes)
API_EXPORT bool CALL_CONV | bladerf_is_loopback_mode_supported (struct bladerf *dev, bladerf_loopback mode)
API_EXPORT int CALL_CONV | bladerf_set_loopback (struct bladerf *dev, bladerf_loopback lb)
API_EXPORT int CALL_CONV | bladerf_get_loopback (struct bladerf *dev, bladerf_loopback *lb)
API_EXPORT int CALL_CONV | bladerf_trigger_init (struct bladerf *dev, bladerf_channel ch, bladerf_trigger_signal signal, struct bladerf_trigger *trigger)
API_EXPORT int CALL_CONV | bladerf_trigger_arm (struct bladerf *dev, const struct bladerf_trigger *trigger, bool arm, uint64_t resv1, uint64_t resv2)
API_EXPORT int CALL_CONV | bladerf_trigger_fire (struct bladerf *dev, const struct bladerf_trigger *trigger)
API_EXPORT int CALL_CONV | bladerf_trigger_state (struct bladerf *dev, const struct bladerf_trigger *trigger, bool *is_armed, bool *has_fired, bool *fire_requested, uint64_t *resv1, uint64_t *resv2)
API_EXPORT int CALL_CONV | bladerf_set_rx_mux (struct bladerf *dev, bladerf_rx_mux mux)
API_EXPORT int CALL_CONV | bladerf_get_rx_mux (struct bladerf *dev, bladerf_rx_mux *mode)
API_EXPORT int CALL_CONV | bladerf_schedule_retune (struct bladerf *dev, bladerf_channel ch, bladerf_timestamp timestamp, bladerf_frequency frequency, struct bladerf_quick_tune *quick_tune)
API_EXPORT int CALL_CONV | bladerf_cancel_scheduled_retunes (struct bladerf *dev, bladerf_channel ch)
API_EXPORT int CALL_CONV | bladerf_get_quick_tune (struct bladerf *dev, bladerf_channel ch, struct bladerf_quick_tune *quick_tune)
API_EXPORT int CALL_CONV | bladerf_set_correction (struct bladerf *dev, bladerf_channel ch, bladerf_correction corr, bladerf_correction_value value)
API_EXPORT int CALL_CONV | bladerf_get_correction (struct bladerf *dev, bladerf_channel ch, bladerf_correction corr, bladerf_correction_value *value)
API_EXPORT int CALL_CONV | bladerf_interleave_stream_buffer (bladerf_channel_layout layout, bladerf_format format, unsigned int buffer_size, void *samples)
API_EXPORT int CALL_CONV | bladerf_deinterleave_stream_buffer (bladerf_channel_layout layout, bladerf_format format, unsigned int buffer_size, void *samples)
API_EXPORT int CALL_CONV | bladerf_enable_module (struct bladerf *dev, bladerf_channel ch, bool enable)
API_EXPORT int CALL_CONV | bladerf_get_timestamp (struct bladerf *dev, bladerf_direction dir, bladerf_timestamp *timestamp)
API_EXPORT int CALL_CONV | bladerf_sync_config (struct bladerf *dev, bladerf_channel_layout layout, bladerf_format format, unsigned int num_buffers, unsigned int buffer_size, unsigned int num_transfers, unsigned int stream_timeout)
API_EXPORT int CALL_CONV | bladerf_sync_tx (struct bladerf *dev, const void *samples, unsigned int num_samples, struct bladerf_metadata *metadata, unsigned int timeout_ms)
API_EXPORT int CALL_CONV | bladerf_sync_rx (struct bladerf *dev, void *samples, unsigned int num_samples, struct bladerf_metadata *metadata, unsigned int timeout_ms)
API_EXPORT int CALL_CONV | bladerf_init_stream (struct bladerf_stream **stream, struct bladerf *dev, bladerf_stream_cb callback, void ***buffers, size_t num_buffers, bladerf_format format, size_t samples_per_buffer, size_t num_transfers, void *user_data)
API_EXPORT int CALL_CONV | bladerf_stream (struct bladerf_stream *stream, bladerf_channel_layout layout)
API_EXPORT int CALL_CONV | bladerf_submit_stream_buffer (struct bladerf_stream *stream, void *buffer, unsigned int timeout_ms)
API_EXPORT int CALL_CONV | bladerf_submit_stream_buffer_nb (struct bladerf_stream *stream, void *buffer)
API_EXPORT void CALL_CONV | bladerf_deinit_stream (struct bladerf_stream *stream)
API_EXPORT int CALL_CONV | bladerf_set_stream_timeout (struct bladerf *dev, bladerf_direction dir, unsigned int timeout)
API_EXPORT int CALL_CONV | bladerf_get_stream_timeout (struct bladerf *dev, bladerf_direction dir, unsigned int *timeout)
API_EXPORT int CALL_CONV | bladerf_flash_firmware (struct bladerf *dev, const char *firmware)
API_EXPORT int CALL_CONV | bladerf_load_fpga (struct bladerf *dev, const char *fpga)
API_EXPORT int CALL_CONV | bladerf_flash_fpga (struct bladerf *dev, const char *fpga_image)
API_EXPORT int CALL_CONV | bladerf_erase_stored_fpga (struct bladerf *dev)
API_EXPORT int CALL_CONV | bladerf_device_reset (struct bladerf *dev)
API_EXPORT int CALL_CONV | bladerf_get_fw_log (struct bladerf *dev, const char *filename)
API_EXPORT int CALL_CONV | bladerf_jump_to_bootloader (struct bladerf *dev)
API_EXPORT int CALL_CONV | bladerf_get_bootloader_list (struct bladerf_devinfo **list)
API_EXPORT int CALL_CONV | bladerf_load_fw_from_bootloader (const char *device_identifier, bladerf_backend backend, uint8_t bus, uint8_t addr, const char *file)
API_EXPORT struct bladerf_image *CALL_CONV | bladerf_alloc_image (struct bladerf *dev, bladerf_image_type type, uint32_t address, uint32_t length)
API_EXPORT struct bladerf_image *CALL_CONV | bladerf_alloc_cal_image (struct bladerf *dev, bladerf_fpga_size fpga_size, uint16_t vctcxo_trim)
API_EXPORT void CALL_CONV | bladerf_free_image (struct bladerf_image *image)
API_EXPORT int CALL_CONV | bladerf_image_write (struct bladerf *dev, struct bladerf_image *image, const char *file)
API_EXPORT int CALL_CONV | bladerf_image_read (struct bladerf_image *image, const char *file)
API_EXPORT int CALL_CONV | bladerf_set_vctcxo_tamer_mode (struct bladerf *dev, bladerf_vctcxo_tamer_mode mode)
API_EXPORT int CALL_CONV | bladerf_get_vctcxo_tamer_mode (struct bladerf *dev, bladerf_vctcxo_tamer_mode *mode)
API_EXPORT int CALL_CONV | bladerf_get_vctcxo_trim (struct bladerf *dev, uint16_t *trim)
API_EXPORT int CALL_CONV | bladerf_trim_dac_write (struct bladerf *dev, uint16_t val)
API_EXPORT int CALL_CONV | bladerf_trim_dac_read (struct bladerf *dev, uint16_t *val)
API_EXPORT int CALL_CONV | bladerf_set_tuning_mode (struct bladerf *dev, bladerf_tuning_mode mode)
API_EXPORT int CALL_CONV | bladerf_get_tuning_mode (struct bladerf *dev, bladerf_tuning_mode *mode)
API_EXPORT int CALL_CONV | bladerf_read_trigger (struct bladerf *dev, bladerf_channel ch, bladerf_trigger_signal signal, uint8_t *val)
API_EXPORT int CALL_CONV | bladerf_write_trigger (struct bladerf *dev, bladerf_channel ch, bladerf_trigger_signal signal, uint8_t val)
API_EXPORT int CALL_CONV | bladerf_wishbone_master_read (struct bladerf *dev, uint32_t addr, uint32_t *data)
API_EXPORT int CALL_CONV | bladerf_wishbone_master_write (struct bladerf *dev, uint32_t addr, uint32_t val)
API_EXPORT int CALL_CONV | bladerf_config_gpio_read (struct bladerf *dev, uint32_t *val)
API_EXPORT int CALL_CONV | bladerf_config_gpio_write (struct bladerf *dev, uint32_t val)
API_EXPORT int CALL_CONV | bladerf_erase_flash (struct bladerf *dev, uint32_t erase_block, uint32_t count)
API_EXPORT int CALL_CONV | bladerf_erase_flash_bytes (struct bladerf *dev, uint32_t address, uint32_t length)
API_EXPORT int CALL_CONV | bladerf_read_flash (struct bladerf *dev, uint8_t *buf, uint32_t page, uint32_t count)
API_EXPORT int CALL_CONV | bladerf_read_flash_bytes (struct bladerf *dev, uint8_t *buf, uint32_t address, uint32_t bytes)
API_EXPORT int CALL_CONV | bladerf_write_flash (struct bladerf *dev, const uint8_t *buf, uint32_t page, uint32_t count)
API_EXPORT int CALL_CONV | bladerf_write_flash_bytes (struct bladerf *dev, const uint8_t *buf, uint32_t address, uint32_t length)
API_EXPORT int CALL_CONV | bladerf_lock_otp (struct bladerf *dev)
API_EXPORT int CALL_CONV | bladerf_read_otp (struct bladerf *dev, uint8_t *buf)
API_EXPORT int CALL_CONV | bladerf_write_otp (struct bladerf *dev, uint8_t *buf)
API_EXPORT int CALL_CONV | bladerf_set_rf_port (struct bladerf *dev, bladerf_channel ch, const char *port)
API_EXPORT int CALL_CONV | bladerf_get_rf_port (struct bladerf *dev, bladerf_channel ch, const char **port)
API_EXPORT int CALL_CONV | bladerf_get_rf_ports (struct bladerf *dev, bladerf_channel ch, const char **ports, unsigned int count)
API_EXPORT int CALL_CONV | bladerf_expansion_attach (struct bladerf *dev, bladerf_xb xb)
API_EXPORT int CALL_CONV | bladerf_expansion_get_attached (struct bladerf *dev, bladerf_xb *xb)
API_EXPORT void CALL_CONV | bladerf_log_set_verbosity (bladerf_log_level level)
API_EXPORT void CALL_CONV | bladerf_version (struct bladerf_version *version)
API_EXPORT const char *CALL_CONV | bladerf_strerror (int error)

## Macro Definition Documentation

## ◆ API_EXPORT

#define API_EXPORT

stdbool.h is not applicable for C++ programs, as the language inherently provides the bool type.

Users of Visual Studio 2012 and earlier will need to supply a stdbool.h implementation, as it is not included with the toolchain. One is provided with the bladeRF source code. Visual Studio 2013 onward supplies this header. Marks an API routine to be made visible to the dynamic loader. This is OS and/or compiler-specific.

Definition at line 82 of file libbladeRF.h.

## ◆ CALL_CONV

#define CALL_CONV

Specifies calling convention, if necessary. This is OS and/or compiler-specific.

Definition at line 85 of file libbladeRF.h.