cancel
Showing results for 
Search instead for 
Did you mean: 

Nucleo-C071RB (MB2046B) vs custom board

curiocity
Associate II

Hi,

I have a question that might be helpful for many others as well.

I am currently using the MB2046B development board, which features the STM32C071RB microcontroller, along with STM32CubeMX for code generation.

I also have a custom board that uses the STM32C071CBT6 microcontroller.

Will the same code developed for the MB2046B board (with STM32C071RB) work on my custom board that uses the STM32C071CBT6?

if Not can you please tell me the Why it not works for instant we forgrt about the pins 

3 REPLIES 3
Andrew Neil
Super User

STM32C071RB vs STM32C071CBT6:

AndrewNeil_0-1749544306395.png

https://www.st.com/resource/en/datasheet/stm32c071rb.pdf#page=128

via: https://www.st.com/en/microcontrollers-microprocessors/stm32c071rb.html

 

So the only difference is in the number of pins on the package.

Therefore, so long as you restrict yourself to things which are available on both packages, the same code can run on both.

 

PS:

Of course, you will also have to ensure that your custom board has compatible hardware in corresponding places to the Nucleo.

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.
Imen.D
ST Employee

Hello @curiocity ,

You should consider the hardware differences and check the pin mapping.

The STM32C071CBT6 (LQFP48 package) has fewer pins than the STM32C071RB (LQFP64 package).

If your code uses GPIO pins that are not available on the STM32C071CBT6, you will need to remap or modify your code accordingly. So, I recommend verifying the pinout in STM32CubeMX and ensure that all peripherals (e.g., UART, I2C, SPI, ADC) are mapped to pins that exist on the STM32C071CBT6.

Also, check the clock settings.

When your question is answered, please close this topic by clicking "Accept as Solution".
Thanks
Imen
Andrew Neil
Super User

@curiocity wrote:

Will the same code developed for the MB2046B board (with STM32C071RB) work on my custom board that uses the STM32C071CBT6?


it also depend on what you mean by "the same code".

If you mean the exact same binary - so with no need to recompile for the different boards - then you would need to ensure that all the pin assignments are identical.

But it is also possible to have a single set of code with compile-time options, so that it can be built for either board - giving you a different binary for each board. This gives you more flexibility in pin assignments, but means you have to manage the two variants.

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.