Firmware SDK
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
bc_module_climate

Driver for BigClown Climate Module. More...

Enumerations

enum  bc_module_climate_event_t {
  BC_MODULE_CLIMATE_EVENT_ERROR_THERMOMETER = 0,
  BC_MODULE_CLIMATE_EVENT_ERROR_HYGROMETER = 1,
  BC_MODULE_CLIMATE_EVENT_ERROR_LUX_METER = 2,
  BC_MODULE_CLIMATE_EVENT_ERROR_BAROMETER = 3,
  BC_MODULE_CLIMATE_EVENT_UPDATE_THERMOMETER = 4,
  BC_MODULE_CLIMATE_EVENT_UPDATE_HYGROMETER = 5,
  BC_MODULE_CLIMATE_EVENT_UPDATE_LUX_METER = 6,
  BC_MODULE_CLIMATE_EVENT_UPDATE_BAROMETER = 7
}
 Callback events. More...
 

Functions

void bc_module_climate_init (void)
 Initialize BigClown Climate Module.
 
void bc_module_climate_set_event_handler (void(*event_handler)(bc_module_climate_event_t, void *), void *event_param)
 Set callback function. More...
 
void bc_module_climate_set_update_interval_all_sensors (bc_tick_t interval)
 Set measurement interval for all sensors. More...
 
void bc_module_climate_set_update_interval_thermometer (bc_tick_t interval)
 Set measurement interval for thermometer. More...
 
void bc_module_climate_set_update_interval_hygrometer (bc_tick_t interval)
 Set measurement interval for hygrometer. More...
 
void bc_module_climate_set_update_interval_lux_meter (bc_tick_t interval)
 Set measurement interval for lux meter. More...
 
void bc_module_climate_set_update_interval_barometer (bc_tick_t interval)
 Set measurement interval for barometer. More...
 
bool bc_module_climate_measure_all_sensors (void)
 Start measurement of all sensors manually. More...
 
bool bc_module_climate_measure_thermometer (void)
 Start thermometer measurement manually. More...
 
bool bc_module_climate_measure_hygrometer (void)
 Start hygrometer measurement manually. More...
 
bool bc_module_climate_measure_lux_meter (void)
 Start lux meter measurement manually. More...
 
bool bc_module_climate_measure_barometer (void)
 Start barometer measurement manually. More...
 
bool bc_module_climate_get_temperature_celsius (float *celsius)
 Get measured temperature in degrees of Celsius. More...
 
bool bc_module_climate_get_temperature_fahrenheit (float *fahrenheit)
 Get measured temperature in degrees of Fahrenheit. More...
 
bool bc_module_climate_get_temperature_kelvin (float *kelvin)
 Get measured temperature in kelvin. More...
 
bool bc_module_climate_get_humidity_percentage (float *percentage)
 Get measured humidity as percentage. More...
 
bool bc_module_climate_get_illuminance_lux (float *lux)
 Get measured illuminance in lux. More...
 
bool bc_module_climate_get_altitude_meter (float *meter)
 Get measured altitude in meters. More...
 
bool bc_module_climate_get_pressure_pascal (float *pascal)
 Get measured pressure in Pascal. More...
 

Detailed Description

Driver for BigClown Climate Module.

Enumeration Type Documentation

Callback events.

Enumerator
BC_MODULE_CLIMATE_EVENT_ERROR_THERMOMETER 

Error event for thermometer.

BC_MODULE_CLIMATE_EVENT_ERROR_HYGROMETER 

Error event for hygrometer.

BC_MODULE_CLIMATE_EVENT_ERROR_LUX_METER 

Error event for lux meter.

BC_MODULE_CLIMATE_EVENT_ERROR_BAROMETER 

Error event for barometer.

BC_MODULE_CLIMATE_EVENT_UPDATE_THERMOMETER 

Update event for thermometer.

BC_MODULE_CLIMATE_EVENT_UPDATE_HYGROMETER 

Update event for hygrometer.

BC_MODULE_CLIMATE_EVENT_UPDATE_LUX_METER 

Update event for lux meter.

BC_MODULE_CLIMATE_EVENT_UPDATE_BAROMETER 

