
Introduction
In OpenWRT development, we may encounter the requirement to convert some network devices from wireless to wired. We can achieve this by adding a network port driver inside the device. Here, we introduce a simple and straightforward method: remove the DHCP function from LAN, and bridge WiFi and LAN to realize the wireless to wired functionality. The router’s signal line is directly connected to the attenuator SMA interface, which is connected to the device that needs to be converted, while configuring the router’s WAN port to provide DHCP service for LUCI login operations.
Author: Liangzhi Yucun
Reprint authorization and following: Welcome to follow the WeChat public account: Yulin Jun
Or add the author’s personal WeChat: become_me
WAN LAN
Above is the WAN and LAN ports of the router. Generally, the LAN port connects to various devices that need to be connected. A router usually has several LAN ports. If the WAN port is not connected, the pure LAN port usage acts as a switch.
The WAN port is usually connected to the network cable coming from the modem and must be plugged into the router’s WAN port; then the secondary router connects the upper-level network cable to the WAN port of the secondary router. This is the typical usage. Here, we start to introduce what we want to do: we hope that the external upper-level router connects to the LAN port of the router, and the upper-level provides DHCP service, while the LAN acts as a DHCP client. WiFi and LAN are bridged, and devices directly connected to the WiFi antenna are connected through the upper-level router for DHCP. This router and WiFi-connected devices together form a device that converts wireless to wired.
Brute Modification
Modify WAN port to static IP for LUCI login
Log into OpenWRT LUCI and enter the interface section
Configure the WAN interface!
Select static address protocol
Set the access address you need
Enable DHCP function
You can also turn off the firewall Set the DHCP allocation pool according to your needs; I set it to start from 100, with a maximum of 150 devices, and a lease time of 12 hours. If devices connect frequently, you can shorten the lease time, but since my router has become a dedicated device, the time can be longer.
Set the routing rules you need
LAN Settings
Select protocol for LAN port, cancel DHCP
This usage allows our LAN and WiFi to become a non-DHCP function, assigned IP by the upper-level router. At this point, you can use WAN to access the LUCI interface. The WiFi antenna and the antenna of the device to be connected are hardware connected, thus forming a device that converts wireless to wired.

Conclusion
This is a little record of a cool operation I did in OpenWRT. If anyone has better ideas, feel free to add me as a friend to exchange and share.
Author: Liangzhi Yucun, working hard during the day, original public account owner at night. The content of the public account includes not only technology but also some life insights. I am a serious content creator in the workplace, and also a person with a rich life outside of technology, including photography, music, and basketball. Follow me and walk with me.
‧‧‧‧‧‧‧‧‧‧‧‧‧‧‧‧ END ‧‧‧‧‧‧‧‧‧‧‧‧‧‧‧‧
Recommended Reading
[1] Detailed Sharing of Jetson Nano Development
[2] Practical Sharing of Linux Core Dump File Analysis
[3] How Programs Run in CPU – Must Read
[4] Establishing Cartographer Environment and Mapping Test
[5] Comparison of Simple Factory Pattern, Factory Pattern, and Abstract Factory Pattern
All original content of this public account has been organized into a directory. Reply [Resource] to obtain it.