STM32H750B-DK - How well supported ?

Post here all questions related to STM32 core if you can't find a relevant section!
Bulek44
Posts: 16
Joined: Mon Feb 22, 2021 3:42 pm

STM32H750B-DK - How well supported ?

Post by Bulek44 »

Hello,

I'm more or less newbie in STM32Duino... I have STM32H750B-DK board and would love to program it using STM32Duino library.
I've quickly tried with several 750 chips, but simple blink LED example below doesn't blink (work), or at least I think it doesn't.

Any advice what can be expected to work on this microcontroller? Should GPIO work ? Any other peripherals that should work ?

How can I debug program on assembly level (it seems to work, pc is changing,but I cannot see the code) ?

Thanks in advance,
regards,
Bulek.

Code: Select all

int i;

void setup() {
  // put your setup code here, to run once:

  // initialize digital pins PI13,PJ2 as outputs.
  pinMode(PI_13, OUTPUT);
  pinMode(PJ_2, OUTPUT);


}

void loop() {
  // put your main code here, to run repeatedly:
  digitalWrite(PI_13, HIGH);   // turn the LED on (HIGH is the voltage level)
  digitalWrite(PJ_2, LOW);    // turn the LED off by making the voltage LOW

  delay(1000);              // wait for a second
  
  i++;
  digitalWrite(PI_13, LOW);    // turn the LED off by making the voltage LOW
  digitalWrite(PJ_2, HIGH);   // turn the LED on (HIGH is the voltage level)

  delay(1000);              // wait for a second

}

ag123
Posts: 1655
Joined: Thu Dec 19, 2019 5:30 am
Answers: 24

Re: STM32H750B-DK - How well supported ?

Post by ag123 »

you can take a look at the list
https://github.com/stm32duino/Arduino_C ... 2h7-boards
you can try selecting an existing board that has the soc or is 'similar' to your board.
a main thing is the crystal frequency for that board needs to match the crystal frequency on your board, otherwise thing would probably works goofy e.g. that usb 'don't work' (wrong frequency).

and do review the wiki
https://github.com/stm32duino/Arduino_Core_STM32/wiki
https://github.com/stm32duino/Arduino_C ... ng-Started

a thing is if the frequency of the selected board don't match your board, you may need to go into
https://github.com/stm32duino/Arduino_C ... figuration

Code: Select all

SystemClock_Config(void)
in the variant and update the PLL multipliers so that the multipliers are based on your crystal for the system clock and peripherals clocks
Bulek44
Posts: 16
Joined: Mon Feb 22, 2021 3:42 pm

Re: STM32H750B-DK - How well supported ?

Post by Bulek44 »

Hello,

thanks for info... Will study sources...

But just out of curiosity, should GPIO work regardless of potential clock mis-setup ?

Thanks,
regards,
Bulek.
Bulek44
Posts: 16
Joined: Mon Feb 22, 2021 3:42 pm

Re: STM32H750B-DK - How well supported ?

Post by Bulek44 »

Hello,

I've tried to debug and it seems that something is wrong with definitions of pins...

I've chosen one of Generic H750 boards, but they all seem to be variants with less pins than mine (STM32H750XB - X has 240 balls).

On board, two user LEDS are on PI-13 and PJ-2 pins...

When I debug this part, it seems that digitalPinToPinName converts port and pin number into NC value, which look like "undefined" to me:

Code: Select all

void pinMode(uint32_t ulPin, uint32_t ulMode)
{
  PinName p = digitalPinToPinName(ulPin);

  if (p != NC) { ...
p gets value of NC and nothing is done for initialization.

I guess I need either to add custom definition for this board or find similar board, but have no clue where to start, since all H750 boards are variants with less pins, and I guess also with less GPIO ports.

Any advice ?

Thanks in advance,
regards,
Bulek.
User avatar
fpiSTM
Posts: 1738
Joined: Wed Dec 11, 2019 7:11 pm
Answers: 91
Location: Le Mans
Contact:

Re: STM32H750B-DK - How well supported ?

Post by fpiSTM »

https://github.com/stm32duino/Arduino_C ... ric.h#L159

https://github.com/stm32duino/Arduino_C ... 4C2-L164C2

They are available. .Main point is this variant is not present. You will have to add it. See the wiki to know how to add it.
Bulek44
Posts: 16
Joined: Mon Feb 22, 2021 3:42 pm

Re: STM32H750B-DK - How well supported ?

Post by Bulek44 »

Hello,

thanks for the hint... I'm getting closer...

Sorry for my newbie questions, but would kindly ask for a short answer.

The files you have pointed to me are already in generic variant folder
Arduino_Core_STM32/variants/STM32H7xx
/H742X(G-I)H_H743X(G-I)H_H745X(G-I)H_H747X(G-I)H_H750XBH_H753XIH_H755XIH_H757XIH
and H750XBH fits my board. Do I still have to add new variant for this specific board ?

Thanks,
Bulek.
User avatar
fpiSTM
Posts: 1738
Joined: Wed Dec 11, 2019 7:11 pm
Answers: 91
Location: Le Mans
Contact:

Re: STM32H750B-DK - How well supported ?

Post by fpiSTM »

Bulek44
Posts: 16
Joined: Mon Feb 22, 2021 3:42 pm

Re: STM32H750B-DK - How well supported ?

Post by Bulek44 »

Thanks for info,

have read the document... It's about adding Generic variants (boards are "in construction").

If I have understood right :
1. I've copied
# Generic H750XBHx
GenH7.menu.pnum.GENERIC_H750XBHX=Generic H750XBHx
GenH7.menu.pnum.GENERIC_H750XBHX.upload.maximum_size=131072
GenH7.menu.pnum.GENERIC_H750XBHX.upload.maximum_data_size=884736
GenH7.menu.pnum.GENERIC_H750XBHX.build.board=GENERIC_H750XBHX
GenH7.menu.pnum.GENERIC_H750XBHX.build.product_line=STM32H750xx
GenH7.menu.pnum.GENERIC_H750XBHX.build.variant=STM32H7xx/H742X(G-I)H_H743X(G-I)H_H745X(G-I)H_H747X(G-I)H_H750XBH_H753XIH_H755XIH_H757XIH
to main boards.txt file in Arduino15\packages\STMicroelectronics\hardware\stm32\2.6.0...

But I can't see this entry (have restarted IDE several times in Windows). Is something else needed for this board to appear in menu ?

Thanks.
User avatar
fpiSTM
Posts: 1738
Joined: Wed Dec 11, 2019 7:11 pm
Answers: 91
Location: Le Mans
Contact:

Re: STM32H750B-DK - How well supported ?

Post by fpiSTM »

If you use ide 2.x yes. You have to delete some cache files. It is a bug of the ide. I will give you more info tomorrow.
Bulek44
Posts: 16
Joined: Mon Feb 22, 2021 3:42 pm

Re: STM32H750B-DK - How well supported ?

Post by Bulek44 »

Update: LED blinking works...

Steps needed :
- to "reload" boards.txt user data cache needs to be deleted
mine was here : C:\Users\UserName\AppData\Roaming\arduino-ide

- script.ld was missing - have added one from CubeIDE project for this board

Now LED blinking works... Will dig futher and report here...

Thanks,
regards,
Bulek.
Post Reply

Return to “General discussion”