This is rigt way to do it or by install openwrt my router will brick? (TP-Link TL-MR3420)

I have router TP-Link TL-MR3420 v5 and i want to compile source code and build image then want to flash in router.

here the step which i followed:

  1. git clone https://git.openwrt.org/openwrt/openwrt.git

  2. cd openwrt

  3. git cheakout openwrt-23.05

  4. ./scripts/feeds update -a && ./scripts/feeds install -a

  5. make menuconfig

  6. make

in 5th step i changed "Target System", "Subtarget", "Target Profile" and save it.

this all step run without error but i have a question that do i need to add or do anthing alse in beside those step and what is god way to flash to router safaly?

Why don't you take a pre-built image and flash that? If you want to customize packages due to the size limits of your device, you can always do so by using the firmware selector:

https://firmware-selector.openwrt.org/?version=23.05.2&target=ramips%2Fmt76x8&id=tplink_tl-mr3420-v5

2 Likes

i want to do changes in codes of openwrt you can think as create a new module or somthing like that that's why i want to do by compile code and make custom image to flash

AFAICS you haven't integrated the default .config for that device, that might lead to missing packages which in turn might lead to dysfunctional components or even a dysfunctional device at all. I'd put that file - you can find it here: https://downloads.openwrt.org/releases/23.05.2/targets/ramips/mt76x8/config.buildinfo - between steps 3 and 4 into your build environment and afterwards check make menuconfig carefully and completely if that's what I want. Then according to the docs simply make can lead to problems, a good starting point are the docs at https://openwrt.org/docs/guide-developer/toolchain/use-buildsystem.

Personally I'd add some saving steps in there, eg. save the whole build tree at least after step 4 in a safe way eg. a tarball so I needn't to start over from scratch if something goes south.

As @andyboeh mentioned, to start playing with OpenWrt it's better to test a precompiled version on your router, that's tested on someone elses hardware to be functional, afterwards you know how to flash, what works how and what not, how to get back if the router won't work with your self-compiled things and so on.

So i just to add one cammand after 4th that is wget https://downloads.openwrt.org/releases/23.05.0/targets/ramips/mt76x8/config.buildinfo -O .config.