#[doc = r" Value read from the register"]
pub struct R {
bits: u32,
}
#[doc = r" Value to write to the register"]
pub struct W {
bits: u32,
}
impl super::CSR {
#[doc = r" Modifies the contents of the register"]
#[inline]
pub fn modify<F>(&self, f: F)
where
for<'w> F: FnOnce(&R, &'w mut W) -> &'w mut W,
{
let bits = self.register.get();
let r = R { bits: bits };
let mut w = W { bits: bits };
f(&r, &mut w);
self.register.set(w.bits);
}
#[doc = r" Reads the contents of the register"]
#[inline]
pub fn read(&self) -> R {
R {
bits: self.register.get(),
}
}
#[doc = r" Writes to the register"]
#[inline]
pub fn write<F>(&self, f: F)
where
F: FnOnce(&mut W) -> &mut W,
{
let mut w = W::reset_value();
f(&mut w);
self.register.set(w.bits);
}
#[doc = r" Writes the reset value to the register"]
#[inline]
pub fn reset(&self) {
self.write(|w| w)
}
}
#[doc = r" Value of the field"]
pub struct COMP1ENR {
bits: bool,
}
impl COMP1ENR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
self.bits
}
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
}
#[doc = r" Value of the field"]
pub struct COMP1_INP_DACR {
bits: bool,
}
impl COMP1_INP_DACR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
self.bits
}
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
}
#[doc = r" Value of the field"]
pub struct COMP1MODER {
bits: u8,
}
impl COMP1MODER {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u8 {
self.bits
}
}
#[doc = r" Value of the field"]
pub struct COMP1INSELR {
bits: u8,
}
impl COMP1INSELR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u8 {
self.bits
}
}
#[doc = r" Value of the field"]
pub struct COMP1OUTSELR {
bits: u8,
}
impl COMP1OUTSELR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u8 {
self.bits
}
}
#[doc = r" Value of the field"]
pub struct COMP1POLR {
bits: bool,
}
impl COMP1POLR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
self.bits
}
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
}
#[doc = r" Value of the field"]
pub struct COMP1HYSTR {
bits: u8,
}
impl COMP1HYSTR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u8 {
self.bits
}
}
#[doc = r" Value of the field"]
pub struct COMP1OUTR {
bits: bool,
}
impl COMP1OUTR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
self.bits
}
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
}
#[doc = r" Value of the field"]
pub struct COMP1LOCKR {
bits: bool,
}
impl COMP1LOCKR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
self.bits
}
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
}
#[doc = r" Value of the field"]
pub struct COMP2ENR {
bits: bool,
}
impl COMP2ENR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
self.bits
}
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
}
#[doc = r" Value of the field"]
pub struct COMP2MODER {
bits: u8,
}
impl COMP2MODER {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u8 {
self.bits
}
}
#[doc = r" Value of the field"]
pub struct COMP2INSELR {
bits: u8,
}
impl COMP2INSELR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u8 {
self.bits
}
}
#[doc = r" Value of the field"]
pub struct WNDWENR {
bits: bool,
}
impl WNDWENR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
self.bits
}
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
}
#[doc = r" Value of the field"]
pub struct COMP2OUTSELR {
bits: u8,
}
impl COMP2OUTSELR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u8 {
self.bits
}
}
#[doc = r" Value of the field"]
pub struct COMP2POLR {
bits: bool,
}
impl COMP2POLR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
self.bits
}
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
}
#[doc = r" Value of the field"]
pub struct COMP2HYSTR {
bits: u8,
}
impl COMP2HYSTR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u8 {
self.bits
}
}
#[doc = r" Value of the field"]
pub struct COMP2OUTR {
bits: bool,
}
impl COMP2OUTR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
self.bits
}
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
}
#[doc = r" Value of the field"]
pub struct COMP2LOCKR {
bits: bool,
}
impl COMP2LOCKR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
self.bits
}
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
}
#[doc = r" Proxy"]
pub struct _COMP1ENW<'a> {
w: &'a mut W,
}
impl<'a> _COMP1ENW<'a> {
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 0;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP1_INP_DACW<'a> {
w: &'a mut W,
}
impl<'a> _COMP1_INP_DACW<'a> {
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 1;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP1MODEW<'a> {
w: &'a mut W,
}
impl<'a> _COMP1MODEW<'a> {
#[doc = r" Writes raw bits to the field"]
#[inline]
pub unsafe fn bits(self, value: u8) -> &'a mut W {
const MASK: u8 = 3;
const OFFSET: u8 = 2;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP1INSELW<'a> {
w: &'a mut W,
}
impl<'a> _COMP1INSELW<'a> {
#[doc = r" Writes raw bits to the field"]
#[inline]
pub unsafe fn bits(self, value: u8) -> &'a mut W {
const MASK: u8 = 7;
const OFFSET: u8 = 4;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP1OUTSELW<'a> {
w: &'a mut W,
}
impl<'a> _COMP1OUTSELW<'a> {
#[doc = r" Writes raw bits to the field"]
#[inline]
pub unsafe fn bits(self, value: u8) -> &'a mut W {
const MASK: u8 = 7;
const OFFSET: u8 = 8;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP1POLW<'a> {
w: &'a mut W,
}
impl<'a> _COMP1POLW<'a> {
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 11;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP1HYSTW<'a> {
w: &'a mut W,
}
impl<'a> _COMP1HYSTW<'a> {
#[doc = r" Writes raw bits to the field"]
#[inline]
pub unsafe fn bits(self, value: u8) -> &'a mut W {
const MASK: u8 = 3;
const OFFSET: u8 = 12;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP1LOCKW<'a> {
w: &'a mut W,
}
impl<'a> _COMP1LOCKW<'a> {
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 15;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP2ENW<'a> {
w: &'a mut W,
}
impl<'a> _COMP2ENW<'a> {
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 16;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP2MODEW<'a> {
w: &'a mut W,
}
impl<'a> _COMP2MODEW<'a> {
#[doc = r" Writes raw bits to the field"]
#[inline]
pub unsafe fn bits(self, value: u8) -> &'a mut W {
const MASK: u8 = 3;
const OFFSET: u8 = 18;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP2INSELW<'a> {
w: &'a mut W,
}
impl<'a> _COMP2INSELW<'a> {
#[doc = r" Writes raw bits to the field"]
#[inline]
pub unsafe fn bits(self, value: u8) -> &'a mut W {
const MASK: u8 = 7;
const OFFSET: u8 = 20;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _WNDWENW<'a> {
w: &'a mut W,
}
impl<'a> _WNDWENW<'a> {
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 23;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP2OUTSELW<'a> {
w: &'a mut W,
}
impl<'a> _COMP2OUTSELW<'a> {
#[doc = r" Writes raw bits to the field"]
#[inline]
pub unsafe fn bits(self, value: u8) -> &'a mut W {
const MASK: u8 = 7;
const OFFSET: u8 = 24;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP2POLW<'a> {
w: &'a mut W,
}
impl<'a> _COMP2POLW<'a> {
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 27;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP2HYSTW<'a> {
w: &'a mut W,
}
impl<'a> _COMP2HYSTW<'a> {
#[doc = r" Writes raw bits to the field"]
#[inline]
pub unsafe fn bits(self, value: u8) -> &'a mut W {
const MASK: u8 = 3;
const OFFSET: u8 = 28;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _COMP2LOCKW<'a> {
w: &'a mut W,
}
impl<'a> _COMP2LOCKW<'a> {
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 31;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
impl R {
#[doc = r" Value of the register as raw bits"]
#[inline]
pub fn bits(&self) -> u32 {
self.bits
}
#[doc = "Bit 0 - Comparator 1 enable"]
#[inline]
pub fn comp1en(&self) -> COMP1ENR {
let bits = {
const MASK: bool = true;
const OFFSET: u8 = 0;
((self.bits >> OFFSET) & MASK as u32) != 0
};
COMP1ENR { bits }
}
#[doc = "Bit 1 - COMP1_INP_DAC"]
#[inline]
pub fn comp1_inp_dac(&self) -> COMP1_INP_DACR {
let bits = {
const MASK: bool = true;
const OFFSET: u8 = 1;
((self.bits >> OFFSET) & MASK as u32) != 0
};
COMP1_INP_DACR { bits }
}
#[doc = "Bits 2:3 - Comparator 1 mode"]
#[inline]
pub fn comp1mode(&self) -> COMP1MODER {
let bits = {
const MASK: u8 = 3;
const OFFSET: u8 = 2;
((self.bits >> OFFSET) & MASK as u32) as u8
};
COMP1MODER { bits }
}
#[doc = "Bits 4:6 - Comparator 1 inverting input selection"]
#[inline]
pub fn comp1insel(&self) -> COMP1INSELR {
let bits = {
const MASK: u8 = 7;
const OFFSET: u8 = 4;
((self.bits >> OFFSET) & MASK as u32) as u8
};
COMP1INSELR { bits }
}
#[doc = "Bits 8:10 - Comparator 1 output selection"]
#[inline]
pub fn comp1outsel(&self) -> COMP1OUTSELR {
let bits = {
const MASK: u8 = 7;
const OFFSET: u8 = 8;
((self.bits >> OFFSET) & MASK as u32) as u8
};
COMP1OUTSELR { bits }
}
#[doc = "Bit 11 - Comparator 1 output polarity"]
#[inline]
pub fn comp1pol(&self) -> COMP1POLR {
let bits = {
const MASK: bool = true;
const OFFSET: u8 = 11;
((self.bits >> OFFSET) & MASK as u32) != 0
};
COMP1POLR { bits }
}
#[doc = "Bits 12:13 - Comparator 1 hysteresis"]
#[inline]
pub fn comp1hyst(&self) -> COMP1HYSTR {
let bits = {
const MASK: u8 = 3;
const OFFSET: u8 = 12;
((self.bits >> OFFSET) & MASK as u32) as u8
};
COMP1HYSTR { bits }
}
#[doc = "Bit 14 - Comparator 1 output"]
#[inline]
pub fn comp1out(&self) -> COMP1OUTR {
let bits = {
const MASK: bool = true;
const OFFSET: u8 = 14;
((self.bits >> OFFSET) & MASK as u32) != 0
};
COMP1OUTR { bits }
}
#[doc = "Bit 15 - Comparator 1 lock"]
#[inline]
pub fn comp1lock(&self) -> COMP1LOCKR {
let bits = {
const MASK: bool = true;
const OFFSET: u8 = 15;
((self.bits >> OFFSET) & MASK as u32) != 0
};
COMP1LOCKR { bits }
}
#[doc = "Bit 16 - Comparator 2 enable"]
#[inline]
pub fn comp2en(&self) -> COMP2ENR {
let bits = {
const MASK: bool = true;
const OFFSET: u8 = 16;
((self.bits >> OFFSET) & MASK as u32) != 0
};
COMP2ENR { bits }
}
#[doc = "Bits 18:19 - Comparator 2 mode"]
#[inline]
pub fn comp2mode(&self) -> COMP2MODER {
let bits = {
const MASK: u8 = 3;
const OFFSET: u8 = 18;
((self.bits >> OFFSET) & MASK as u32) as u8
};
COMP2MODER { bits }
}
#[doc = "Bits 20:22 - Comparator 2 inverting input selection"]
#[inline]
pub fn comp2insel(&self) -> COMP2INSELR {
let bits = {
const MASK: u8 = 7;
const OFFSET: u8 = 20;
((self.bits >> OFFSET) & MASK as u32) as u8
};
COMP2INSELR { bits }
}
#[doc = "Bit 23 - Window mode enable"]
#[inline]
pub fn wndwen(&self) -> WNDWENR {
let bits = {
const MASK: bool = true;
const OFFSET: u8 = 23;
((self.bits >> OFFSET) & MASK as u32) != 0
};
WNDWENR { bits }
}
#[doc = "Bits 24:26 - Comparator 2 output selection"]
#[inline]
pub fn comp2outsel(&self) -> COMP2OUTSELR {
let bits = {
const MASK: u8 = 7;
const OFFSET: u8 = 24;
((self.bits >> OFFSET) & MASK as u32) as u8
};
COMP2OUTSELR { bits }
}
#[doc = "Bit 27 - Comparator 2 output polarity"]
#[inline]
pub fn comp2pol(&self) -> COMP2POLR {
let bits = {
const MASK: bool = true;
const OFFSET: u8 = 27;
((self.bits >> OFFSET) & MASK as u32) != 0
};
COMP2POLR { bits }
}
#[doc = "Bits 28:29 - Comparator 2 hysteresis"]
#[inline]
pub fn comp2hyst(&self) -> COMP2HYSTR {
let bits = {
const MASK: u8 = 3;
const OFFSET: u8 = 28;
((self.bits >> OFFSET) & MASK as u32) as u8
};
COMP2HYSTR { bits }
}
#[doc = "Bit 30 - Comparator 2 output"]
#[inline]
pub fn comp2out(&self) -> COMP2OUTR {
let bits = {
const MASK: bool = true;
const OFFSET: u8 = 30;
((self.bits >> OFFSET) & MASK as u32) != 0
};
COMP2OUTR { bits }
}
#[doc = "Bit 31 - Comparator 2 lock"]
#[inline]
pub fn comp2lock(&self) -> COMP2LOCKR {
let bits = {
const MASK: bool = true;
const OFFSET: u8 = 31;
((self.bits >> OFFSET) & MASK as u32) != 0
};
COMP2LOCKR { bits }
}
}
impl W {
#[doc = r" Reset value of the register"]
#[inline]
pub fn reset_value() -> W {
W { bits: 0 }
}
#[doc = r" Writes raw bits to the register"]
#[inline]
pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
self.bits = bits;
self
}
#[doc = "Bit 0 - Comparator 1 enable"]
#[inline]
pub fn comp1en(&mut self) -> _COMP1ENW {
_COMP1ENW { w: self }
}
#[doc = "Bit 1 - COMP1_INP_DAC"]
#[inline]
pub fn comp1_inp_dac(&mut self) -> _COMP1_INP_DACW {
_COMP1_INP_DACW { w: self }
}
#[doc = "Bits 2:3 - Comparator 1 mode"]
#[inline]
pub fn comp1mode(&mut self) -> _COMP1MODEW {
_COMP1MODEW { w: self }
}
#[doc = "Bits 4:6 - Comparator 1 inverting input selection"]
#[inline]
pub fn comp1insel(&mut self) -> _COMP1INSELW {
_COMP1INSELW { w: self }
}
#[doc = "Bits 8:10 - Comparator 1 output selection"]
#[inline]
pub fn comp1outsel(&mut self) -> _COMP1OUTSELW {
_COMP1OUTSELW { w: self }
}
#[doc = "Bit 11 - Comparator 1 output polarity"]
#[inline]
pub fn comp1pol(&mut self) -> _COMP1POLW {
_COMP1POLW { w: self }
}
#[doc = "Bits 12:13 - Comparator 1 hysteresis"]
#[inline]
pub fn comp1hyst(&mut self) -> _COMP1HYSTW {
_COMP1HYSTW { w: self }
}
#[doc = "Bit 15 - Comparator 1 lock"]
#[inline]
pub fn comp1lock(&mut self) -> _COMP1LOCKW {
_COMP1LOCKW { w: self }
}
#[doc = "Bit 16 - Comparator 2 enable"]
#[inline]
pub fn comp2en(&mut self) -> _COMP2ENW {
_COMP2ENW { w: self }
}
#[doc = "Bits 18:19 - Comparator 2 mode"]
#[inline]
pub fn comp2mode(&mut self) -> _COMP2MODEW {
_COMP2MODEW { w: self }
}
#[doc = "Bits 20:22 - Comparator 2 inverting input selection"]
#[inline]
pub fn comp2insel(&mut self) -> _COMP2INSELW {
_COMP2INSELW { w: self }
}
#[doc = "Bit 23 - Window mode enable"]
#[inline]
pub fn wndwen(&mut self) -> _WNDWENW {
_WNDWENW { w: self }
}
#[doc = "Bits 24:26 - Comparator 2 output selection"]
#[inline]
pub fn comp2outsel(&mut self) -> _COMP2OUTSELW {
_COMP2OUTSELW { w: self }
}
#[doc = "Bit 27 - Comparator 2 output polarity"]
#[inline]
pub fn comp2pol(&mut self) -> _COMP2POLW {
_COMP2POLW { w: self }
}
#[doc = "Bits 28:29 - Comparator 2 hysteresis"]
#[inline]
pub fn comp2hyst(&mut self) -> _COMP2HYSTW {
_COMP2HYSTW { w: self }
}
#[doc = "Bit 31 - Comparator 2 lock"]
#[inline]
pub fn comp2lock(&mut self) -> _COMP2LOCKW {
_COMP2LOCKW { w: self }
}
}