LPC5534: Use P0_22 for USB0_VBUS in ISP

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

LPC5534: Use P0_22 for USB0_VBUS in ISP

Jump to solution
712 Views
OE_
Contributor II

Greetings,

I am using LPC5534 and I'd need to use ISP via USB, however we are only able to connect VBUS on our board to P0_22 which according to Datasheet and ReferenceManual is routable to USB0_VBUS.

It is mentioned in ReferenceManual page 914 that it would be possible to have ISP use P0_22 as VBUS : PIO1_31(if [bit_22] @0x3FC14 is set to 1, use P0_22.

However the mentioned address 0x3FC14 is apparently located in NMPA which seems read-only part of the flash...

Is there a way to have it written so ISP uses P0_22 as VBUS.

Thanks forward

Labels (1)
0 Kudos
1 Solution
598 Views
CarlosGarabito
NXP TechSupport
NXP TechSupport

The 100 pin package has only one pin option for VBUS which will be P1_31, and this is not modificable by the user

View solution in original post

0 Kudos
7 Replies
631 Views
CarlosGarabito
NXP TechSupport
NXP TechSupport

Can you please provide the complete part number the you are using?. What package are you using?. 

0 Kudos
628 Views
OE_
Contributor II
It's a LPC5534JBD100 revision 0A, hence package HLQFP100
Thanks forward
0 Kudos
599 Views
CarlosGarabito
NXP TechSupport
NXP TechSupport

The 100 pin package has only one pin option for VBUS which will be P1_31, and this is not modificable by the user

0 Kudos
596 Views
OE_
Contributor II

Thanks a lot for this information !
Does this concern only the ISP or it also applies for user application?
What about other packages ?

Thanks forward

0 Kudos
575 Views
CarlosGarabito
NXP TechSupport
NXP TechSupport

ISP

0 Kudos
674 Views
OE_
Contributor II

Greetings,

I think we have a misunderstanding there, as I specified, I'm using LPC5534, which doesn't have USB1 according to both datasheet and ReferenceManual, only USB0, so I do not really get why you have mentioned USB1.

My problem is not to have USB0's USB-HID enabled in the Bootloader ISP (because my application gives it 1 as interface argument as described in section 28.2.3 of the ReferenceManual),
but to have the Bootloader ISP configure its USB0 device to use the P0_22 as VBUS (instead of the default P1_31),
which is supposed to be done by editing a memory region which is located in the (read-only) NMPA and not CMPA according to the xlsx file showing the PFR mappings embedded in the ReferenceManual.

Since the flash API seemingly doesn't offer a way to write NMPA, I am wondering why it's mentioned that setting a bit in 0x3FC14 changes the ISP behavior since it's impossible to change this value... or there's an error somewhere in the manual?

Thanks forward

0 Kudos
681 Views
CarlosGarabito
NXP TechSupport
NXP TechSupport

Hi @OE_ 

LPC55 USB0 is Full Speed USB port. The default setting of CMPA turns off the USB0 port. Some users may reconfigure CMPA to enable ISP USB0 in order to use ISP USB0 BOOT, but this is not recommended in practice.

It is mentioned in ReferenceManual page 914 that it would be possible to have ISP use P0_22 as VBUS : PIO1_31(if [bit_22] @0x3FC14 is set to 1, use P0_22.

 If you want to enable the USB0,  as you says, yes, is set to 1. but If you choose this option please be extra careful as you could brick your device.

As says in the manual "The bootloader supports In-System Programming using the USB peripheral. The target is implemented as USB-HID device classes. When transfer data through USB-HID device class, USB-HID does not use framing packets. Instead, the packetization, inherent in the USB protocol itself is used. The ability for the device to NAK Out transfers (until they can be received) provides the required flow control. The built-in CRC of each USB packet provides the required error detection"

So you can use USB1 with Auto ISP mode. . USB1 in ISP mode is identified as a USB input device in the HID section of the device manager.

0 Kudos