#[doc = r" Value to write to the register"] pub struct W { bits: u32, } impl super::DTUPD4 { #[doc = r" Writes to the register"] #[inline] pub fn write(&self, f: F) where F: FnOnce(&mut W) -> &mut W, { let bits = self.register.get(); let mut w = W { bits: bits }; f(&mut w); self.register.set(w.bits); } } #[doc = r" Proxy"] pub struct _DTHUPDW<'a> { w: &'a mut W, } impl<'a> _DTHUPDW<'a> { #[doc = r" Writes raw bits to the field"] #[inline] pub unsafe fn bits(self, value: u16) -> &'a mut W { const MASK: u16 = 65535; 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 _DTLUPDW<'a> { w: &'a mut W, } impl<'a> _DTLUPDW<'a> { #[doc = r" Writes raw bits to the field"] #[inline] pub unsafe fn bits(self, value: u16) -> &'a mut W { const MASK: u16 = 65535; const OFFSET: u8 = 16; self.w.bits &= !((MASK as u32) << OFFSET); self.w.bits |= ((value & MASK) as u32) << OFFSET; self.w } } impl W { #[doc = "Bits 0:15 - Dead-Time Value Update for PWMHx Output"] #[inline] pub fn dthupd(&mut self) -> _DTHUPDW { _DTHUPDW { w: self } } #[doc = "Bits 16:31 - Dead-Time Value Update for PWMLx Output"] #[inline] pub fn dtlupd(&mut self) -> _DTLUPDW { _DTLUPDW { w: self } } }