BOARD_InitLEDSPins() isn't being called

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 
已解决

BOARD_InitLEDSPins() isn't being called

跳至解决方案
2,099 次查看
aaronm
Contributor IV

I'm using:

MCUXpresso v11.6.1

SDK_2.x_LPC810 version 2.9.0

LPC812M101JDH20J

And after creating a simple "blinky" project, I used a 'scope to watch the pins go up and down as expected.  However, they didn't.  I loaded a binary that I knew worked to confirm the chip itself is working, and that made the pins go up and down, so I know it's not the chip.  I traced it down to BOARD_InitBootPins() in pin_mux.c and found that it's not calling BOARD_InitLEDsPins() which initializes the hardware for output.  When I updated the function manually to call InitLEDs, it works.  My question is: why isn't BOARD_InitLEDsPins() called automatically by the SDK?  Shouldn't the "Pins" portion of the IDE add that when triggered?  Yes, I selected "Update Code."

Thanks!

标签 (1)
0 项奖励
回复
1 解答
2,061 次查看
ErichStyger
Specialist I

Just my 1 cent on this:

to my understanding, it calls board specific things like LEDs/Sensors only if the SDK/Config tools knows it is a board with known components. If you use just a device or chip without SDK for a specific board, it won't call things like initializing the LEDs, because it is unknown if they exist.

Instead manually calling it, you have to enable it here:

ErichStyger_0-1669351619751.png

 

I hope this helps,

Erich

在原帖中查看解决方案

6 回复数
2,084 次查看
Pavel_Hernandez
NXP TechSupport
NXP TechSupport

Hello, 

I review the example in the SDK but unfortunately, I cannot find the function you mentioned, even if I add another GPIO, could you update your SDK, please?

Pavel_Hernandez_0-1669254909096.png

Best regards,
Pavel

 

0 项奖励
回复
2,080 次查看
aaronm
Contributor IV

Hey, Pavel, I'm not using a development board: I'm using an individual chip.  And for that particular chip, here's the SDK builder page, which it shows stops at v2.9.0.  Am I missing something?  Thanks, Aaron

Screen Shot 2022-11-24 at 12.18.20 AM.png

0 项奖励
回复
2,062 次查看
ErichStyger
Specialist I

Just my 1 cent on this:

to my understanding, it calls board specific things like LEDs/Sensors only if the SDK/Config tools knows it is a board with known components. If you use just a device or chip without SDK for a specific board, it won't call things like initializing the LEDs, because it is unknown if they exist.

Instead manually calling it, you have to enable it here:

ErichStyger_0-1669351619751.png

 

I hope this helps,

Erich

2,058 次查看
aaronm
Contributor IV

Oh!  That's new to me, but that's just the thing.  Thanks, Erich!

2,053 次查看
ErichStyger
Specialist I

Yes, NXP changed that some time ago, and I was not aware of it too, so got trapped by it.

Previously, the 'only device no board' SDK came without any pre-pin assignments and even without examples. Now it they come with the examples (which is a good thing!) but as well with 'board pin assignments' which can be confusing. As for myself, the first thing I do if I create a project for my own board, I get rid of all the pre-pin muxing/assignements, as they only clutter my projects, as my boards are different anyway.

 

2,066 次查看
Pavel_Hernandez
NXP TechSupport
NXP TechSupport

Hello,

Thanks for being clear, I downloaded the same SDK and do the test, and have the same result as you mentioned, I will do a report on the Config Tool.

Best regards,
Pavel

0 项奖励
回复