Netgear WNDR3700v5 hardware observations / experiments

Report problems and success stories with Gargoyle on various hardware platforms.

Moderator: Moderators

pythonic
Posts: 276
Joined: Mon Mar 11, 2019 5:47 am
Location: Australia

Re: Netgear WNDR3700v5 hardware observations / experiments

Post by pythonic »

se325919 wrote:
Sat Dec 20, 2025 10:20 am
The hardware part is simple enough. Unfortunately for me, the software side of things looks very much out of my depth.
Although still requiring software understanding to implement, I've just remembered seeing a reference to mtd-concat in this thread which could make it easier than I earlier thought. Being able to use mtd-concat would allow you to join the existing root filesystem/overlay space to the free space at the end of the larger flash. Provided the device boots from the larger flash, the changes to do this are all in the OpenWrt environment and you would likely get away without needing to change the bootloader at all.

There are quite a few existing examples of devices using this functionality (I count at least 20 in the ramips target alone for OpenWrt 24.10). My suspicion is that after copying the contents of the old flash to the new flash you would just need to define a new partition in the device tree for the unused space and then add the reference combining the new and existing partitions to the device tree. In theory, this would only require building a new device tree binary. While it isn't that hard to extract a DTB (device tree binary) from an image using tools like binwalk, and decompile/compile DTBs to/from source (DTS) using dtc, there aren't any convenient tools to replace the DTB in an image with a modified DTB while preserving the image structure so building the full image from source becomes a necessity.

At least Netgear bootloaders usually have reliable and relatively easily used ways to flash back factory images...

I've never tried to do this myself so the above is hypothetical - be careful and do your own research!

se325919
Posts: 22
Joined: Fri Dec 05, 2025 10:00 pm

Re: Netgear WNDR3700v5 hardware observations / experiments

Post by se325919 »

Thanks again Pythonic. There is certainly hope there. I will see if I can get hold of another router for the home for now which will allow me to take this one away to the workshop and mess about with it more. I'm sure I will be coming back for more advice later. You have been really helpful in finding things that confirm that what I have in mind is not impossible.

se325919
Posts: 22
Joined: Fri Dec 05, 2025 10:00 pm

Re: Netgear WNDR3700v5 hardware observations / experiments

Post by se325919 »

Hi Lantis, pythonic and all. I am back after some time.

I have gone ahead and swapped out the NOR chip for one exactly twice the size (32MiB).

Before doing that, I used a CH341 chip programmer to copy the data from the old chip (I flashed it back to Netgear factory firmware first just as a precaution). I then wrote that data to the new chip before soldering it to the PCB. I was happy to see that the router still booted and worked normally. Once that was ascertained, I decided to flash the latest build of OpenWRT onto it, which worked, but predictably it only shows the same space as before.

The reason I went to OpenWRT is because it has a GUI that lets you save out the u-boot, u-boot-env and factory partitions as bin files. Maybe Gargoyle also has this, or maybe you can do it from the command line, but this is the way I did it anyway.

I have created a Debian virtual machine and followed the OpenWRT guide to make it into a build environment. Someone on the OpenWRT forums kindly pointed me to the DTS file that I need to modify, which is here:
https://github.com/openwrt/openwrt/blob ... 700-v5.dts

I think I am some way to understanding how the DTS file describes the flash layout of the device and mentions where partitions start and how large they are, but I don't understand where this file is used. I can probably have a go at modifying it, but have no clue what to do with it after that.

I have a thread ongoing over on the OpenWRT forums at this link:
https://forum.openwrt.org/t/i-have-swap ... 0v5/245092

There has been some useful info provided there already and I feel I am getting nearer to realising the objective, but still in need of help.

I'm down to the 'menuconfig' section on this page:
https://openwrt.org/docs/guide-develope ... uildsystem

but kind of confused where the DTS file comes in and how I put that into the build as it doesn't seem to mention anything there. Any more help would be most appreciated.

Lantis
Moderator
Posts: 7237
Joined: Mon Jan 05, 2015 5:33 am
Location: Australia
Contact:

Re: Netgear WNDR3700v5 hardware observations / experiments

Post by Lantis »

Yes the DTS needs modifying for sure and sounds like you’re on your way to completing that.
It should be sufficient to modify the file and then start a build. The modified version will be referenced.

It may be useful to export a diff of this file in case you need to reset your environment for some reason, to avoid losing your work. Or save a copy of the file outside the build environment.

If this all works I can assist with how you can do the same in Gargoyle. Same concept but different steps.
https://lantisproject.com/downloads/gargoylebuilds for the latest releases
Please be respectful when posting. I do this in my free time on a volunteer basis.
https://lantisproject.com/blog

Post Reply