gnssmax 2.0.0.0
GNSS MAX Click Driver

API for configuring and manipulating GNSS MAX Click driver. More...

Topics

 GNSS MAX Device Settings
 Settings for registers of GNSS MAX Click driver.
 
 GNSS MAX MikroBUS Map
 MikroBUS pin mapping of GNSS MAX Click driver.
 

Functions

void gnssmax_cfg_setup (gnssmax_cfg_t *cfg)
 GNSS MAX configuration object setup function.
 
err_t gnssmax_init (gnssmax_t *ctx, gnssmax_cfg_t *cfg)
 GNSS MAX initialization function.
 
err_t gnssmax_default_cfg (gnssmax_t *ctx)
 GNSS MAX default configuration function.
 
err_t gnssmax_generic_write (gnssmax_t *ctx, char *data_buf, uint16_t len)
 GNSS MAX data writing function.
 
err_t gnssmax_generic_read (gnssmax_t *ctx, char *data_buf, uint16_t max_len)
 GNSS MAX data reading function.
 
void gnssmax_reset (gnssmax_t *ctx)
 GNSS MAX reset function.
 
void gnssmax_set_external_interrupt (gnssmax_t *ctx, uint8_t state)
 GNSS MAX sets state of external interrupt.
 
uint8_t gnssmax_get_pps (gnssmax_t *ctx)
 GNSS MAX reads timestamp pin state.
 

Detailed Description

API for configuring and manipulating GNSS MAX Click driver.

Any initialization code needed for MCU to function properly. Do not remove this line or clock might not be set correctly.

Function Documentation

◆ gnssmax_cfg_setup()

void gnssmax_cfg_setup ( gnssmax_cfg_t * cfg)

GNSS MAX configuration object setup function.

This function initializes click configuration structure to initial values.

Parameters
[out]cfg: Click configuration structure. See gnssmax_cfg_t object definition for detailed explanation.
Returns
Nothing.
Note
The all used pins will be set to unconnected state.

◆ gnssmax_default_cfg()

err_t gnssmax_default_cfg ( gnssmax_t * ctx)

GNSS MAX default configuration function.

This function executes a default configuration of GNSS MAX click board.

Parameters
[in]ctx: Click context object. See gnssmax_t object definition for detailed explanation.
Returns
  • 0 - Success,
  • -1 - Error.
See #err_t definition for detailed explanation.
Note
This function can consist any necessary configuration or setting to put device into operating mode.

◆ gnssmax_generic_read()

err_t gnssmax_generic_read ( gnssmax_t * ctx,
char * data_buf,
uint16_t max_len )

GNSS MAX data reading function.

This function reads a desired number of data bytes by using UART serial interface.

Parameters
[in]ctx: Click context object. See gnssmax_t object definition for detailed explanation.
[out]data_buf: Output read data.
[in]max_len: Number of bytes to be read.
Returns
  • >0 - Number of data bytes read,
  • <=0 - Error/Empty Ring buffer.
See #err_t definition for detailed explanation.
Note
None.

◆ gnssmax_generic_write()

err_t gnssmax_generic_write ( gnssmax_t * ctx,
char * data_buf,
uint16_t len )

GNSS MAX data writing function.

This function writes a desired number of data bytes by using UART serial interface.

Parameters
[in]ctx: Click context object. See gnssmax_t object definition for detailed explanation.
[in]data_buf: Data buffer for sending.
[in]len: Number of bytes for sending.
Returns
  • >=0 - Success,
  • <0 - Error.
See #err_t definition for detailed explanation.
Note
None.

◆ gnssmax_get_pps()

uint8_t gnssmax_get_pps ( gnssmax_t * ctx)

GNSS MAX reads timestamp pin state.

This function reads logic state of timestamp pin.

Parameters
[out]ctx: Click context object. See gnssmax_t object definition for detailed explanation.
Returns
Timestamp pin state.

◆ gnssmax_init()

err_t gnssmax_init ( gnssmax_t * ctx,
gnssmax_cfg_t * cfg )

GNSS MAX initialization function.

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

Parameters
[out]ctx: Click context object. See gnssmax_t object definition for detailed explanation.
[in]cfg: Click configuration structure. See gnssmax_cfg_t object definition for detailed explanation.
Returns
  • 0 - Success,
  • -1 - Error.
See #err_t definition for detailed explanation.
Note
None.

◆ gnssmax_reset()

void gnssmax_reset ( gnssmax_t * ctx)

GNSS MAX reset function.

This function toggles reset pin to reset module.

Parameters
[in]ctx: Click context object. See gnssmax_t object definition for detailed explanation.
Returns
Nothing

◆ gnssmax_set_external_interrupt()

void gnssmax_set_external_interrupt ( gnssmax_t * ctx,
uint8_t state )

GNSS MAX sets state of external interrupt.

This function sets logic state of ext_int pin.

Parameters
[in]ctx: Click context object. See gnssmax_t object definition for detailed explanation.
[in]state: State of pin to set.
Returns
Nothing