waterdetect 2.0.0.0

Functions

void waterdetect_cfg_setup (waterdetect_cfg_t *cfg)
 Config Object Initialization function.
 
WATERDETECT_RETVAL waterdetect_init (waterdetect_t *ctx, waterdetect_cfg_t *cfg)
 Initialization function.
 
void waterdetect_default_cfg (waterdetect_t *ctx)
 Click Default Configuration function.
 
uint8_t waterdetect_get_status (waterdetect_t *ctx)
 Get the status of the water detection function.
 

Detailed Description

Function Documentation

◆ waterdetect_cfg_setup()

void waterdetect_cfg_setup ( waterdetect_cfg_t * cfg)

Config Object Initialization function.

Parameters
cfgClick configuration structure.

@description This function initializes click configuration structure to init state.

Note
All used pins will be set to unconnected state.

◆ waterdetect_default_cfg()

void waterdetect_default_cfg ( waterdetect_t * ctx)

Click Default Configuration function.

Parameters
ctxClick object.

@description This function executes default configuration for Water Detect click.

◆ waterdetect_get_status()

uint8_t waterdetect_get_status ( waterdetect_t * ctx)

Get the status of the water detection function.

Parameters
ctxClick object.
Returns
water detect status:
  • 0 : water is detected;
  • 1 : water not detected;

@description Function get the status of the water detection and return status of INT pin on Water Detect Click board.

◆ waterdetect_init()

WATERDETECT_RETVAL waterdetect_init ( waterdetect_t * ctx,
waterdetect_cfg_t * cfg )

Initialization function.

Parameters
waterdetectClick object.
cfgClick configuration structure.

@description This function initializes all necessary pins and peripherals used for this click.