LPC5528 GPIO "Dead pin"

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

LPC5528 GPIO "Dead pin"

Jump to solution
5,491 Views
jplathuile
Contributor III

Hi,

Strange behavior on PIO1_10 on LPC5528.
Doing :

BOARD_INITPINS_PWR_Down_PORT=1

BOARD_INITPINS_PWR_Down_PIN=10
GPIO_PinWrite(BOARD_INITPINS_PWR_Down_GPIO, BOARD_INITPINS_PWR_Down_PORT, BOARD_INITPINS_PWR_Down_PIN, 1);

Pin stay at 0, and reading base->B [port] in debug windows show the pin at 0.

This pin can be configured as FLEXCOMM1 that I did for testing, and stay at 0 during SPI communication.

On the board the pin is not short to GND.

When redirecting that connection to another (PIO0-24 for the case) everything come right.
On the rest of the board I use 10's of other pin configured in the same manner and everything is fine.

What happened for that specific PIO1_10?

Regards

JP

Labels (1)
0 Kudos
Reply
1 Solution
5,284 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello JP,

Which version of IDE do you used? I test LPC5528 project, the register memory view is the same with Lpc55s18.

Any way , do not check w[10], mainly check the address  0x4008 02a.

And I also use DS measure the P1_10 pin, it can set to 1, it can toggle, there is no problem. see my attachment video.

Recommend use my project, then use logical measure the p1_10. If still not work, check your hardware.

 

 

 

BR

Alice

View solution in original post

0 Kudos
Reply
10 Replies
5,285 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello JP,

Which version of IDE do you used? I test LPC5528 project, the register memory view is the same with Lpc55s18.

Any way , do not check w[10], mainly check the address  0x4008 02a.

And I also use DS measure the P1_10 pin, it can set to 1, it can toggle, there is no problem. see my attachment video.

Recommend use my project, then use logical measure the p1_10. If still not work, check your hardware.

 

 

 

BR

Alice

0 Kudos
Reply
5,275 Views
jplathuile
Contributor III

Hi,

I belive you, what is important is that this pin move on your board, and the same program does not make it move on my board so i have to conclude that my pin is defective. Every thing else work very fine i have strapped this pin on an other.

Regards

JP

0 Kudos
Reply
5,469 Views
jplathuile
Contributor III

Hi,

The pin configuration is made with the configuration tool from mcuxpresso. And the clock is enabled, the pin init is in right mode (Altfunc 0).
on the scope the output stay at 0.0.

In file attached there is a very basic code, direct from Mcuxpresso:

the second pin move but PIO1-10 is still dead!!!

if the pin was burnt by ESD will base->B [port] show 0 ?

Regards

JP

 

 

 

 

Regards

JP

0 Kudos
Reply
5,458 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello JP,

How do you read the register?

I have checked on my side, the PIO1_10 state is 1:

Alice_Yang_0-1638949150985.png

 

For your code,  change pin states too fast, you can just set it to 1 to check.

while (1) {
GPIO_PinWrite(BOARD_INITPINS_Test_GPIO, BOARD_INITPINS_Test_PORT, BOARD_INITPINS_Test_PIN, 0);
GPIO_PinWrite(BOARD_INITPINS_Test_GPIO, BOARD_INITPINS_Test_PORT, BOARD_INITPINS_Test_PIN, 1);

GPIO_PinWrite(BOARD_INITPINS_Test2_GPIO, BOARD_INITPINS_Test2_PORT, BOARD_INITPINS_Test2_PIN, 0);
GPIO_PinWrite(BOARD_INITPINS_Test2_GPIO, BOARD_INITPINS_Test2_PORT, BOARD_INITPINS_Test2_PIN, 1);
}

 

0 Kudos
Reply
5,452 Views
jplathuile
Contributor III

Hi,


I check in fsl_gpio.h:

static inline void GPIO_PinWrite(GPIO_Type *base, uint32_t port, uint32_t pin, uint8_t output)
{
 base->B[port][pin] = output;
} <- break points

at the break point i check base.B[1]
other pins are correct P1_10 stay at 0.

if you think it is because it is too fast

just
GPIO_PinWrite(BOARD_INITPINS_Test_GPIO, BOARD_INITPINS_Test_PORT, BOARD_INITPINS_Test_PIN, 1);
out of the loop
does not pass PIO1_10 to one

but other pin test2 switch well on the scope and at the debug BP

Using your window "Peripherals"

i can see SET1.SETP that move and display 0x400 at 1

but PIN1.PORT does not.

So i thing my chip has a problem, it came from mouser, i am "esd aware" and as soon as i had opened the bag i had soldered it with minimum manipulation.

In anyway i have made a strap on another pin and it is ok.

Regards

JP

 

0 Kudos
Reply
5,378 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello,

 

Which IDE do you used? Please take a screenshot about the data of register you got. 

Pay attention the GPIO port register address of P1_10.

Alice_Yang_0-1639371380280.png

 

 

BR

Alice

 

0 Kudos
Reply
5,371 Views
jplathuile
Contributor III

Hi,

Here are 2 "screencasts".

My debug probe is MCU-link

Regards

JP

0 Kudos
Reply
5,351 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello ,

I take  a video on my side,  please see my attachment.

Pay attention, it seems there is issue in Peripherals view with MCUXpresso IDE v11.4.0. 

so just  notice the address of 0x4008 02a

Alice_Yang_0-1639544069199.png

 

I also attached my project.

 

BR

Alice

0 Kudos
Reply
5,343 Views
jplathuile
Contributor III

Hi,

Despite your are using a 55S28, i can import and run your project on my 5528. That is what i did... and W[10] stay at 0.0.

your W[10] register is at 4008C028 mine at 4008D028 !. At 4008C028 i have B[40] witch stay a 0 (on your project )

But it is not a problem of debugger it is that the pin stay at 0 on the card.
I think that there are register that reflect what should be on the port (SET register) and register that reflect what is really on the port (B).
For my case i thing the pin is fried and do not respond.

Regards

JP

0 Kudos
Reply
5,477 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello jplathuile,

Have you enable port clock, and initialize the pin , refer to below code to configure:

/* Init output LED GPIO. */
GPIO_PortInit(GPIO, APP_BOARD_TEST_LED_PORT);
GPIO_PortInit(GPIO, APP_SW_PORT);
GPIO_PinInit(GPIO, APP_BOARD_TEST_LED_PORT, APP_BOARD_TEST_LED_PIN, &led_config);
GPIO_PinWrite(GPIO, APP_BOARD_TEST_LED_PORT, APP_BOARD_TEST_LED_PIN, 1);

Use Oscilloscope measure the pin output.

If still have issue, please provide the whole project, and show the result using a picture .

 

BR

Alice

0 Kudos
Reply