Adding OpenWrt support for Senao like Devices

On Label just show ETH MAC, but these are all of Mac addresses currently shown:

br-lan    Link encap:Ethernet  HWaddr 00:90:7F:B4:D7:E2  
          inet addr:192.168.1.103  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::290:7fff:feb4:d7e2/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:38355 errors:0 dropped:0 overruns:0 frame:0
          TX packets:29081 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:4222236 (4.0 MiB)  TX bytes:10632663 (10.1 MiB)

eth0      Link encap:Ethernet  HWaddr 00:90:7F:B4:D7:E2  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:132318 errors:0 dropped:6 overruns:0 frame:0
          TX packets:86269 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:96731719 (92.2 MiB)  TX bytes:20483137 (19.5 MiB)
          Interrupt:4 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:13333 errors:0 dropped:0 overruns:0 frame:0
          TX packets:13333 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:1213460 (1.1 MiB)  TX bytes:1213460 (1.1 MiB)

wlan0     Link encap:Ethernet  HWaddr 00:90:7F:B4:D7:E4  
          inet6 addr: fe80::290:7fff:feb4:d7e4/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:67144 errors:0 dropped:0 overruns:0 frame:0
          TX packets:110311 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:11818653 (11.2 MiB)  TX bytes:97992737 (93.4 MiB)

wlan1     Link encap:Ethernet  HWaddr 00:90:7F:B4:D7:E3  
          inet6 addr: fe80::290:7fff:feb4:d7e3/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:10950 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:1222018 (1.1 MiB)

This device have 2 bi-color led´s (WiFI and LAN) and a power green led:

WIFI AMBER > 23
WIFI GREEN > 19
LAN AMBER > 12
LAN GREEN > 13
POWER > 22

I remember that after some specific firmware update Watchguard defined same led behavior to all of their AP products, but I didn't found that article to serve us as a baseline to keep similar behavior.
This is default behavior on older firmwares:




After posted image, found that there is a Red color that was not shown by script. M
ight be green + amber?

you found a red LED using the script? or documentation of it?

when asking about MAC addresses I'm only interested in how the original firmware does it

sometimes vendors have the same MAC for each interface of a device, sometimes they increment down instead of up, etc.

when adding boards we are supposed to follow the MAC address pattern from the original firmware exactly

this board is exactly the same hardware as EAP1750H but the MACs might be assigned in different ways

if you are unable to get wireless up on the original firmware to print it's MACs its ok though...

Documentation. Testing original firmware really show that RED led is not really RED. Actually watchguard´s RED is more like AMBER and Watchguard´s AMBER is more like Yellow, result of both of led´s on.
Using original script I was not able to simulate that. Just playing with it disabling the part of code that turn off led, leaving more than one led´s on I was able to get all of 3 colors.

Is possible to set on new image lan default configuration to DHCP client instead static ip on 192.168.1.1?

1 Like

About WIFI MAC Addresses... On an original I see same behavior: incrementing from lan Mac > 2.4 +1 > 5 +2 Example: lan with Mac ending :3c, 2.4ghz ending 3d , 5ghz ending 3e.

1 Like

Ok we will stick with amber and green regardless of what it looks like when both are on

here is a final test image

for LAN LEDs I did:
amber --> link status
green --> activity

enable wireless one at a time and verify the right LED turns on

and post kernel log

https://gist.github.com/mpratt14/ae08223fbb9bb9a639197452d215bffb

making DHCP the default is possible but not encouraged...this is done for devices that are not part of network infrastructure at all...end-point devices like NAS and other IoT things. Right now there is only 1 device in ath79 with DHCP as the default and it is not a router or an AP (Etactica EG-200).

the main concern is that someone attempting to follow "failsafe mode" instructions will fail because it assumes failsafe mode will start up with the default static ip

however, when we are done, I can show you how to build your own image with DHCP as default

1 Like

Actually this kind of device is more comercial or enterprise, so I think is a little bit risky in case of need to remote factory reset when it is installed in a place like 5m high where is not possible to switch to a direct cable to get limited access to it. In case of a reset will cause a lot of havoc on network being a well known default gateway, advertising ipv4 and ipv6... Actually I not even think is necessary a DHCP server on it because in normal use this role is normally on another device but OK. I can build a new image more Enterprise later.

