pub type R = crate::R<P0SCSTRrs>;
pub type W = crate::W<P0SCSTRrs>;
pub type HSTART_R = crate::FieldReader<u16>;
pub type HSTART_W<'a, REG> = crate::FieldWriter<'a, REG, 12, u16>;
pub type VSTART_R = crate::FieldReader<u16>;
pub type VSTART_W<'a, REG> = crate::FieldWriter<'a, REG, 12, u16>;
impl R {
#[inline(always)]
pub fn hstart(&self) -> HSTART_R {
HSTART_R::new((self.bits & 0x0fff) as u16)
}
#[inline(always)]
pub fn vstart(&self) -> VSTART_R {
VSTART_R::new(((self.bits >> 16) & 0x0fff) as u16)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("P0SCSTR")
.field("hstart", &self.hstart())
.field("vstart", &self.vstart())
.finish()
}
}
impl W {
#[inline(always)]
pub fn hstart(&mut self) -> HSTART_W<P0SCSTRrs> {
HSTART_W::new(self, 0)
}
#[inline(always)]
pub fn vstart(&mut self) -> VSTART_W<P0SCSTRrs> {
VSTART_W::new(self, 16)
}
}
pub struct P0SCSTRrs;
impl crate::RegisterSpec for P0SCSTRrs {
type Ux = u32;
}
impl crate::Readable for P0SCSTRrs {}
impl crate::Writable for P0SCSTRrs {
type Safety = crate::Unsafe;
}
impl crate::Resettable for P0SCSTRrs {}