VSCode extension not checking selected MCU?

Just getting set up with a clean installation of nRF Connect Extension for VSCode.

I created a new application based upon the Basic Blinky app. The only attached DevKit is nRF52dk_nrf52832. However, I accidentally selected the wrong DevKit when I was creating the application. I then built and flashed the application to the nRF52dk_nrf52832 DevKit. It did not work and using the debugger I discovered a hard fault was occurring, as one might expect with the code built for the wrong MCU. I created a new build configuration for the correct MCU, and all worked as expected.

It seems to me the tools should have detected the wrong MCU was being targeted and reported that. 

If I am misunderstanding something, please correct me. To me this seems like it would be a useful feature of the tools.

I am using v2.2.0 SDK and toolchain, and v2022.11.140 extension.

Thank you, so far, I am most impressed with the extension.

Sid

Parents
  • Hi Sid,

    Thanks for the praise and thanks for the suggestion. I'll pass both on to the developers.

    Did you build for two identical MCUs (nRF52832) but in different PCB configurations? Or was the (accidental) target a completely different chip?

    In case of the former: I think the debugger can only query for chip-level information, so my initial thought is that it will be hard to automatically disambiguate between the same chip on different boards.

    In any case, I've tried flashing an nRF52840 application to an nRF5340 and see that the error I got wasn't super clear. I'll ask the team if we can add stricter device recognition.

    Best regards,

    Raoul

Reply
  • Hi Sid,

    Thanks for the praise and thanks for the suggestion. I'll pass both on to the developers.

    Did you build for two identical MCUs (nRF52832) but in different PCB configurations? Or was the (accidental) target a completely different chip?

    In case of the former: I think the debugger can only query for chip-level information, so my initial thought is that it will be hard to automatically disambiguate between the same chip on different boards.

    In any case, I've tried flashing an nRF52840 application to an nRF5340 and see that the error I got wasn't super clear. I'll ask the team if we can add stricter device recognition.

    Best regards,

    Raoul

Children
Related