Microchip® Advanced Software Framework

iisc.c File Reference

IIS driver for SAM.

This file defines a useful set of functions for the IIS on SAM devices.

Copyright (c) 2014-2018 Microchip Technology Inc. and its subsidiaries.

#include "iisc.h"
#include "sysclk.h"
#include "sleepmgr.h"

Functions

static enum status_code _iis_set_config (struct iis_dev_inst *const dev_inst)
 
void iis_clear_status (struct iis_dev_inst *dev_inst, iis_interrupt_source_t source)
 Clear the IIS status value. More...
 
void iis_disable (struct iis_dev_inst *const dev_inst)
 Disable the IIS module. More...
 
void iis_disable_interrupt (struct iis_dev_inst *const dev_inst, iis_interrupt_source_t source)
 Disable the specified interrput sources. More...
 
void iis_enable (struct iis_dev_inst *const dev_inst)
 Enable the IIS module. More...
 
void iis_enable_interrupt (struct iis_dev_inst *const dev_inst, iis_interrupt_source_t source)
 Enable the specified interrput sources. More...
 
enum status_code iis_init (struct iis_dev_inst *const dev_inst, Iisc *iisc, struct iis_config *const cfg)
 Initialize and configure the IIS module. More...
 
static void iis_interrupt_handler (void)
 Internal interrupt handler for IIS. More...
 
enum status_code iis_read (struct iis_dev_inst *const dev_inst, uint32_t *data)
 Read a single message of data. More...
 
void iis_set_callback (struct iis_dev_inst *const dev_inst, iis_interrupt_source_t source, iis_callback_t callback, uint8_t irq_level)
 Set callback for IIS. More...
 
enum status_code iis_write (struct iis_dev_inst *const dev_inst, uint32_t data)
 Write a single message of data. More...
 
void IISC_Handler (void)
 Interrupt handler for IIS. More...
 

Variables

struct iis_dev_inst_iis_instance
 
iis_callback_t iis_callback_pointer [_IIS_INTERRUPT_SOURCE_NUM]
 IIS callback function pointer array. More...
 

static void iis_interrupt_handler ( void  )
static
void IISC_Handler ( void  )

Interrupt handler for IIS.

References iis_interrupt_handler().

struct iis_dev_inst* _iis_instance

IIS callback function pointer array.

Referenced by iis_interrupt_handler(), and iis_set_callback().