Update event for barometer.

Definition at line 12 of file bc_module_climate.h.

Function Documentation

bool bc_module_climate_get_altitude_meter ( float *  meter)

Get measured altitude in meters.

Parameters
[in]meterPointer to variable where result will be stored
Returns
true When value is valid
false When value is invalid

Definition at line 149 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_get_humidity_percentage ( float *  percentage)

Get measured humidity as percentage.

Parameters
[in]percentagePointer to variable where result will be stored
Returns
true When value is valid
false When value is invalid

Definition at line 139 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_get_illuminance_lux ( float *  lux)

Get measured illuminance in lux.

Parameters
[in]luxPointer to variable where result will be stored
Returns
true When value is valid
false When value is invalid

Definition at line 144 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_get_pressure_pascal ( float *  pascal)

Get measured pressure in Pascal.

Parameters
[in]pascalPointer to variable where result will be stored
Returns
true When value is valid
false When value is invalid

Definition at line 154 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_get_temperature_celsius ( float *  celsius)

Get measured temperature in degrees of Celsius.

Parameters
[in]celsiusPointer to variable where result will be stored
Returns
true When value is valid
false When value is invalid

Definition at line 124 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_get_temperature_fahrenheit ( float *  fahrenheit)

Get measured temperature in degrees of Fahrenheit.

Parameters
[in]fahrenheitPointer to variable where result will be stored
Returns
true When value is valid
false When value is invalid

Definition at line 129 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_get_temperature_kelvin ( float *  kelvin)

Get measured temperature in kelvin.

Parameters
[in]kelvinPointer to variable where result will be stored
Returns
true When value is valid
false When value is invalid

Definition at line 134 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_measure_all_sensors ( void  )

Start measurement of all sensors manually.

Returns
true On success
false When other measurement is in progress

Definition at line 77 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_measure_barometer ( void  )

Start barometer measurement manually.

Returns
true On success
false When other measurement is in progress

Definition at line 119 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_measure_hygrometer ( void  )

Start hygrometer measurement manually.

Returns
true On success
false When other measurement is in progress

Definition at line 109 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_measure_lux_meter ( void  )

Start lux meter measurement manually.

Returns
true On success
false When other measurement is in progress

Definition at line 114 of file bc_module_climate.c.

Here is the call graph for this function:

bool bc_module_climate_measure_thermometer ( void  )

Start thermometer measurement manually.

Returns
true On success
false When other measurement is in progress

Definition at line 104 of file bc_module_climate.c.

Here is the call graph for this function:

void bc_module_climate_set_event_handler ( void(*)(bc_module_climate_event_t, void *)  event_handler,
void *  event_param 
)

Set callback function.

Parameters
[in]event_handlerFunction address
[in]event_paramOptional event parameter (can be NULL)

Definition at line 43 of file bc_module_climate.c.

void bc_module_climate_set_update_interval_all_sensors ( bc_tick_t  interval)

Set measurement interval for all sensors.

Parameters
[in]intervalMeasurement interval

Definition at line 49 of file bc_module_climate.c.

Here is the call graph for this function:

void bc_module_climate_set_update_interval_barometer ( bc_tick_t  interval)

Set measurement interval for barometer.

Parameters
[in]intervalMeasurement interval

Definition at line 72 of file bc_module_climate.c.

Here is the call graph for this function:

void bc_module_climate_set_update_interval_hygrometer ( bc_tick_t  interval)

Set measurement interval for hygrometer.

Parameters
[in]intervalMeasurement interval

Definition at line 62 of file bc_module_climate.c.

Here is the call graph for this function:

void bc_module_climate_set_update_interval_lux_meter ( bc_tick_t  interval)

Set measurement interval for lux meter.

Parameters
[in]intervalMeasurement interval

Definition at line 67 of file bc_module_climate.c.

Here is the call graph for this function:

void bc_module_climate_set_update_interval_thermometer ( bc_tick_t  interval)

Set measurement interval for thermometer.

Parameters
[in]intervalMeasurement interval

Definition at line 57 of file bc_module_climate.c.

Here is the call graph for this function: