Obtain OpenWRT

  • Find the device model at the Table of Hardware (Huawei HG556a C)
  • Open Device Techdata for Firmware OpenWrt Install URL
  • Open Device Page for Installation instructions

Computer - Cable - Router

Connect the computer to the router with a cable.

Install OpenWRT

Follow the instructions to install OpenWRT.

SSH

First login:

telnet 192.168.1.1

Change password to enable SSH:

passwd
exit

For public key authentication, add the public key:

ssh-copy-id [email protected]
ssh [email protected]
mv ~/.ssh/authorized_keys /etc/dropbear
exit

WiFi

In /etc/config/wireless:

config wifi-device  radio0
	......
	# REMOVE THIS LINE TO ENABLE WIFI:
	# option disabled 1

config wifi-iface
	option device     radio0
	option network    lan
	option mode       ap
	option encryption psk2
	option hidden     1
	option ssid       [SSID]
	option key        [WiFi password]
	option macaddr    [00:0A:4B:3C:6D:02]

Execute:

wifi

Computer - WiFi - Router

Disconnect the cable to the router. Try SSH via WiFi.

Internet

In /etc/config/network:

It is better to change the lan address so that it will not be conflicted with the upstream address.

config interface 'lan'
	option ipaddr '192.168.2.1'
# lan switch
config switch_vlan
	option device 	eth0
	option vlan 	1
	option ports 	"1 2 5t"

# wan switch
config switch_vlan
	option device 	eth0
	option vlan 	2
	option ports 	"0 5t"

For DHCP wan:

config interface wan
	option ifname eth0.2
	option proto  dhcp

For PPPOE wan:

config interface wan
	option ifname   eth0.2
	option proto    pppoe
	option username [PPPOE user name]
	option password [password]

Computer - WiFi - Router - Cable - Internet

Connect the internet cable to the router, reboot the router.