[    0.000000] Linux version 5.4.96 (pi@SDDesk) (gcc version 8.4.0 (OpenWrt GCC 8.4.0 r13719+835-66e04abbb6)) #0 Fri Feb 12 06:03:12 2021
[    0.000000] printk: bootconsole [early0] enabled
[    0.000000] CPU0 revision is: 00019750 (MIPS 74Kc)
[    0.000000] MIPS: machine is WatchGuard AP300
[    0.000000] SoC: Qualcomm Atheros QCA9558 ver 1 rev 0
[    0.000000] Initrd not found or empty - disabling initrd
[    0.000000] Primary instruction cache 64kB, VIPT, 4-way, linesize 32 bytes.
[    0.000000] Primary data cache 32kB, 4-way, VIPT, cache aliases, linesize 32 bytes
[    0.000000] Zone ranges:
[    0.000000]   Normal   [mem 0x0000000000000000-0x0000000007ffffff]
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000000000000-0x0000000007ffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000000000000-0x0000000007ffffff]
[    0.000000] On node 0 totalpages: 32768
[    0.000000]   Normal zone: 288 pages used for memmap
[    0.000000]   Normal zone: 0 pages reserved
[    0.000000]   Normal zone: 32768 pages, LIFO batch:7
[    0.000000] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
[    0.000000] pcpu-alloc: [0] 0 
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 32480
[    0.000000] Kernel command line: console=ttyS0,115200n8 rootfstype=squashfs,jffs2
[    0.000000] Dentry cache hash table entries: 16384 (order: 4, 65536 bytes, linear)
[    0.000000] Inode-cache hash table entries: 8192 (order: 3, 32768 bytes, linear)
[    0.000000] Writing ErrCtl register=00000000
[    0.000000] Readback ErrCtl register=00000000
[    0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[    0.000000] Memory: 112400K/131072K available (4916K kernel code, 184K rwdata, 1124K rodata, 10920K init, 196K bss, 18672K reserved, 0K cma-reserved)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] NR_IRQS: 51
[    0.000000] random: get_random_bytes called from start_kernel+0x32c/0x520 with crng_init=0
[    0.000000] CPU clock: 720.000 MHz
[    0.000000] clocksource: MIPS: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 5309056796 ns
[    0.000007] sched_clock: 32 bits at 360MHz, resolution 2ns, wraps every 5965232126ns
[    0.008285] Calibrating delay loop... 359.42 BogoMIPS (lpj=718848)
[    0.042878] pid_max: default: 32768 minimum: 301
[    0.047919] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes, linear)
[    0.055708] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes, linear)
[    0.068021] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 7645041785100000 ns
[    0.078408] futex hash table entries: 256 (order: -1, 3072 bytes, linear)
[    0.085738] pinctrl core: initialized pinctrl subsystem
[    0.092129] NET: Registered protocol family 16
[    0.121537] workqueue: max_active 576 requested for napi_workq is out of range, clamping between 1 and 512
[    0.134668] clocksource: Switched to clocksource MIPS
[    0.141056] NET: Registered protocol family 2
[    0.146380] tcp_listen_portaddr_hash hash table entries: 512 (order: 0, 4096 bytes, linear)
[    0.155335] TCP established hash table entries: 1024 (order: 0, 4096 bytes, linear)
[    0.163503] TCP bind hash table entries: 1024 (order: 0, 4096 bytes, linear)
[    0.171015] TCP: Hash tables configured (established 1024 bind 1024)
[    0.177897] UDP hash table entries: 256 (order: 0, 4096 bytes, linear)
[    0.184899] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes, linear)
[    0.192569] NET: Registered protocol family 1
[    0.197259] PCI: CLS 0 bytes, default 32
[    0.369816] workingset: timestamp_bits=14 max_order=15 bucket_order=1
[    0.382408] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    0.388654] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[    0.413117] pinctrl-single 1804002c.pinmux: 544 pins, size 68
[    0.420168] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[    0.427572] printk: console [ttyS0] disabled
[    0.432198] 18020000.uart: ttyS0 at MMIO 0x18020000 (irq = 9, base_baud = 2500000) is a 16550A
[    0.441390] printk: console [ttyS0] enabled
[    0.450287] printk: bootconsole [early0] disabled
[    0.466110] spi-nor spi0.0: s25fl256s1 (32768 Kbytes)
[    0.471335] 10 fixed-partitions partitions found on MTD device spi0.0
[    0.477878] Creating 10 MTD partitions on "spi0.0":
[    0.482836] 0x000000000000-0x000000040000 : "u-boot"
[    0.488676] 0x000000040000-0x000000050000 : "u-boot-env"
[    0.494913] 0x000000050000-0x0000000a0000 : "custom"
[    0.500753] 0x0000000a0000-0x0000000b0000 : "loader"
[    0.506610] 0x0000000b0000-0x000000220000 : "fwconcat2"
[    0.512721] 0x000000220000-0x000000230000 : "fakeroot"
[    0.518794] 0x000000230000-0x000000d70000 : "fwconcat0"
[    0.524870] 0x000000d70000-0x000000ff0000 : "failsafe"
[    0.530966] 0x000000ff0000-0x000001ff0000 : "fwconcat1"
[    0.537060] 0x000001ff0000-0x000002000000 : "art"
[    0.542918] Concatenating MTD devices:
[    0.546757] (0): "fwconcat0"
[    0.549678] (1): "fwconcat1"
[    0.552602] (2): "fwconcat2"
[    0.555530] into device "virtual_flash"
[    0.559450] 1 fixed-partitions partitions found on MTD device virtual_flash
[    0.566517] Creating 1 MTD partitions on "virtual_flash":
[    0.572006] 0x000000000000-0x000001cb0000 : "firmware"
[    0.615374] libphy: Fixed MDIO Bus: probed
[    0.948432] libphy: ag71xx_mdio: probed
[    0.969810] ag71xx 19000000.eth: connected to PHY at mdio.0:05 [uid=004dd072, driver=Atheros 8035 ethernet]
[    0.980268] eth0: Atheros AG71xx at 0xb9000000, irq 4, mode: rgmii-id
[    0.987023] i2c /dev entries driver
[    0.992343] NET: Registered protocol family 10
[    1.001045] Segment Routing with IPv6
[    1.004906] NET: Registered protocol family 17
[    1.009504] 8021q: 802.1Q VLAN Support v1.8
[    1.014545] PCI host bridge /ahb/pcie-controller@180c0000 ranges:
[    1.020787]  MEM 0x0000000010000000..0x0000000011ffffff
[    1.026103]   IO 0x0000000000000000..0x0000000000000000
[    1.031561] PCI host bridge to bus 0000:00
[    1.035750] pci_bus 0000:00: root bus resource [mem 0x10000000-0x11ffffff]
[    1.042734] pci_bus 0000:00: root bus resource [io  0x0000]
[    1.048398] pci_bus 0000:00: root bus resource [??? 0x00000000 flags 0x0]
[    1.055288] pci_bus 0000:00: No busn resource found for root bus, will use [bus 00-ff]
[    1.063357] pci 0000:00:00.0: [168c:003c] type 00 class 0x028000
[    1.069505] pci 0000:00:00.0: reg 0x10: [mem 0x00000000-0x001fffff 64bit]
[    1.076447] pci 0000:00:00.0: reg 0x30: [mem 0x00000000-0x0000ffff pref]
[    1.083325] pci 0000:00:00.0: supports D1
[    1.087402] pci 0000:00:00.0: PME# supported from D0 D1 D3hot
[    1.094278] pci_bus 0000:00: busn_res: [bus 00-ff] end is updated to 00
[    1.101031] pci 0000:00:00.0: BAR 0: assigned [mem 0x10000000-0x101fffff 64bit]
[    1.108473] pci 0000:00:00.0: BAR 6: assigned [mem 0x10200000-0x1020ffff pref]
[    1.156628] Freeing unused kernel memory: 10920K
[    1.161339] This architecture does not have kernel memory protection.
[    1.167871] Run /init as init process
[    1.186697] random: fast init done
[    1.616218] init: Console is alive
[    1.619954] init: - watchdog -
[    1.639966] kmodloader: loading kernel modules from /etc/modules-boot.d/*
[    1.649061] kmodloader: done loading kernel modules from /etc/modules-boot.d/*
[    1.667372] init: - preinit -
[    1.918033] random: jshn: uninitialized urandom read (4 bytes read)
[    2.029007] random: jshn: uninitialized urandom read (4 bytes read)
[    2.076016] random: jshn: uninitialized urandom read (4 bytes read)
[    6.376078] eth0: link up (1000Mbps/Full duplex)
[    6.387671] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[    6.415319] eth0: link down
[    6.428598] procd: - early -
[    6.431662] procd: - watchdog -
[    6.993229] procd: - watchdog -
[    6.996779] procd: - ubus -
[    7.006926] urandom_read: 5 callbacks suppressed
[    7.006933] random: ubusd: uninitialized urandom read (4 bytes read)
[    7.051235] random: ubusd: uninitialized urandom read (4 bytes read)
[    7.060576] procd: - init -
[    7.582399] kmodloader: loading kernel modules from /etc/modules.d/*
[    7.628303] Loading modules backported from Linux version v5.8.18-0-gab435ce49bd1
[    7.635945] Backport generated by backports.git v5.8.18-1-0-ga630fd46
[    7.693651] xt_time: kernel timezone is -0000
[    7.812897] PPP generic driver version 2.4.2
[    7.823647] NET: Registered protocol family 24
[    7.885874] urngd: v1.0.2 started.
[    7.898808] ath10k 5.8 driver, optimized for CT firmware, probing pci device: 0x3c.
[    7.919313] ath10k_pci 0000:00:00.0: enabling device (0000 -> 0002)
[    7.927915] ath10k_pci 0000:00:00.0: pci irq legacy oper_irq_mode 1 irq_mode 0 reset_mode 0
[    8.106724] random: crng init done
[   11.419423] ath10k_pci 0000:00:00.0: qca988x hw2.0 target 0x4100016c chip_id 0x043202ff sub 0000:0000
[   11.428833] ath10k_pci 0000:00:00.0: kconfig debug 0 debugfs 1 tracing 0 dfs 1 testmode 0
[   11.441066] ath10k_pci 0000:00:00.0: firmware ver 10.1-ct-8x-__fW-022-ecad3248 api 2 features wmi-10.x,has-wmi-mgmt-tx,mfp,txstatus-noack,wmi-10.x-CT,ratemask-CT,txrate-CT,get-temp-CT,tx-rc-CT,cust-stats-CT,retry-gt2-CT,txrate2-CT,beacon-cb-CT,wmi-block-ack-CT crc32 3e4cf97f
[   11.774353] ath10k_pci 0000:00:00.0: board_file api 1 bmi_id N/A crc32 bebc7c08
[   12.698699] ath10k_pci 0000:00:00.0: 10.1 wmi init: vdevs: 16  peers: 127  tid: 256
[   12.715987] ath10k_pci 0000:00:00.0: wmi print 'P 128 V 8 T 410'
[   12.722313] ath10k_pci 0000:00:00.0: wmi print 'msdu-desc: 1424  sw-crypt: 0 ct-sta: 0'
[   12.730460] ath10k_pci 0000:00:00.0: wmi print 'alloc rem: 24984 iram: 38672'
[   12.784302] ath10k_pci 0000:00:00.0: htt-ver 2.1 wmi-op 2 htt-op 2 cal file max-sta 128 raw 0 hwcrypto 1
[   12.798565] ath10k_pci 0000:00:00.0: NOTE:  Firmware DBGLOG output disabled in debug_mask: 0x10000000
[   12.909994] ath: EEPROM regdomain sanitized
[   12.910002] ath: EEPROM regdomain: 0x64
[   12.910006] ath: EEPROM indicates we should expect a direct regpair map
[   12.910023] ath: Country alpha2 being used: 00
[   12.910026] ath: Regpair used: 0x64
[   12.979460] ath: EEPROM regdomain sanitized
[   12.979469] ath: EEPROM regdomain: 0x64
[   12.979473] ath: EEPROM indicates we should expect a direct regpair map
[   12.979491] ath: Country alpha2 being used: 00
[   12.979494] ath: Regpair used: 0x64
[   12.996552] ieee80211 phy1: Selected rate control algorithm 'minstrel_ht'
[   12.998256] ieee80211 phy1: Atheros AR9550 Rev:0 mem=0xb8100000, irq=12
[   13.039051] kmodloader: done loading kernel modules from /etc/modules.d/*
[   31.933229] br-lan: port 1(eth0) entered blocking state
[   31.938587] br-lan: port 1(eth0) entered disabled state
[   31.944175] device eth0 entered promiscuous mode
[   34.984024] eth0: link up (1000Mbps/Full duplex)
[   34.988922] br-lan: port 1(eth0) entered blocking state
[   34.994257] br-lan: port 1(eth0) entered forwarding state
[   35.001426] IPv6: ADDRCONF(NETDEV_CHANGE): br-lan: link becomes ready
[   73.894812] eth0: link down
[   73.898197] br-lan: port 1(eth0) entered disabled state
[   79.016017] eth0: link up (100Mbps/Full duplex)
[   79.020800] br-lan: port 1(eth0) entered blocking state
[   79.026127] br-lan: port 1(eth0) entered forwarding state
[  161.958805] eth0: link down
[  161.962182] br-lan: port 1(eth0) entered disabled state
[  164.008015] eth0: link up (100Mbps/Full duplex)
[  164.012792] br-lan: port 1(eth0) entered blocking state
[  164.018116] br-lan: port 1(eth0) entered forwarding state
[  246.950804] eth0: link down
[  246.954190] br-lan: port 1(eth0) entered disabled state
[  250.024015] eth0: link up (100Mbps/Full duplex)
[  250.028795] br-lan: port 1(eth0) entered blocking state
[  250.034126] br-lan: port 1(eth0) entered forwarding state
[  268.454804] eth0: link down
[  268.458185] br-lan: port 1(eth0) entered disabled state
[  270.504011] eth0: link up (1000Mbps/Full duplex)
[  270.508886] br-lan: port 1(eth0) entered blocking state
[  270.514217] br-lan: port 1(eth0) entered forwarding state

Ops.... Forgot to mention that LEDS are fine now.

1 Like

Are you planning to build some other image to test or I can try to flash this last one?
If I can go ahead... any other tip before flashing?

now is a good time to say that many of these Engenius and WatchGuard devices have a "failsafe" image that loads in case a firmware upgrade fails, or the kernel or rootfs gets damaged somehow. It allows you to upload a new image by ethernet or wireless.

it can be triggered by erasing a checksum from the uboot environment

fw_setenv rootfs_checksum 0

if you had access to UART console for uboot, you would be able to boot the failsafe image manually

run failsafe_boot

this is Watchguard's documentation of it

https://techsearch.watchguard.com/KB/WGKnowledgeBase?lang=en_US&SFDCID=kA2F00000000LnWKAU&type=KBArticle

1 Like

I will give you a factory.bin soon on the gist

1 Like

Yeap. I already recovered one or two times using it, but when this happens there is no escape from getting device in hand to recover it.
Default behavior on these guys is DHCP client and this already saved me a lot of trouble when need to reset them in place or remote from miles away to default to re-pair with WLC, fix some bad config or like this.
By the way. Are you aware of some project or product to manage centrally OpenWrt devices?

1 Like

I don´t want to abuse, but I didn´t found Switch Menu to set VLAN´s. Is difficult to add it to next build?

1 Like

yeah there is several projects using Ansible
https://github.com/danielvijge/openwrt-configuration-ansible

this device does not have a switch, so VLAN has to be set by making a virtual interface

there is limited documentation on this but here is what I found

https://openwrt.org/docs/guide-user/network/vlan/managed_switch#without_programmable_switch

1 Like

With the CPU connected directly to single port PHY chip, it should work to declare VLANs using the notation eth0.N directly in the network config.

1 Like

Hi @mk24 Coincidently I´m reading your comment on another thread about this just now...

So there's no graphic way to set it up on single port devices like this?

1 Like

Go to a network's physical settings and pull down the list of devices type eth0.N at the bottom (N is your VLAN number) and press enter to create that VLAN directly on the port.

4 Likes

OK, Thanks, got it..

1 Like

Now occurred me... How to set tagged x untagged?
let's say I want to eth0.10 be untagged

1 Like

eth0.10 will send and receive packets tagged 10 on the cable. eth0 by itself is untagged.

This affects only the signals on the Ethernet cable. There's no such thing as tagged packets within a software bridge. They are just packets. They are isolated from other networks because the bridge is separate from other bridges.

It is problematic mixing tagged and untagged on the same cable. Usually when you want more than one network on the line tag everything. Configure eth0.10 in one network, eth0.20 in another. Don't have plain eth0 active anywhere.

3 Likes