Pinmux limitation

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

Pinmux limitation

436 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by JulianCox on Tue Mar 29 02:53:41 MST 2016
I am using a LPC824 for a project that requires 15 I/O pins, 8 of which will be configured as a 8-bit port. To simplify the PCB layout I want to be able to re-assign the GPIO pins using the Initialisation tool. When I select GPIO0 as the focal peripheral all of the pins are pre-assigned and I can find no way to re-assign any of them. How do I re-assign them?
Labels (1)
0 Kudos
9 Replies

403 Views
lpcware
NXP Employee
NXP Employee
bump
0 Kudos

403 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by IanB on Thu Mar 31 04:14:07 MST 2016
I don't remember the 8004 (maybe you started at a very young age), but the 8048 isn't quite such an orderly layout as the 8051 - I checked - that wasn't from memory!

I think we're all agreed - whoever decided on the random pinout for the first device, the one with which all subsequent device must have pin compatibility, has some explaining to do!
0 Kudos

403 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by JulianCox on Thu Mar 31 02:33:50 MST 2016
Why stop there. What about the 8048, or even the 8004, or amI giving my age away?
0 Kudos

403 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by IanB on Wed Mar 30 10:01:04 MST 2016

Quote:
pin compatibility with earlier devices



If you go back far enough you get to the 8051. Let's have pin compatibility with that - that had everything neatly arranged!
0 Kudos

403 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by MikeSimmonds on Wed Mar 30 04:21:16 MST 2016
I have noticed similar stupidities with other devices in the LPC range.
The manual states that the reason is for pin compatibility with earlier devices.
But that just begs the questions as to why those devices were such brain damaged designs.

Mike.
0 Kudos

403 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by IanB on Wed Mar 30 03:44:54 MST 2016
If you external circuitry doesn't pull pins down on startup, try the LPC15xx 48-pin - you have 9 pins in a row (PIO0_0 to PIO0_8) and a comparator.

If PIO0_4 can ever be pulled to 0V whilst the circuit starts up, it won't work, but perhaps you could use 0-3 and 5-8


I've written a parallel-port for LPC11xx with pins in random order, and it's a pain - probably easier to re-do the pcb!
0 Kudos

403 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by JulianCox on Wed Mar 30 03:07:42 MST 2016
Thanks for the information. The device has to be the 32-pin LPC824 as I need a comparator. Ok - so I can't re-assign the GPIO pins. It would have been useful when laying out the board, but it's not the end of the world.
0 Kudos

403 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by lpcxpresso-support on Tue Mar 29 07:12:00 MST 2016
Hi,

The GPIO pins are not multiplexed using the switchmatrix on the LPC824 - this means that each GPIO is assigned to exactly one pin on the package. So as IanB notes, you can't reorder them to run sequentially for example. You can configure the 20pin part to have 8 pins next to each other be GPIOs by reassigning the Reset, SWIO and SWCLK pins to be GPIOs.

This is not recommended as it will make debugging more of a challenge since the Reset, SWIO and SWCLK pins are required to get a debug connection and are not configured by the Switch Matrix either (i.e. can only be assigned to exactly one specific pin each). You'd need to boot into ISP mode (pulling PIO0_12 low on power up) to recover the default pin layout and get access to the SWIO and SWCLK pins, or have the part reconfigure the pinmuxing based on some external signal (eg on a trigger from a spare GPIO).

To reassign the SWIO for example you would select the GPIO0 as the focal peripheral and then select the SWIO pin (Pin 8). The corresponding GPIO will then be highlighted green and can be selected.

[img]https://www.lpcware.com/system/files/pinmux.png[/img]

Ciao,
LPCXpresso Support

0 Kudos

403 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by IanB on Tue Mar 29 03:58:23 MST 2016
Short answer - You don't!

The 8-bit port problem! - are you driving a dot-matrix display, by any chance? I've never had a good explanation as to why the port pins are arranged completely randomly. Going right back to the 8049, 8051, ATmegas and most microchip parts, the ports run consecutively; but not these devices.

If you want 8 consecutive port pins, then look at the LPC12xx (but remember that the inputs are not 5V tolerant).

Next up is the 64-pin version of the LPC15xx. Note that the 48-pin version has PIO0_0 to PIO0_8 all nicely in a row, but someone had the bright idea to spoil it by sticking the ISP-reset pin right in the middle on PIO0_4.

0 Kudos