AllJoyn/Samples/BACnetAdapter/bacnet-stack-0.8.2/ports/xplained/ASF/xmega/drivers/adc/adc.h
static inline uint16_t adc_get_unsigned_result (ADC_t * adc,
						  uint8_t ch_mask)
  {
    uint16_t val;
    irqflags_t flags;
    ADC_CH_t *adc_ch;

    adc_ch = adc_get_channel (adc, ch_mask);

    flags = cpu_irq_save ();
    val = adc_ch->RES;
    cpu_irq_restore (flags);

    return val;
  }
/**
 * \brief Get unsigned result from ADC channel
 *
 * Returns the latest conversion result from the ADC channel as an unsigned
 * type, with interrupt protection of the 16-bit read.
 *
 * \param adc Pointer to ADC module.
 * \param ch_mask Mask of ADC channel(s):
 * \arg \c ADC_CHn , where \c n specifies the channel. (Only a single channel
 * can be given in mask)
 *
 * \return Latest conversion result of ADC channel, as unsigned 16-bit integer.
 */
\brief Get unsigned result from ADC channel
Returns the latest conversion result from the ADC channel as an unsigned
type, with interrupt protection of the 16-bit read.

\param adc Pointer to ADC module.
\param ch_mask Mask of ADC channel(s):
\arg \c ADC_CHn , where \c n specifies the channel. (Only a single channel
can be given in mask)

\return Latest conversion result of ADC channel, as unsigned 16-bit integer.
\ brief Get unsigned result from ADC channel Returns the latest conversion result from the ADC channel as an unsigned type with interrupt protection of the 16 - bit read . \ param adc Pointer to ADC module . \ param ch_mask Mask of ADC channel ( s ) : \ arg \ c ADC_CHn where \ c n specifies the channel . ( Only a single channel can be given in mask ) \ return Latest conversion result of ADC channel as unsigned 16 - bit integer .
static inline uint16_t adc_get_unsigned_result (ADC_t * adc,
						  uint8_t ch_mask)
  {
    uint16_t val;
    irqflags_t flags;
    ADC_CH_t *adc_ch;
    adc_ch = adc_get_channel (adc, ch_mask);
    flags = cpu_irq_save ();
    val = adc_ch->RES;
    cpu_irq_restore (flags);
    return val;
  }
static inline uint16_t adc_get_unsigned_result ( ADC_t * adc , uint8_t ch_mask ) { uint16_t val ; irqflags_t flags ; ADC_CH_t * adc_ch ; adc_ch = adc_get_channel ( adc , ch_mask ) ; flags = cpu_irq_save ( ) ; val = adc_ch -> RES ; cpu_irq_restore ( flags ) ; return val ; }
\brief Get unsigned result from ADC channel
 Returns the latest conversion result from the ADC channel as an unsigned
 type, with interrupt protection of the 16-bit read.
\ brief Get unsigned result from ADC channel Returns the latest conversion result from the ADC channel as an unsigned type with interrupt protection of the 16 - bit read .