TMS320F28075: Two Security Zones and the Pointer That Joins Them
Duplicating a microcontroller normally means one operation repeated: read the array, write it elsewhere. On a part with a single security module, that is close to accurate. The F28075 breaks the assumption, because its memory and its security configuration are divided into two independent zones, and the two can be configured to behave as one, as two, or as two where one is subordinate to the other.
The result is that a “full copy” of an F28075 is not one image. It is two images, two OTP configurations, and a relationship between them — and the relationship is stored in the same OTP that most other parts use only for the password.
Two zones, not one
The array is partitioned into zone one and zone two. Each has a password, each has a per-zone OTP block that controls how the password may be used, and each governs access to whichever flash sectors and RAM blocks were assigned to it. Code in zone one cannot read zone two and vice versa, unless a link is established.
That arrangement exists for a real product reason. A design that ships with a manufacturer-supplied bootloader in one zone and the customer’s application in the other wants the two to be mutually invisible: the bootloader vendor cannot read the application, and the customer cannot read the bootloader.
| Configuration | What it means for a read |
|---|---|
| Two zones, no link | Each needs its own password; neither can see the other |
| Two zones, linked | Presenting zone two’s password also releases zone one |
| One zone effectively unused | Only the populated zone matters |
| Zone locked with password unknown | That zone is unreadable; the other may still be open |
The OTP block is the real configuration
Most of the parts discussed on this site keep their security state in a handful of flash bits. Here, each zone has an OTP region holding several independent lock fields, and each field answers a different question:
- whether the password may be changed at all;
- whether the CRC of the zone’s protected region is enforced;
- whether RAM assigned to the zone may be allocated by code outside it;
- whether code in the zone may be executed but not read.
That last field is the one most often missed. A zone configured for execute-only is not unreadable in the ordinary sense; it is readable by the instruction fetch path and not by the data path. Code runs from it normally, and any attempt to copy it as data returns something other than the code. A device in this state behaves exactly like a working product and yields nothing to a data copy.
Why duplication is a per-zone decision
Given the above, “duplicate this F28075” decomposes into a question per zone: is this zone read-protected, and if so, with what configuration? The answers can differ. A common shape is one zone open — the bootloader, deliberately left readable so the customer’s production line can verify it — and one zone locked.
Attempting a single pass over the whole array and then deciding what is missing is the wrong order. Read the OTP area first. It is small, it is outside the protected region, and it tells you which of the four configurations you are dealing with before any large transfer is attempted.
What a duplicate must reproduce besides code
A duplicated part that runs but does not behave identically has usually been copied at the array level and not at the configuration level. On this family, the items that must match are:
- The code image of each zone, at its original addresses.
- The password of each zone, or the decision to leave each zone open.
- The OTP lock fields, which govern what the next reader is allowed to do.
- The boot configuration, which decides which zone runs first.
- The calibration values the device reads at startup, if the design uses factory trim.
Item five is specific to parts with analog blocks that carry trim from the factory. Copy the code without the trim and the ADC reads with a systematic offset — a difference that looks like a firmware bug and is not one.
The link pointer, and why it matters at copy time
When zone one is linked to zone two, unlocking zone two unlocks both. This is convenient during development and a trap during duplication, because it means a device can appear to be fully open when only one password has been supplied. A technician who unlocks zone two, copies everything visible, and reports success has copied whatever zone one exposes through the link — which may be everything, or may be only the parts not individually restricted.
The check is straightforward: after unlocking, read a known code address in each zone and confirm the result is not zero. Zero on a part that should be populated means the zone is still closed, whatever the unlock sequence reported.
Execute-only zones and the limits of copying
If a zone is configured execute-only, the data path will not return its contents and no amount of re-reading changes that. What remains available is behavioural: the zone runs, so its code can be observed through its effects — which peripherals it touches, what it writes to shared RAM, what it sends on a bus.
For duplication purposes that is often enough. A bootloader’s job is well-defined, and a replacement that performs the same job at the same interface is functionally a duplicate even if it is not byte-identical. For an application zone, behavioural reconstruction is a much larger undertaking and the honest answer is that the copy will be an equivalent rather than a replica.
Ordering the work
The sequence that avoids wasted effort on this family:
- Read the OTP configuration for both zones.
- Determine which zones are populated, which are open, and which are execute-only.
- Unlock what can be unlocked; confirm by reading a known address.
- Copy open zones by ordinary read.
- For closed zones, decide between password recovery and behavioural reconstruction — these are different projects with different costs.
- On the destination part, program zones, then OTP, then boot configuration, then verify by running.
Step six is where copies fail. Programming the OTP before the code means the destination part locks itself out of its own array halfway through the process, and the part must be mass-erased and started again.
Related reading
- TMS320F28067 and the single-zone lock — the simpler case, useful as a baseline.
- TMS320F28375 and zone semantics on the larger family — the same idea with more zones and more OTP fields.
- TMS320F28068F and code that lives in the control law accelerator — when part of the program is not in the main array at all.
FAQ
Can both zones be unlocked with one password? Only if the zones are linked. Without the link, each needs its own.
Is the OTP area readable on a locked part? The configuration fields are, which is why reading them first is the right opening move.
Does an execute-only zone defeat duplication entirely? It defeats copying as data. It does not prevent reconstructing behaviour from observation.
What happens if the destination’s OTP is programmed first? The part locks itself against the remainder of the write. It has to be mass-erased and redone.
Can a zone’s password be changed later? Only if the corresponding lock field in OTP permits it. Once that field is set, the password is fixed for the life of the die.
Conclusion
Duplication on the F28075 is a per-zone exercise governed by OTP rather than by the array. Read the configuration first, unlock per zone, confirm by reading known addresses, and treat execute-only zones as a behavioural problem rather than a data problem. The array is the easy part; the OTP is where the decisions are.