esp32[c3|c6|h2]: Update docs for efuse driver
This commit is contained in:
parent
35ace4196f
commit
a49a5df5ba
7 changed files with 151 additions and 3 deletions
|
@ -142,6 +142,43 @@ disables the NuttShell to get the best possible score.
|
|||
.. note:: As the NSH is disabled, the application will start as soon as the
|
||||
system is turned on.
|
||||
|
||||
efuse
|
||||
-----
|
||||
|
||||
This configuration demonstrates the use of the eFuse driver. It can be accessed
|
||||
through the ``/dev/efuse`` device file.
|
||||
Virtual eFuse mode can be used by enabling `CONFIG_ESPRESSIF_EFUSE_VIRTUAL`
|
||||
option to prevent possible damages on chip.
|
||||
|
||||
The following snippet demonstrates how to read MAC address:
|
||||
|
||||
.. code-block:: C
|
||||
|
||||
int fd;
|
||||
int ret;
|
||||
uint8_t mac[6];
|
||||
struct efuse_param_s param;
|
||||
struct efuse_desc_s mac_addr =
|
||||
{
|
||||
.bit_offset = 1,
|
||||
.bit_count = 48
|
||||
};
|
||||
|
||||
const efuse_desc_t* desc[] =
|
||||
{
|
||||
&mac_addr,
|
||||
NULL
|
||||
};
|
||||
param.field = desc;
|
||||
param.size = 48;
|
||||
param.data = mac;
|
||||
|
||||
fd = open("/dev/efuse", O_RDONLY);
|
||||
ret = ioctl(fd, EFUSEIOC_READ_FIELD, ¶m);
|
||||
|
||||
To find offset and count variables for related eFuse,
|
||||
please refer to Espressif's Technical Reference Manuals.
|
||||
|
||||
gpio
|
||||
----
|
||||
|
||||
|
|
|
@ -291,7 +291,7 @@ Bluetooth No
|
|||
CAN/TWAI Yes
|
||||
CDC Console Yes Rev.3
|
||||
DMA Yes
|
||||
eFuse No
|
||||
eFuse Yes Also virtual mode supported
|
||||
GPIO Yes
|
||||
I2C Yes
|
||||
LED_PWM Yes
|
||||
|
|
|
@ -125,6 +125,43 @@ disables the NuttShell to get the best possible score.
|
|||
.. note:: As the NSH is disabled, the application will start as soon as the
|
||||
system is turned on.
|
||||
|
||||
efuse
|
||||
-----
|
||||
|
||||
This configuration demonstrates the use of the eFuse driver. It can be accessed
|
||||
through the ``/dev/efuse`` device file.
|
||||
Virtual eFuse mode can be used by enabling `CONFIG_ESPRESSIF_EFUSE_VIRTUAL`
|
||||
option to prevent possible damages on chip.
|
||||
|
||||
The following snippet demonstrates how to read MAC address:
|
||||
|
||||
.. code-block:: C
|
||||
|
||||
int fd;
|
||||
int ret;
|
||||
uint8_t mac[6];
|
||||
struct efuse_param_s param;
|
||||
struct efuse_desc_s mac_addr =
|
||||
{
|
||||
.bit_offset = 1,
|
||||
.bit_count = 48
|
||||
};
|
||||
|
||||
const efuse_desc_t* desc[] =
|
||||
{
|
||||
&mac_addr,
|
||||
NULL
|
||||
};
|
||||
param.field = desc;
|
||||
param.size = 48;
|
||||
param.data = mac;
|
||||
|
||||
fd = open("/dev/efuse", O_RDONLY);
|
||||
ret = ioctl(fd, EFUSEIOC_READ_FIELD, ¶m);
|
||||
|
||||
To find offset and count variables for related eFuse,
|
||||
please refer to Espressif's Technical Reference Manuals.
|
||||
|
||||
gpio
|
||||
----
|
||||
|
||||
|
|
|
@ -109,6 +109,43 @@ disables the NuttShell to get the best possible score.
|
|||
.. note:: As the NSH is disabled, the application will start as soon as the
|
||||
system is turned on.
|
||||
|
||||
efuse
|
||||
-----
|
||||
|
||||
This configuration demonstrates the use of the eFuse driver. It can be accessed
|
||||
through the ``/dev/efuse`` device file.
|
||||
Virtual eFuse mode can be used by enabling `CONFIG_ESPRESSIF_EFUSE_VIRTUAL`
|
||||
option to prevent possible damages on chip.
|
||||
|
||||
The following snippet demonstrates how to read MAC address:
|
||||
|
||||
.. code-block:: C
|
||||
|
||||
int fd;
|
||||
int ret;
|
||||
uint8_t mac[6];
|
||||
struct efuse_param_s param;
|
||||
struct efuse_desc_s mac_addr =
|
||||
{
|
||||
.bit_offset = 1,
|
||||
.bit_count = 48
|
||||
};
|
||||
|
||||
const efuse_desc_t* desc[] =
|
||||
{
|
||||
&mac_addr,
|
||||
NULL
|
||||
};
|
||||
param.field = desc;
|
||||
param.size = 48;
|
||||
param.data = mac;
|
||||
|
||||
fd = open("/dev/efuse", O_RDONLY);
|
||||
ret = ioctl(fd, EFUSEIOC_READ_FIELD, ¶m);
|
||||
|
||||
To find offset and count variables for related eFuse,
|
||||
please refer to Espressif's Technical Reference Manuals.
|
||||
|
||||
gpio
|
||||
----
|
||||
|
||||
|
|
|
@ -278,7 +278,7 @@ Bluetooth No
|
|||
CAN/TWAI Yes
|
||||
DMA Yes
|
||||
ECC No
|
||||
eFuse No
|
||||
eFuse Yes
|
||||
GPIO Yes
|
||||
HMAC No
|
||||
I2C Yes
|
||||
|
|
|
@ -108,6 +108,43 @@ disables the NuttShell to get the best possible score.
|
|||
.. note:: As the NSH is disabled, the application will start as soon as the
|
||||
system is turned on.
|
||||
|
||||
efuse
|
||||
-----
|
||||
|
||||
This configuration demonstrates the use of the eFuse driver. It can be accessed
|
||||
through the ``/dev/efuse`` device file.
|
||||
Virtual eFuse mode can be used by enabling `CONFIG_ESPRESSIF_EFUSE_VIRTUAL`
|
||||
option to prevent possible damages on chip.
|
||||
|
||||
The following snippet demonstrates how to read MAC address:
|
||||
|
||||
.. code-block:: C
|
||||
|
||||
int fd;
|
||||
int ret;
|
||||
uint8_t mac[6];
|
||||
struct efuse_param_s param;
|
||||
struct efuse_desc_s mac_addr =
|
||||
{
|
||||
.bit_offset = 1,
|
||||
.bit_count = 48
|
||||
};
|
||||
|
||||
const efuse_desc_t* desc[] =
|
||||
{
|
||||
&mac_addr,
|
||||
NULL
|
||||
};
|
||||
param.field = desc;
|
||||
param.size = 48;
|
||||
param.data = mac;
|
||||
|
||||
fd = open("/dev/efuse", O_RDONLY);
|
||||
ret = ioctl(fd, EFUSEIOC_READ_FIELD, ¶m);
|
||||
|
||||
To find offset and count variables for related eFuse,
|
||||
please refer to Espressif's Technical Reference Manuals.
|
||||
|
||||
gpio
|
||||
----
|
||||
|
||||
|
|
|
@ -278,7 +278,7 @@ Bluetooth No
|
|||
CAN/TWAI Yes
|
||||
DMA Yes
|
||||
ECC No
|
||||
eFuse No
|
||||
eFuse Yes
|
||||
GPIO Yes
|
||||
HMAC No
|
||||
I2C Yes
|
||||
|
|
Loading…
Reference in a new issue