The final step to Clone Philip Chip LPC87LPC761 Heximal Code its by using the unlocked status of chip to read out the heximal code, in order to do that we need to have clear idea about the I/O port definition on the chip:
The P87LPC761 has 3 I/O ports, port 0, port 1, and port 2. The exact number of I/O pins available depend upon the oscillator and reset options chosen. At least 9 pins of the P87LPC759 may be used as I/Os when a two-pin external oscillator and an external reset circuit are used for MCU Recovering. Up to 12 pins may be available if fully on-chip oscillator and reset configurations are chosen.
All but three I/O port pins on the P87LPC761 may be software configured to one of four types on a bit-by-bit basis, as shown in below Table which has the similar procedures of NXP Chip P89LPC970 Heximal Code Dumping. These are: quasi-bidirectional (standard 80C51 port outputs), push-pull, open drain, and input only. Two configuration registers for each port choose the output type for each port pin.
Quasi-Bidirectional Output Configuration
The default port output configuration for standard P87LPC761 I/O ports is the quasi-bidirectional output that is common on the 80C51 and most of its derivatives. This output type can be used as both an input and output without the need to reconfigure the port. This is possible because when the port outputs a logic high, it is weakly driven, allowing an external device to pull the pin low.
When the pin is pulled low, it is driven strongly and able to sink a fairly large current. These features are somewhat similar to an open drain output except that there are three pull-up transistors in the quasi bidirectional output that serve different purposes.
One of these pull-ups, called the “very weak” pull-up, is turned on whenever the port latch for the pin contains a logic 1. The very weak pull-up sources a very small current that will pull the pin high if it is left floating.