cancel
Showing results for 
Search instead for 
Did you mean: 

STM32L412: can't toggle PD2 on a custom board

VasuManiV
Associate III

Hello,

 

Am working on STM32L412RBT6.

We made a custom PCB for our product and Am trying to PD2 as digital output as toggle function.

I can't able to find any high output at PD2. The pin PD2 is always remains low.

Please help me on this 

 

29 REPLIES 29

Yes i saw that. I have tried by changing the jumper position and even i have tried by removing both the jumpers. While removing both the jumpers, i probed at controller pin.

As I said need to check SB16 and SB18 solder bridges. 

SofLit_0-1718295051098.png

 

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

VasuManiV_0-1718295140465.png

Have a look on this. PD2 is at 54th pin. I think you have selected some different series. Am using STM32L412RBT6

 

No I didn't select other series, in my project pin 54 is well PD2, so please check the zip file attached and test the project and don't forget to check the status of SB16/SB18.

SofLit_0-1718295700256.png

 

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

Yeah sure. I will check in the tomorrow morning and will let you know.

Pin 54 is either PB3 or PD2, depending on which particular model of STM32L412 are you using - the suffix is important.

waclawekjan_0-1718301160555.png

So, post a photo of the chip you are using.

Also, for testing, stop execution in debugger, and toggle given GPIOx_ODR pin manually directly in the debugger (of course after checking that the respective GPIOx_MODER is set properly for GPIOx Out).

JW

Hello @SofLit ,

I tried to test your code. But i can't able to open your MX project because am using latest version.
And tried to debug the code from CubeIDE, but it is giving errors. Am uploading my code here, that contains only PD2 toggle function. Can you please check and let me know? 

Yes exactly @waclawek.jan . I found that and i tried to toggle PB3 pin, it is working fine and i can able to see the pulses at 54th pin. So finally our ordered part is wrong. 

So look at your chip, to see, what you have:

AScha3_0-1718605000703.png

AScha3_1-1718605037833.png

AScha3_2-1718605221656.png

 

 

with P or not ? (you should find the P ...)  

 

If you feel a post has answered your question, please click "Accept as Solution".

Yeah Sure