PBI not applied

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

PBI not applied

Jump to solution
2,336 Views
mykytah
Contributor II

Hello everyone,

I am currently trying to use USB2_EN, USB2_PWRFAULT, USB3_EN, USB3_PWRFAULT pins on LS1046 as GPIOs. To do this, I am trying to use the following PBI command:

write 0x0057040c,0x00001111

However, it does not seem to be applied, as when reading the from uboot, I get:

=> md.l 0x0157040c
0157040c: 00330000 00000000 29000000 9e000000 ..3........)....

I have confirmed that manually overwriting it in uboot makes the GPIO work, so now I am wondering, why my PBI commands are not applied (also some other registers seem to be different). 

What is the best way to debug this? The generated binary (see attached) seems to be including the commands. 

Thank you in advance!

Mykyta

0 Kudos
Reply
1 Solution
2,278 Views
mykytah
Contributor II

I was indeed suspecting that something overwrites it:) Finally I found it, in the board configuration there was:

out_be32(&scfg->rcwpmuxcr0, 0x3300);

After removing it, no one overwrites my stuff:) 

Thank you for the hint!

 

View solution in original post

0 Kudos
Reply
4 Replies
2,288 Views
June_Lu
NXP TechSupport
NXP TechSupport

Would that be modified after you set the value in the PMUXCR0 in the PBI?

You could check it by the CodeWarrior TAP before the u-boot start to run.

If you want to use this register you could change it when you need it to confirm it is not changed by the other command. But should not conflict with other function.

Thanks

2,279 Views
mykytah
Contributor II

I was indeed suspecting that something overwrites it:) Finally I found it, in the board configuration there was:

out_be32(&scfg->rcwpmuxcr0, 0x3300);

After removing it, no one overwrites my stuff:) 

Thank you for the hint!

 

0 Kudos
Reply
2,306 Views
kaypotthoff
Contributor I

Hi,

 

you need to set RCW[429] and RCW[430] to 1 before the PBI block.

This enables GPIO4[29] and GPIO4[30].

In your configuration file you can achieve this with:

USB_DRVVBUS=1

USB_PWRFAULT=1

This configures the pins to GPIOs.

 

Best, Kay

2,292 Views
mykytah
Contributor II

Thank you for your answer.

The pins that I am referring to are GPIO4_10, GPIO4_11, GPIO4_12, GPIO4_13 - these are controlled only with setting the SCFG PINMUX register. 

With RCW-controlled pins I do not have any issues.

0 Kudos
Reply