Compile with wifi on

hi , how i can compile a firmware with wifi on, i need test a device with one etrhernet port, and i want make sure that the ethernet port is used as wan.

check the wiki you can provide files that will be included directly in the final image (provide a wireless config enabled by default)
Another way if you are handy with the openwrt source is edit the wifi config gen function and make it to set the wifi enabled by default, but i think the quickest task is just run the router once, copy the wireless config file, and provide it with the "files" dir (again the wiki are more info about this)

1 Like

I cannot connect to the router, it’s a mikrotik , after the initram immage it will not reboot, but it will not respond to openwrt no to router os, so i hope that the problem is that the ethernet port is the wan.

You can place a script in base-files/etc/uci-defaults that will setup wifi credentials via uci on first boot.

As a template, you could use 50-wifi-defaults from my initial DAP-2660 test branch, which had the same issue (ethernet required special settings to work):

Just place 50-wifi-defaults in your base-files folder and edit the boardname to match your device (or remove the whole case construct). Beware this will use the first wifi interface it can find.

1 Like

What's the device?