Contiki 2.5
Enumerations | Functions
adc.h File Reference

 Functions to control the ADC of the MCU.
More...

#include <avr/io.h>
#include <stdio.h>
#include <stdint.h>
#include <stdbool.h>

Go to the source code of this file.

Enumerations

enum  adc_trig_t
 Lists the different ways in which the ADC can be triggered. More...
 
enum  adc_ps_t
 Lists a variety of prescalers used with the ADC. More...
 
enum  adc_ref_t
 Lists the ways in which the voltage reference can be configured for use with the ADC.
 
enum  adc_chan_t
 Lists each channel's mask value for the ADC MUX. More...
 
enum  adc_adj_t
 Lists the two ADC adjustment values. More...
 

Functions

int adc_init (adc_chan_t chan, adc_trig_t trig, adc_ref_t ref, adc_ps_t prescale)
 This function will init the ADC with the following parameters. More...
 
void adc_deinit (void)
 This will disable the adc. More...
 
int adc_conversion_start (void)
 This will start an ADC conversion. More...
 
int16_t adc_result_get (adc_adj_t adjust)
 This will read the ADC result during the ADC conversion and return the raw ADC conversion result. More...
 

Detailed Description

 Functions to control the ADC of the MCU.

This is used to read the joystick.

Author
Mike Vidales mavid.nosp@m.a404.nosp@m.@gmai.nosp@m.l.co.nosp@m.m

Definition in file adc.h.

Enumeration Type Documentation

enum adc_adj_t

Lists the two ADC adjustment values.

Definition at line 99 of file adc.h.

enum adc_chan_t

Lists each channel's mask value for the ADC MUX.

Definition at line 87 of file adc.h.

enum adc_ps_t

Lists a variety of prescalers used with the ADC.

Definition at line 66 of file adc.h.

enum adc_trig_t

Lists the different ways in which the ADC can be triggered.

Definition at line 54 of file adc.h.