Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions esp32c6/src/pcr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ pub struct RegisterBlock {
#[doc = "0x1c - MSPI_CLK configuration register"]
pub mspi_clk_conf: MSPI_CLK_CONF,
#[doc = "0x20 - I2C configuration register"]
pub i2c_conf: I2C_CONF,
pub i2c0_conf: I2C0_CONF,
#[doc = "0x24 - I2C_SCLK configuration register"]
pub i2c_sclk_conf: I2C_SCLK_CONF,
#[doc = "0x28 - UHCI configuration register"]
Expand Down Expand Up @@ -202,10 +202,10 @@ pub mod mspi_conf;
pub type MSPI_CLK_CONF = crate::Reg<mspi_clk_conf::MSPI_CLK_CONF_SPEC>;
#[doc = "MSPI_CLK configuration register"]
pub mod mspi_clk_conf;
#[doc = "I2C_CONF (rw) register accessor: an alias for `Reg<I2C_CONF_SPEC>`"]
pub type I2C_CONF = crate::Reg<i2c_conf::I2C_CONF_SPEC>;
#[doc = "I2C0_CONF (rw) register accessor: an alias for `Reg<I2C0_CONF_SPEC>`"]
pub type I2C0_CONF = crate::Reg<i2c0_conf::I2C0_CONF_SPEC>;
#[doc = "I2C configuration register"]
pub mod i2c_conf;
pub mod i2c0_conf;
#[doc = "I2C_SCLK_CONF (rw) register accessor: an alias for `Reg<I2C_SCLK_CONF_SPEC>`"]
pub type I2C_SCLK_CONF = crate::Reg<i2c_sclk_conf::I2C_SCLK_CONF_SPEC>;
#[doc = "I2C_SCLK configuration register"]
Expand Down
46 changes: 23 additions & 23 deletions esp32c6/src/pcr/i2c_conf.rs → esp32c6/src/pcr/i2c0_conf.rs
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
#[doc = "Register `I2C_CONF` reader"]
pub struct R(crate::R<I2C_CONF_SPEC>);
#[doc = "Register `I2C0_CONF` reader"]
pub struct R(crate::R<I2C0_CONF_SPEC>);
impl core::ops::Deref for R {
type Target = crate::R<I2C_CONF_SPEC>;
type Target = crate::R<I2C0_CONF_SPEC>;
#[inline(always)]
fn deref(&self) -> &Self::Target {
&self.0
}
}
impl From<crate::R<I2C_CONF_SPEC>> for R {
impl From<crate::R<I2C0_CONF_SPEC>> for R {
#[inline(always)]
fn from(reader: crate::R<I2C_CONF_SPEC>) -> Self {
fn from(reader: crate::R<I2C0_CONF_SPEC>) -> Self {
R(reader)
}
}
#[doc = "Register `I2C_CONF` writer"]
pub struct W(crate::W<I2C_CONF_SPEC>);
#[doc = "Register `I2C0_CONF` writer"]
pub struct W(crate::W<I2C0_CONF_SPEC>);
impl core::ops::Deref for W {
type Target = crate::W<I2C_CONF_SPEC>;
type Target = crate::W<I2C0_CONF_SPEC>;
#[inline(always)]
fn deref(&self) -> &Self::Target {
&self.0
Expand All @@ -28,20 +28,20 @@ impl core::ops::DerefMut for W {
&mut self.0
}
}
impl From<crate::W<I2C_CONF_SPEC>> for W {
impl From<crate::W<I2C0_CONF_SPEC>> for W {
#[inline(always)]
fn from(writer: crate::W<I2C_CONF_SPEC>) -> Self {
fn from(writer: crate::W<I2C0_CONF_SPEC>) -> Self {
W(writer)
}
}
#[doc = "Field `I2C0_CLK_EN` reader - Set 1 to enable i2c apb clock"]
pub type I2C0_CLK_EN_R = crate::BitReader;
#[doc = "Field `I2C0_CLK_EN` writer - Set 1 to enable i2c apb clock"]
pub type I2C0_CLK_EN_W<'a, const O: u8> = crate::BitWriter<'a, I2C_CONF_SPEC, O>;
pub type I2C0_CLK_EN_W<'a, const O: u8> = crate::BitWriter<'a, I2C0_CONF_SPEC, O>;
#[doc = "Field `I2C0_RST_EN` reader - Set 0 to reset i2c module"]
pub type I2C0_RST_EN_R = crate::BitReader;
#[doc = "Field `I2C0_RST_EN` writer - Set 0 to reset i2c module"]
pub type I2C0_RST_EN_W<'a, const O: u8> = crate::BitWriter<'a, I2C_CONF_SPEC, O>;
pub type I2C0_RST_EN_W<'a, const O: u8> = crate::BitWriter<'a, I2C0_CONF_SPEC, O>;
impl R {
#[doc = "Bit 0 - Set 1 to enable i2c apb clock"]
#[inline(always)]
Expand All @@ -57,14 +57,14 @@ impl R {
#[cfg(feature = "impl-register-debug")]
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("I2C_CONF")
f.debug_struct("I2C0_CONF")
.field("i2c0_clk_en", &format_args!("{}", self.i2c0_clk_en().bit()))
.field("i2c0_rst_en", &format_args!("{}", self.i2c0_rst_en().bit()))
.finish()
}
}
#[cfg(feature = "impl-register-debug")]
impl core::fmt::Debug for crate::generic::Reg<I2C_CONF_SPEC> {
impl core::fmt::Debug for crate::generic::Reg<I2C0_CONF_SPEC> {
fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result {
self.read().fmt(f)
}
Expand All @@ -89,22 +89,22 @@ impl W {
self
}
}
#[doc = "I2C configuration register\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [i2c_conf](index.html) module"]
pub struct I2C_CONF_SPEC;
impl crate::RegisterSpec for I2C_CONF_SPEC {
#[doc = "I2C configuration register\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [i2c0_conf](index.html) module"]
pub struct I2C0_CONF_SPEC;
impl crate::RegisterSpec for I2C0_CONF_SPEC {
type Ux = u32;
}
#[doc = "`read()` method returns [i2c_conf::R](R) reader structure"]
impl crate::Readable for I2C_CONF_SPEC {
#[doc = "`read()` method returns [i2c0_conf::R](R) reader structure"]
impl crate::Readable for I2C0_CONF_SPEC {
type Reader = R;
}
#[doc = "`write(|w| ..)` method takes [i2c_conf::W](W) writer structure"]
impl crate::Writable for I2C_CONF_SPEC {
#[doc = "`write(|w| ..)` method takes [i2c0_conf::W](W) writer structure"]
impl crate::Writable for I2C0_CONF_SPEC {
type Writer = W;
const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
}
#[doc = "`reset()` method sets I2C_CONF to value 0x01"]
impl crate::Resettable for I2C_CONF_SPEC {
#[doc = "`reset()` method sets I2C0_CONF to value 0x01"]
impl crate::Resettable for I2C0_CONF_SPEC {
const RESET_VALUE: Self::Ux = 0x01;
}
5 changes: 4 additions & 1 deletion esp32c6/svd/patches/esp32c6.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,10 @@ ASSIST_DEBUG:
name: CORE_0_DRAM0_EXCEPTION_MONITOR_INTR_ENA

PCR:
I2C_CONF:
_modify:
I2C_CONF:
name: I2C0_CONF
I2C0_CONF:
_modify:
I2C_CLK_EN:
name: I2C0_CLK_EN
Expand Down