I'm trying to store default static ip settings in a custom rom.
I write the SSID and Password to /etc/wifi/wpa_supplicant.conf and that works well for Wi-Fi
But how do I add the static IP settings (gateway, fixed ip) for Wi-Fi (and Ethernet)?
I'm trying to store default static ip settings in a custom rom.
I write the SSID and Password to /etc/wifi/wpa_supplicant.conf and that works well for Wi-Fi
But how do I add the static IP settings (gateway, fixed ip) for Wi-Fi (and Ethernet)?
Save the following in one of the init scripts in the ROM
ifconfig eth0 192.168.1.100 netmask 255.255.255.0
route add default gw 192.168.1.1 dev eth0
setprop net.dns1 192.168.1.1
ip addr show
ip route show
Where eth0 in this case, is an ethernet adapter attached via USB.
I had a problem where my Samsung S3 Mini (Jelly Bean 4.1.2) worked 100% on my Wi-Fi router but failed to connect to the Internet with my Wi-Fi repeater - stuck on "obtaining IP address..." message. I have now set a static IP and it works 100% on both the router and the repeater. If you need multiple static IP options then check out "Wi-Fi Static" application. I found the answer courtesy of Motorola, and repeat it below, at https://motorola-global-portal.custhelp.com/app/answers/prod_answer_detail/a_id/68989/p/7901,8013,
To setup a Static IP Address on your Motorola Xoom, follow the steps below:
Touch Apps
Touch Settings
Touch Wi-Fi settings
Touch Add Wi-Fi network
Enter Name under Network SSID, and touch Save
Touch and hold the "network name", and touch Modify network
Select Static under IP settings, and enter the specific network information
Tip: You can also adjsut your security and Proxy settings.
Touch Save
You can set ip with ifconfig and gateway with route when you are rooted. I used it to change the tcp buffer.