cc2538_pac/gpio_d/
ibe.rs

1#[doc = "Register `IBE` reader"]
2pub type R = crate::R<IbeSpec>;
3#[doc = "Register `IBE` writer"]
4pub type W = crate::W<IbeSpec>;
5#[doc = "Field `IBE` reader - Bits set: Both edges on corresponding pin trigger an interrupt Bits cleared: Interrupt generation event is controlled by GPIOIEV Single edge: Determined by corresponding bit in GPIOIEV register"]
6pub type IbeR = crate::FieldReader;
7#[doc = "Field `IBE` writer - Bits set: Both edges on corresponding pin trigger an interrupt Bits cleared: Interrupt generation event is controlled by GPIOIEV Single edge: Determined by corresponding bit in GPIOIEV register"]
8pub type IbeW<'a, REG> = crate::FieldWriter<'a, REG, 8>;
9impl R {
10    #[doc = "Bits 0:7 - Bits set: Both edges on corresponding pin trigger an interrupt Bits cleared: Interrupt generation event is controlled by GPIOIEV Single edge: Determined by corresponding bit in GPIOIEV register"]
11    #[inline(always)]
12    pub fn ibe(&self) -> IbeR {
13        IbeR::new((self.bits & 0xff) as u8)
14    }
15}
16impl W {
17    #[doc = "Bits 0:7 - Bits set: Both edges on corresponding pin trigger an interrupt Bits cleared: Interrupt generation event is controlled by GPIOIEV Single edge: Determined by corresponding bit in GPIOIEV register"]
18    #[inline(always)]
19    pub fn ibe(&mut self) -> IbeW<IbeSpec> {
20        IbeW::new(self, 0)
21    }
22}
23#[doc = "The IBE register is the interrupt both-edges register. When the corresponding bit in IS is set to detect edges, bits set to high in IBE configure the corresponding pin to detect both rising and falling edges, regardless of the corresponding bit in the IEV (interrupt event register). Clearing a bit configures the pin to be controlled by IEV.\n\nYou can [`read`](crate::Reg::read) this register and get [`ibe::R`](R). You can [`reset`](crate::Reg::reset), [`write`](crate::Reg::write), [`write_with_zero`](crate::Reg::write_with_zero) this register using [`ibe::W`](W). You can also [`modify`](crate::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
24pub struct IbeSpec;
25impl crate::RegisterSpec for IbeSpec {
26    type Ux = u32;
27}
28#[doc = "`read()` method returns [`ibe::R`](R) reader structure"]
29impl crate::Readable for IbeSpec {}
30#[doc = "`write(|w| ..)` method takes [`ibe::W`](W) writer structure"]
31impl crate::Writable for IbeSpec {
32    type Safety = crate::Unsafe;
33    const ZERO_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
34    const ONE_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
35}
36#[doc = "`reset()` method sets IBE to value 0"]
37impl crate::Resettable for IbeSpec {
38    const RESET_VALUE: u32 = 0;
39}