Chirp C SDK  3.3.1
Use Chirp to send data over sound from your C application.
chirp_sdk_errors.h File Reference

Error handling of the SDK. More...

#include "chirp_sdk.h"

Go to the source code of this file.

Enumerations

enum  chirp_sdk_error_code_t {
  CHIRP_SDK_OK = 0, CHIRP_SDK_OUT_OF_MEMORY, CHIRP_SDK_NOT_INITIALISED, CHIRP_SDK_INTERNAL_ERROR,
  CHIRP_SDK_MEMORY_LEAK, CHIRP_SDK_RECEIVING_NOT_AVAILABLE, CHIRP_SDK_NOT_RUNNING, CHIRP_SDK_ALREADY_RUNNING,
  CHIRP_SDK_ALREADY_STOPPED, CHIRP_SDK_ALREADY_SENDING, CHIRP_SDK_INVALID_SAMPLE_RATE = 20, CHIRP_SDK_NULL_BUFFER,
  CHIRP_SDK_NULL_POINTER, CHIRP_SDK_CHANNEL_NOT_SUPPORTED, CHIRP_SDK_INVALID_FREQUENCY_CORRECTION, CHIRP_SDK_PROCESSING_ERROR,
  CHIRP_SDK_INVALID_KEY = 40, CHIRP_SDK_INVALID_SECRET, CHIRP_SDK_INVALID_CREDENTIALS, CHIRP_SDK_MISSING_SIGNATURE,
  CHIRP_SDK_INVALID_SIGNATURE, CHIRP_SDK_MISSING_CONFIG, CHIRP_SDK_INVALID_CONFIG, CHIRP_SDK_EXPIRED_CONFIG,
  CHIRP_SDK_INVALID_VERSION, CHIRP_SDK_INVALID_PROJECT, CHIRP_SDK_INVALID_CONFIG_CHARACTER, CHIRP_SDK_PAYLOAD_EMPTY_MESSAGE = 80,
  CHIRP_SDK_PAYLOAD_INVALID_MESSAGE, CHIRP_SDK_PAYLOAD_UNKNOWN_SYMBOLS, CHIRP_SDK_PAYLOAD_DECODE_FAILED, CHIRP_SDK_PAYLOAD_TOO_LONG,
  CHIRP_SDK_PAYLOAD_TOO_SHORT, CHIRP_SDK_INVALID_VOLUME = 99, CHIRP_SDK_UNKNOWN_ERROR = 100, CHIRP_SDK_NETWORK_ERROR = 200,
  CHIRP_SDK_NETWORK_NO_NETWORK, CHIRP_SDK_NETWORK_PERMISSIONS_NOT_GRANTED, CHIRP_SDK_ACCOUNT_DISABLED, CHIRP_SDK_AUDIO_IO_ERROR,
  CHIRP_SDK_SENDING_NOT_ENABLED, CHIRP_SDK_RECEIVING_NOT_ENABLED, CHIRP_SDK_DEVICE_IS_MUTED
}
 

Functions

const PUBLIC_SYM char * chirp_sdk_error_code_to_string (chirp_sdk_error_code_t err)
 

Detailed Description

Error handling of the SDK.


ASIO CONFIDENTIAL

All contents are strictly proprietary, and not for copying, resale, or use outside of the agreed license.

Copyright © 2011-2019, Asio Ltd. All rights reserved.


Enumeration Type Documentation

◆ chirp_sdk_error_code_t

Various error codes the SDK can return. Note that some of the values don't apply on this SDK.

Enumerator
CHIRP_SDK_OK 

No error.

CHIRP_SDK_OUT_OF_MEMORY 

The SDK ran out of memory.

CHIRP_SDK_NOT_INITIALISED 

The SDK hasn't been initialised, did you forget to set the config?

CHIRP_SDK_INTERNAL_ERROR 

An internal error prevented the SDK from initialising correctly.

CHIRP_SDK_MEMORY_LEAK 

Some memory hasn't been freed leading to some leaks.

CHIRP_SDK_RECEIVING_NOT_AVAILABLE 

Receiving mode has been disabled and is not available.

