Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
esp32 ,chip Revision check
/*
esp32 ,chip Revision check
thanks:
https://www.esp32.com/viewtopic.php?t=1358
*/
#include "soc/efuse_reg.h"
//
uint8_t getChipRevision(){
return (REG_READ(EFUSE_BLK0_RDATA3_REG) >> EFUSE_RD_CHIP_VER_RESERVE_S ) && EFUSE_RD_CHIP_VER_RESERVE_V;
}
//
void setup() {
Serial.begin(115200);
Serial.println("#Start-Setup");
Serial.printf("Chip rev=%d\n" ,getChipRevision() );
}
void loop() {
// put your main code here, to run repeatedly:
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.