R5F35L2EJFE: 256 KB Firmware Read, 20 KB RAM Die

Two hundred and fifty-six kilobytes of flash with twenty kilobytes of RAM is the top of the M16C/5L range, and R5F35L2EJFE is the 80-pin body that carries it. At this size the firmware is no longer a single loop with a few interrupts. It is an operating structure with a file system on the data flash, a protocol stack on the serial ports, and possibly a bootloader in program ROM 2 that the customer has forgotten exists.

The Bottom Edge Moves Again

Program ROM 1 is addressed from FFFFFh downward, so a bigger array simply extends further down. On this part the bottom edge is C0000h. That is 256 KB below the top of the megabyte map, and it sits well under the point where most disassemblers assume code begins. A dump taken with a 128 KB assumption returns E0000h to FFFFFh and loses 128 KB of the application without any visible error – the image still merges, still has a plausible reset vector, and still fails on the target.

Where The Other 128 KB Lives

The missing half is usually not “more of the same”. On builds this large, the low addresses tend to hold the cold paths: the menu system, the calibration routines, the diagnostic strings, sometimes the bootloader’s staging area. The high addresses hold the interrupt-driven core. That distribution is exactly backwards from what a quick look at the hex would suggest, which is why we map the dump against the vector table before handing it over.

RAM At Twenty Kilobytes

RAM runs from 00400h to 053FFh. At twenty kilobytes, the start-up code almost certainly performs a memory test, and the results of that test land in a structure the firmware later reads. On a live capture, that structure is worth grabbing: it tells a rebuild team how the original code partitioned the heap and the stacks, which is otherwise a matter of guesswork.

Data Flash Is A File System Here

Two 4 KB blocks at 0E000h to 0FFFFh. With endurance rated at 10,000 cycles for data flash against 1,000 for program ROM, a design at this scale nearly always treats the pair as a rotating log. Reading both blocks and reporting their fill level tells the customer whether the unit was near end of life or barely used – a small piece of information that has decided more than one rebuild-or-replace argument.

The Read

Four passes, each duplicated: ROM 1 from C0000h, ROM 2 from 10000h, data flash block A, data flash block B, then the 37-byte option window. The merged HEX is written at true addresses, so a blank part programmed from it starts without relocation. ROM code protect and the ID code check are handled as configuration, never as an obstacle that requires erasing the array.

Where Twenty Kilobytes Goes

Twenty kilobytes of RAM in a 16-bit controller is unusual enough that it shapes the firmware. The start-up code typically divides it into regions with fixed boundaries, and the linker script that produced the image encoded those boundaries as absolute addresses. When a dump is examined, the first few kilobytes of RAM usage are usually obvious from the addresses the code loads into the stack pointer and the data section.

If the unit is alive, the RAM image is worth capturing for one more reason: the CAN receive buffers hold whatever was last on the bus, and that content identifies the network the product belonged to. On a machine that has been decommissioned, that is often the only record of its message set.

Handover

An Intel HEX, five region binaries, a checksum table, and a configuration page with the ID code, OFS1, OFS2, and the erase state of both data flash blocks. If a live capture was possible, the page also records the ADC channel assignment, the Timer S setup, and the serial port baud divisors.

Send the board with the crystal frequency and a note on what the product does. Quotes start at the services page; technical questions go to the contact form. The 64-pin 256 KB part is R5F35L3EJFF, and the 128 KB 80-pin device is R5F35L26JFE.