Microchip® Advanced Software Framework

sau.h File Reference
#include <avr32/io.h>
#include "compiler.h"

Data Structures

struct  sau_map_t
 A type definition of channels and HSB memories to be mapped. More...
 

Macros

#define sau_clear_error_flags(error_flag)   (AVR32_SAU.icr = error_flag)
 Clear the error bits flags in SR. More...
 
#define sau_disable()   (Set_bits(AVR32_SAU.cr, AVR32_SAU_CR_DIS_MASK))
 
#define sau_disable_buserr_resp()
 
#define sau_disable_interrupt(int_source)   (AVR32_SAU.idr = int_source)
 Disable the SAU interrupt. More...
 
#define sau_disable_open_mode()
 
#define sau_enable()   (Set_bits(AVR32_SAU.cr, AVR32_SAU_CR_EN_MASK))
 Enable/Disable the SAU module. More...
 
#define sau_enable_buserr_resp()
 SAU Bus Error Exception response management. More...
 
#define sau_enable_interrupt(int_source)   (AVR32_SAU.ier = int_source)
 Enable the SAU interrupt. More...
 
#define sau_enable_open_mode()
 SAU open mode management. More...
 
#define sau_enter_setup()   (Set_bits(AVR32_SAU.cr, AVR32_SAU_CR_SEN_MASK))
 SAU setup mode management. More...
 
#define sau_exit_setup()   (Set_bits(AVR32_SAU.cr, AVR32_SAU_CR_SDIS_MASK))
 
#define sau_status_check()   (AVR32_SAU.sr & (0xff ^ AVR32_SAU_SR_CAS_MASK))
 Check the error bits flags in SR. More...
 

Functions

bool sau_configure_channels (const sau_map_t saumap, uint32_t size)
 Configs specific HSB memories for a set of channels. More...
 
void sau_disable_channel (unsigned char channel_num)
 
void sau_enable_channel (unsigned char channel_num)
 
void sau_lock_channels (U8 unlock_HSB_cycles, U8 unlock_key)
 Lock SAU channels. More...
 
uint32_t sau_read_channel (unsigned char channel_num)
 Read the HSB memory value by the SAU channel. More...
 
bool sau_unlock_channel (U8 Unlock_channel_number, U8 Unlock_key)
 Unlock an SAU channel. More...
 
void sau_write_channel (uint32_t data, unsigned char channel_num)
 Write the HSB memory value by the SAU channel. More...