Switching from NOR to NAND on a fleet of remote devices

I have a bunch of GL-AR300M deployed in the wild. All of those devices are behind NAT and my only access is via reverse ssh tunnel. If anything goes wrong I'll need to post a new device.

Those devices are running OpenWRT18.x NOR.
I am able to remotely flash them with OpenWRT23.05 NOR.

But how to make them run NAND version of OpenWRT?
I've tried:
updating 18 NOR -> 23.05 NOR - that went well
Updating 23.05 NOR to 23.05 NAND - I can't no longer access the device. As far as I can tell it did not boot neither of those 3 images (18NOR 23NOR, 23NAND)

Is there any doco on moving from NOR to NAND?

It has a hardware switch to do it, cannot remote.
Docs on internet.

@RadioOperator - a hardware switch?
that device has a momentary switch that acts as a reset and a toggle switch that is wired to gpio and can be configured to do many different things.

Docs on internet. - care to point me into right direction as I spent few days on getting this working and can't find anything that would describe the process.

I have to say I've skimmed over this doco as the devices I access are already on OpenWRT and I build my images using OpenWrt wiki.
But this article says to use .img, which the builder produces, when flashing NAND the first time.. I wonder if this applies when flashing from OpenWRT NOR to NAND too...

Will report back after the weekend.

Thanks @RadioOperator

I think this AR300M, has two mode, NOR mode and NAND mode.
You could only use one mode, to switch the mode, should be the uboot function.
You can not switch the mode by programmed firmware.


nope, foctory.img did not work.
There must be a step I'm missing.
I could probably use MTD for flash NAND firmware onto NAND chip but how do I get uboot upgraded to boot from the other device (nand)?

I donot know how to use NAND flash on ar300m, you have to search this on internet carefully, or contact manufacturer.

What functions you want to use it in nand flash? Nor chip is not enough?

First of all, are you aware that not all ar300m models have nand?

Older ones do, but as far as I am aware, the nand versions were discontinued some time ago. The current version only has the nor flash, namely because it is perfectly adequate for just about any application, and keeps the price down to very low levels.

If we assume you have the nand/nor original version, these will boot only from the nand flash unless the nand flash fails 3 times in a row and then it will try booting from nor.

It is quite possible you have been remotely flashing the nor firmware to have it boot back into the original nand, ignoring what you just flashed into nor. Many people have done this, including me a few years ago until I found out how to force booting from nor.

1 Like