CHIRP_SDK_NOT_RUNNING 

The SDK is not running.

CHIRP_SDK_ALREADY_RUNNING 

The SDK is already running.

CHIRP_SDK_ALREADY_STOPPED 

The SDK has already stopped.

CHIRP_SDK_ALREADY_SENDING 

The SDK is already sending.

CHIRP_SDK_INVALID_SAMPLE_RATE 

The sample rate is invalid (it must respect Nyquist law).

CHIRP_SDK_NULL_BUFFER 

One of the parameters is a NULL buffer.

CHIRP_SDK_NULL_POINTER 

One of the parameters is a NULL pointer.

CHIRP_SDK_CHANNEL_NOT_SUPPORTED 

The channel asked is bigger than the maximum one authorised by the config being used.

CHIRP_SDK_INVALID_FREQUENCY_CORRECTION 

Invalid frequency correction value.

CHIRP_SDK_PROCESSING_ERROR 

An internal issue happened when processing.

CHIRP_SDK_INVALID_KEY 

Invalid application key.

CHIRP_SDK_INVALID_SECRET 

Invalid application secret.

CHIRP_SDK_INVALID_CREDENTIALS 

Invalid application credentials.

CHIRP_SDK_MISSING_SIGNATURE 

Signature is missing from the config.

CHIRP_SDK_INVALID_SIGNATURE 

Signature couldn't be verified.

CHIRP_SDK_MISSING_CONFIG 

Config information is missing.

CHIRP_SDK_INVALID_CONFIG 

Config information is invalid.

CHIRP_SDK_EXPIRED_CONFIG 

This config has expired.

CHIRP_SDK_INVALID_VERSION 

This config was generated for a different version. Please visit https://developers.chirp.io to upgrade your SDK.

CHIRP_SDK_INVALID_PROJECT 

This config was generated for a different project.

CHIRP_SDK_INVALID_CONFIG_CHARACTER 

Your config contains one or many unknown character(s).

CHIRP_SDK_PAYLOAD_EMPTY_MESSAGE 

The payload is empty.

CHIRP_SDK_PAYLOAD_INVALID_MESSAGE 

The payload is invalid.

CHIRP_SDK_PAYLOAD_UNKNOWN_SYMBOLS 

The payload contains unknown symbols.

CHIRP_SDK_PAYLOAD_DECODE_FAILED 

Couldn't decode the payload.

CHIRP_SDK_PAYLOAD_TOO_LONG 

The payload's length is longer than the maximum one authorised by the config being used.

CHIRP_SDK_PAYLOAD_TOO_SHORT 

The payload's length is shorter than the minimum one authorised by the config being used..

CHIRP_SDK_INVALID_VOLUME 

Volume value is incorrect.

CHIRP_SDK_UNKNOWN_ERROR 

The SDK has reported an unknown error.

CHIRP_SDK_NETWORK_ERROR 

"Network error."

CHIRP_SDK_NETWORK_NO_NETWORK 

"Couldn't reach the server, please check your network connection."

CHIRP_SDK_NETWORK_PERMISSIONS_NOT_GRANTED 

"Network permissions were not granted by the application or user. Please add network permissions to your application, or contact sales@chirp.io to request completely offline operation."

CHIRP_SDK_ACCOUNT_DISABLED 

"Your account has been disabled due to an unpaid license. Please contact sales@chirp.io."

CHIRP_SDK_AUDIO_IO_ERROR 

"Audio IO error."

CHIRP_SDK_SENDING_NOT_ENABLED 

"Send mode hasn't been enabled."

CHIRP_SDK_RECEIVING_NOT_ENABLED 

"Receive mode hasn't been enabled."

CHIRP_SDK_DEVICE_IS_MUTED 

"The device is muted. Cannot send data."

Function Documentation

◆ chirp_sdk_error_code_to_string()

const PUBLIC_SYM char* chirp_sdk_error_code_to_string ( chirp_sdk_error_code_t  err)

Convert a chirp_sdk_error_code_t code to a string describing the error.

Parameters
errThe error code which needs to be detailed.
Returns
The string describing the error code.