2021-04-13 10:07 AM
The MCU on my STM32F407-DISCO1 board is being misidentified as STM32F215 / 217.
I'm pretty sure it is in fact STM32F407VG. What could be causing it?
2021-04-13 10:20 AM
I think it's an early part circa 2011, seen as a STM32F457, and perhaps needs special casing
On a DISCO (Rev B) not DISC1 board
2021-04-13 10:36 AM
Not sure about it being STM32F457, but it does seem like the chip is Rev A and the board is Rev B-00.
2021-04-13 10:42 AM
Yep, confirmed in the errata sheet.
2021-04-13 12:15 PM
void CORECheck(void) // sourcer32@gmail.com
{
uint32_t cpuid = SCB->CPUID;
uint32_t var, pat;
printf("CPUID %08X DEVID %03X REVID %04X\n", cpuid, DBGMCU->IDCODE & 0xFFF, (DBGMCU->IDCODE >> 16) & 0xFFFF);
pat = (cpuid & 0x0000000F);
var = (cpuid & 0x00F00000) >> 20;
if ((cpuid & 0xFF000000) == 0x41000000) // ARM
{
switch((cpuid & 0x0000FFF0) >> 4)
{
case 0xC20 : printf("Cortex M0 r%dp%d\n", var, pat); break;
case 0xC60 : printf("Cortex M0+ r%dp%d\n", var, pat); break;
case 0xC21 : printf("Cortex M1 r%dp%d\n", var, pat); break;
case 0xC23 : printf("Cortex M3 r%dp%d\n", var, pat); break;
case 0xC24 : printf("Cortex M4 r%dp%d\n", var, pat); break;
case 0xC27 : printf("Cortex M7 r%dp%d\n", var, pat); break;
default : printf("Unknown CORE\n");
}
}
else
printf("Unknown CORE IMPLEMENTER\n");
}