how to change LED color in frdm-k22f

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

how to change LED color in frdm-k22f

Jump to solution
1,104 Views
hosseinmoghadda
Contributor III

Hello everybody

I want to change the LED color using the example provided in mqx example folder . I replaced every BSP_LED1(it turns the red LED on) in the file with BSP_LED2 and BSP_LED3 to turn on green and blue LED . when I replaced BSP_LED2 the green LED lite very faint but when I replace BSP_LED3 it didn't light anymore . I will be appreciated if anybody tell me how to do this .

Tags (2)
1 Solution
910 Views
soledad
NXP Employee
NXP Employee

Hi,

If you are using MQX 4.x, could you please try using the code attached?


Have a great day,
Sol

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

View solution in original post

4 Replies
911 Views
soledad
NXP Employee
NXP Employee

Hi,

If you are using MQX 4.x, could you please try using the code attached?


Have a great day,
Sol

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

910 Views
hosseinmoghadda
Contributor III

Hello Soledad

Thanks for your quick reply . I asked that question because I want to write a simple program based on gpio example on mqx/example folder , I want to define 2 switches available on frdmk22f as inputs that when you press each one it turns on corresponding LED . I could solve the mentioned problem and I think it caused by power supply  . I used segger jlink to program and power the board using swd but after that when I supply power from USB  the problem was solved .

I didn't receive your attachment could you resend it .

0 Kudos
Reply
910 Views
hosseinmoghadda
Contributor III

I'm sorry . I could find your attachment here . I saw it first in my inbox and there was no attachment .

0 Kudos
Reply
910 Views
soledad
NXP Employee
NXP Employee

Hi,

Which MQX version are you using???

Regards

Soledad

0 Kudos
Reply