OpenWrt Forum Archive

Topic: WL-351 adding USB port(WIP) - OpenWRT on a Sitecom WL-351(WIP)

The content of this topic has been archived between 4 Mar 2018 and 8 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Hello,

Im trying to get openWRT working on my sitecom-wl351.

This is what i did:
found the page : Sitecom WL-351
and started searching for a Image
I saw in the logs "openwrt-ramips-rt305x-wl-351-squashfs-sysupgrade.bin" and started googleling it. and with succes.

Since then i had probably the right image. but after i flashed it using the TTL and TFTP server method in the bootloader. something was not right.

Im still able to get in contact with the router but for some reason the OpenWRT install can't access the RTL8366RB switch.
So none of my lan ports are working.

Wlan is working and and i can get a DHCP ip assigned. I can ping the router from a Wlan-client. but i cannot ping that Wlan-client from  the router side. very strange. even with a disabled firewall

root@OpenWrt:/# etc/init.d/network restart
[  137.140000] br-lan: port 1(eth0.1) entered disabled state
[  137.160000] device eth0.1 left promiscuous mode
[  137.170000] br-lan: port 1(eth0.1) entered disabled state
[  137.430000] device eth0 left promiscuous mode
Failed to connect to the switch
[  139.600000] device eth0.1 entered promiscuous mode
[  139.610000] device eth0 entered promiscuous mode
[  139.640000] br-lan: port 1(eth0.1) entered forwarding state
[  139.650000] br-lan: port 1(eth0.1) entered forwarding state

no matter what i change in the /etc/config/network file nothing seems to help. and i cant see anthing related to a RTL8366RB driver loaded. so maybe its not compiled in this kernel? which would be very strange since its writen for the WL-351 and even flashed in the OpenWRT doc page.

This is the Default one after flashing...

root@OpenWrt:/# cat /etc/config/network

config interface 'loopback'
        option ifname 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config interface 'lan'
        option ifname 'eth0.1'
        option type 'bridge'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option macaddr [ROUTER LAN MAC]'

config interface 'wan'
        option ifname 'eth0.2'
        option proto 'dhcp'
        option macaddr '[ROUTER WAN MAC]'

config switch
        option name 'switch0'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'switch0'
        option vlan '1'
        option ports '0 1 2 3 5t'

config switch_vlan
        option device 'switch0'
        option vlan '2'
        option ports '4 5t'

is there anyone that can help me with this? Thanks
Regards,
Timeless

(Last edited by Timeless on 18 May 2016, 22:51)

I have an idea but some check needed. Pls, show output of commands (switch configurations):

swconfig dev switch0 show
swconfig dev rt305x show
swconfig dev switch1 show
swconfig dev rtl8366rb show

Thanks for your reply!

These are the results:

root@OpenWrt:/# swconfig dev switch0 show
Failed to connect to the switch
root@OpenWrt:/# swconfig dev rt305x show
Failed to connect to the switch
root@OpenWrt:/# swconfig dev switch1 show
Failed to connect to the switch
root@OpenWrt:/# swconfig dev rtl8366rb show
Failed to connect to the switch

Here an "ifconfig" command:

root@OpenWrt:/# ifconfig
br-lan    Link encap:Ethernet  HWaddr [ROUTER LAN MAC]
          inet addr:192.168.1.1  Bcast:192.168.1.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:917 errors:0 dropped:203 overruns:0 frame:0
          TX packets:318 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:131540 (128.4 KiB)  TX bytes:27471 (26.8 KiB)

eth0      Link encap:Ethernet  HWaddr 00:11:22:33:44:55[strange MAC?]
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1155 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:351498 (343.2 KiB)
          Interrupt:5

eth0.1    Link encap:Ethernet  HWaddr 00:11:22:33:44:55[strange MAC?]
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:587 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 B)  TX bytes:118082 (115.3 KiB)

eth0.2    Link encap:Ethernet  HWaddr [ROUTER WAN MAC]
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:568 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 B)  TX bytes:228336 (222.9 KiB)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:13488 errors:0 dropped:0 overruns:0 frame:0
          TX packets:13488 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:917184 (895.6 KiB)  TX bytes:917184 (895.6 KiB)

wlan0     Link encap:Ethernet  HWaddr [ROUTER LAN MAC]
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:916 errors:0 dropped:0 overruns:0 frame:0
          TX packets:903 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:32
          RX bytes:144358 (140.9 KiB)  TX bytes:161385 (157.6 KiB)

(Last edited by Timeless on 26 Oct 2012, 19:54)

-Bump-

No one that can help me with this problem?

Regards,
Timeless

I have this router as well and there was one thing I notice immediately, the kernel module for the RTL8366RB chip is not installed/loaded by default in the image for this router, so you have to install that first but need to get the network config working.

Make a backup of the network config first!

cp /etc/config/network /root/

I've changed the network config to the following:

config interface 'loopback'
        option ifname 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config interface 'lan'
        option ifname 'eth0.1'
        option type 'bridge'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option macaddr '*removed*'

config interface 'wan'
        option ifname 'eth0'
        option proto 'dhcp'

Then restart the network config and insert the internet cable in port 0 (that is the first yellow port next to the power socket:

/etc/init.d/network restart

Then update the OPKG software list and install the appropriate kernel module for the switch chip:

opkg update
opkg install kmod-switch-rtl8366rb

When finished, copy back the backupped network config:

cp /root/network /etc/config/

Reboot the device:

reboot

When it's back online, one thing to notice is that the command:

swconfig dev rtl8366rb show

Now works and shows the status of all ports, tested that by plugging in cables in random ports and it detected it, see results below:

root@OpenWrt:/# swconfig dev rtl8366rb show
Global attributes:
        enable_learning: 1
        enable_vlan: 1
        enable_vlan4k: 0
        blinkrate: 0
        enable_qos: 1
Port 0:
        mib: Port 0 MIB counters
IfInOctets                          : 21064
EtherStatsOctets                    : 21064
EtherStatsUnderSizePkts             : 0
EtherFragments                      : 0
EtherStatsPkts64Octets              : 37
EtherStatsPkts65to127Octets         : 28
EtherStatsPkts128to255Octets        : 3
EtherStatsPkts256to511Octets        : 19
EtherStatsPkts512to1023Octets       : 14
EtherStatsPkts1024to1518Octets      : 0
EtherOversizeStats                  : 0
EtherStatsJabbers                   : 0
IfInUcastPkts                       : 0
EtherStatsMulticastPkts             : 75
EtherStatsBroadcastPkts             : 26
EtherStatsDropEvents                : 0
Dot3StatsFCSErrors                  : 0
Dot3StatsSymbolErrors               : 0
Dot3InPauseFrames                   : 0
Dot3ControlInUnknownOpcodes         : 0
IfOutOctets                         : 2613
Dot3StatsSingleCollisionFrames      : 0
Dot3StatMultipleCollisionFrames     : 0
Dot3sDeferredTransmissions          : 0
Dot3StatsLateCollisions             : 0
EtherStatsCollisions                : 0
Dot3StatsExcessiveCollisions        : 0
Dot3OutPauseFrames                  : 0
Dot1dBasePortDelayExceededDiscards  : 0
Dot1dTpPortInDiscards               : 0
IfOutUcastPkts                      : 0
IfOutMulticastPkts                  : 12
IfOutBroadcastPkts                  : 18

        led: 2
        disable: 0
        rate_in: 1048512
        rate_out: 1048512
        pvid: 1
        link: port:0 link:down
Port 1:
        mib: Port 1 MIB counters
IfInOctets                          : 0
EtherStatsOctets                    : 0
EtherStatsUnderSizePkts             : 0
EtherFragments                      : 0
EtherStatsPkts64Octets              : 0
EtherStatsPkts65to127Octets         : 0
EtherStatsPkts128to255Octets        : 0
EtherStatsPkts256to511Octets        : 0
EtherStatsPkts512to1023Octets       : 0
EtherStatsPkts1024to1518Octets      : 0
EtherOversizeStats                  : 0
EtherStatsJabbers                   : 0
IfInUcastPkts                       : 0
EtherStatsMulticastPkts             : 0
EtherStatsBroadcastPkts             : 0
EtherStatsDropEvents                : 0
Dot3StatsFCSErrors                  : 0
Dot3StatsSymbolErrors               : 0
Dot3InPauseFrames                   : 0
Dot3ControlInUnknownOpcodes         : 0
IfOutOctets                         : 0
Dot3StatsSingleCollisionFrames      : 0
Dot3StatMultipleCollisionFrames     : 0
Dot3sDeferredTransmissions          : 0
Dot3StatsLateCollisions             : 0
EtherStatsCollisions                : 0
Dot3StatsExcessiveCollisions        : 0
Dot3OutPauseFrames                  : 0
Dot1dBasePortDelayExceededDiscards  : 0
Dot1dTpPortInDiscards               : 0
IfOutUcastPkts                      : 0
IfOutMulticastPkts                  : 0
IfOutBroadcastPkts                  : 0

        led: 3
        disable: 0
        rate_in: 1048512
        rate_out: 1048512
        pvid: 2
        link: port:1 link:down
Port 2:
        mib: Port 2 MIB counters
IfInOctets                          : 221637
EtherStatsOctets                    : 221637
EtherStatsUnderSizePkts             : 0
EtherFragments                      : 0
EtherStatsPkts64Octets              : 0
EtherStatsPkts65to127Octets         : 298
EtherStatsPkts128to255Octets        : 81
EtherStatsPkts256to511Octets        : 496
EtherStatsPkts512to1023Octets       : 0
EtherStatsPkts1024to1518Octets      : 0
EtherOversizeStats                  : 0
EtherStatsJabbers                   : 0
IfInUcastPkts                       : 0
EtherStatsMulticastPkts             : 724
EtherStatsBroadcastPkts             : 151
EtherStatsDropEvents                : 0
Dot3StatsFCSErrors                  : 0
Dot3StatsSymbolErrors               : 0
Dot3InPauseFrames                   : 0
Dot3ControlInUnknownOpcodes         : 0
IfOutOctets                         : 0
Dot3StatsSingleCollisionFrames      : 0
Dot3StatMultipleCollisionFrames     : 0
Dot3sDeferredTransmissions          : 0
Dot3StatsLateCollisions             : 0
EtherStatsCollisions                : 0
Dot3StatsExcessiveCollisions        : 0
Dot3OutPauseFrames                  : 0
Dot1dBasePortDelayExceededDiscards  : 0
Dot1dTpPortInDiscards               : 0
IfOutUcastPkts                      : 0
IfOutMulticastPkts                  : 0
IfOutBroadcastPkts                  : 0

        led: 4
        disable: 0
        rate_in: 1048512
        rate_out: 1048512
        pvid: 3
        link: port:2 link:up speed:1000baseT full-duplex txflow rxflow
Port 3:
        mib: Port 3 MIB counters
IfInOctets                          : 4998
EtherStatsOctets                    : 4998
EtherStatsUnderSizePkts             : 0
EtherFragments                      : 0
EtherStatsPkts64Octets              : 0
EtherStatsPkts65to127Octets         : 0
EtherStatsPkts128to255Octets        : 1
EtherStatsPkts256to511Octets        : 13
EtherStatsPkts512to1023Octets       : 0
EtherStatsPkts1024to1518Octets      : 0
EtherOversizeStats                  : 0
EtherStatsJabbers                   : 0
IfInUcastPkts                       : 0
EtherStatsMulticastPkts             : 14
EtherStatsBroadcastPkts             : 0
EtherStatsDropEvents                : 0
Dot3StatsFCSErrors                  : 0
Dot3StatsSymbolErrors               : 0
Dot3InPauseFrames                   : 0
Dot3ControlInUnknownOpcodes         : 0
IfOutOctets                         : 0
Dot3StatsSingleCollisionFrames      : 0
Dot3StatMultipleCollisionFrames     : 0
Dot3sDeferredTransmissions          : 0
Dot3StatsLateCollisions             : 0
EtherStatsCollisions                : 0
Dot3StatsExcessiveCollisions        : 0
Dot3OutPauseFrames                  : 0
Dot1dBasePortDelayExceededDiscards  : 0
Dot1dTpPortInDiscards               : 0
IfOutUcastPkts                      : 0
IfOutMulticastPkts                  : 0
IfOutBroadcastPkts                  : 0

        led: 0
        disable: 0
        rate_in: 1048512
        rate_out: 1048512
        pvid: 4
        link: port:3 link:down
Port 4:
        mib: Port 4 MIB counters
IfInOctets                          : 545064
EtherStatsOctets                    : 545064
EtherStatsUnderSizePkts             : 0
EtherFragments                      : 0
EtherStatsPkts64Octets              : 166
EtherStatsPkts65to127Octets         : 234
EtherStatsPkts128to255Octets        : 183
EtherStatsPkts256to511Octets        : 265
EtherStatsPkts512to1023Octets       : 119
EtherStatsPkts1024to1518Octets      : 204
EtherOversizeStats                  : 0
EtherStatsJabbers                   : 0
IfInUcastPkts                       : 388
EtherStatsMulticastPkts             : 601
EtherStatsBroadcastPkts             : 182
EtherStatsDropEvents                : 0
Dot3StatsFCSErrors                  : 0
Dot3StatsSymbolErrors               : 0
Dot3InPauseFrames                   : 0
Dot3ControlInUnknownOpcodes         : 0
IfOutOctets                         : 34294
Dot3StatsSingleCollisionFrames      : 0
Dot3StatMultipleCollisionFrames     : 0
Dot3sDeferredTransmissions          : 3
Dot3StatsLateCollisions             : 0
EtherStatsCollisions                : 0
Dot3StatsExcessiveCollisions        : 0
Dot3OutPauseFrames                  : 0
Dot1dBasePortDelayExceededDiscards  : 0
Dot1dTpPortInDiscards               : 0
IfOutUcastPkts                      : 407
IfOutMulticastPkts                  : 7
IfOutBroadcastPkts                  : 2

        led: ???
        disable: 0
        rate_in: 1048512
        rate_out: 1048512
        pvid: 5
        link: port:4 link:up speed:1000baseT full-duplex txflow rxflow
Port 5:
        mib: Port 5 MIB counters
IfInOctets                          : 155629
EtherStatsOctets                    : 155629
EtherStatsUnderSizePkts             : 0
EtherFragments                      : 0
EtherStatsPkts64Octets              : 0
EtherStatsPkts65to127Octets         : 1990
EtherStatsPkts128to255Octets        : 13
EtherStatsPkts256to511Octets        : 27
EtherStatsPkts512to1023Octets       : 0
EtherStatsPkts1024to1518Octets      : 0
EtherOversizeStats                  : 0
EtherStatsJabbers                   : 0
IfInUcastPkts                       : 407
EtherStatsMulticastPkts             : 175
EtherStatsBroadcastPkts             : 1448
EtherStatsDropEvents                : 0
Dot3StatsFCSErrors                  : 0
Dot3StatsSymbolErrors               : 0
Dot3InPauseFrames                   : 0
Dot3ControlInUnknownOpcodes         : 0
IfOutOctets                         : 792763
Dot3StatsSingleCollisionFrames      : 0
Dot3StatMultipleCollisionFrames     : 0
Dot3sDeferredTransmissions          : 3
Dot3StatsLateCollisions             : 0
EtherStatsCollisions                : 0
Dot3StatsExcessiveCollisions        : 0
Dot3OutPauseFrames                  : 0
Dot1dBasePortDelayExceededDiscards  : 0
Dot1dTpPortInDiscards               : 1584
IfOutUcastPkts                      : 388
IfOutMulticastPkts                  : 1414
IfOutBroadcastPkts                  : 359

        led: ???
        disable: 0
        rate_in: 1048512
        rate_out: 1048512
        pvid: 6
        link: port:5 link:up speed:1000baseT full-duplex txflow rxflow auto
VLAN 1:
        info: VLAN 1: Ports: '05', members=0021, untag=0021, fid=0
        fid: 0
        ports: 0 5
VLAN 2:
        info: VLAN 2: Ports: '15', members=0022, untag=0022, fid=0
        fid: 0
        ports: 1 5
VLAN 3:
        info: VLAN 3: Ports: '25', members=0024, untag=0024, fid=0
        fid: 0
        ports: 2 5
VLAN 4:
        info: VLAN 4: Ports: '35', members=0028, untag=0028, fid=0
        fid: 0
        ports: 3 5
VLAN 5:
        info: VLAN 5: Ports: '45', members=0030, untag=0030, fid=0
        fid: 0
        ports: 4 5
VLAN 6:
        info: VLAN 6: Ports: '012345', members=003f, untag=003f, fid=0
        fid: 0
        ports: 0 1 2 3 4 5

The switch config can also be accessed now, but strangely, that does not seem to recognize the port states which the rtl8366rb sees, because in my paste above you can see that port 2 is up and below it's down:

root@OpenWrt:/# swconfig dev switch0 show
Global attributes:
        enable_vlan: 1
        alternate_vlan_disable: 0
Port 0:
        disable: 0
        doubletag: 0
        untag: 1
        led: 0
        lan: 1
        recv_bad: 0
        recv_good: 0
        pvid: 1
        link: port:0 link:down
Port 1:
        disable: 0
        doubletag: 0
        untag: 1
        led: 0
        lan: 1
        recv_bad: 0
        recv_good: 0
        pvid: 1
        link: port:1 link:down
Port 2:
        disable: 0
        doubletag: 0
        untag: 1
        led: 0
        lan: 1
        recv_bad: 0
        recv_good: 0
        pvid: 1
        link: port:2 link:down
Port 3:
        disable: 0
        doubletag: 0
        untag: 1
        led: 0
        lan: 1
        recv_bad: 0
        recv_good: 0
        pvid: 1
        link: port:3 link:down
Port 4:
        disable: 0
        doubletag: 0
        untag: 1
        led: 0
        lan: 1
        recv_bad: 0
        recv_good: 0
        pvid: 2
        link: port:4 link:down
Port 5:
        disable: 0
        doubletag: 0
        untag: 0
        led: ???
        lan: 1
        recv_bad: 0
        recv_good: 2231
        pvid: 0
        link: port:5 link:up speed:1000baseT full-duplex
Port 6:
        disable: 0
        doubletag: 0
        untag: 0
        led: ???
        lan: ???
        recv_bad: ???
        recv_good: ???
        pvid: 0
        link: port:6 link:up speed:1000baseT full-duplex
VLAN 1:
        ports: 0 1 2 3 5t
VLAN 2:
        ports: 4 5t

And the output of rt305x is the same as above:

root@OpenWrt:/# swconfig dev rt305x show
Global attributes:
        enable_vlan: 1
        alternate_vlan_disable: 0
Port 0:
        disable: 0
        doubletag: 0
        untag: 1
        led: 0
        lan: 1
        recv_bad: 0
        recv_good: 0
        pvid: 1
        link: port:0 link:down
Port 1:
        disable: 0
        doubletag: 0
        untag: 1
        led: 0
        lan: 1
        recv_bad: 0
        recv_good: 0
        pvid: 1
        link: port:1 link:down
Port 2:
        disable: 0
        doubletag: 0
        untag: 1
        led: 0
        lan: 1
        recv_bad: 0
        recv_good: 0
        pvid: 1
        link: port:2 link:down
Port 3:
        disable: 0
        doubletag: 0
        untag: 1
        led: 0
        lan: 1
        recv_bad: 0
        recv_good: 0
        pvid: 1
        link: port:3 link:down
Port 4:
        disable: 0
        doubletag: 0
        untag: 1
        led: 0
        lan: 1
        recv_bad: 0
        recv_good: 0
        pvid: 2
        link: port:4 link:down
Port 5:
        disable: 0
        doubletag: 0
        untag: 0
        led: ???
        lan: 1
        recv_bad: 0
        recv_good: 2325
        pvid: 0
        link: port:5 link:up speed:1000baseT full-duplex
Port 6:
        disable: 0
        doubletag: 0
        untag: 0
        led: ???
        lan: ???
        recv_bad: ???
        recv_good: ???
        pvid: 0
        link: port:6 link:up speed:1000baseT full-duplex
VLAN 1:
        ports: 0 1 2 3 5t
VLAN 2:
        ports: 4 5t

For the record, my network config is the default one (removed mac's):

root@OpenWrt:/# cat /etc/config/network

config interface 'loopback'
        option ifname 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config interface 'lan'
        option ifname 'eth0.1'
        option type 'bridge'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'

config interface 'wan'
        option ifname 'eth0.2'
        option proto 'static'
        option ipaddr '192.168.0.99'
        option netmask '255.255.255.0'

config switch
        option name 'switch0'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'switch0'
        option vlan '1'
        option ports '0 1 2 3 5t'

config switch_vlan
        option device 'switch0'
        option vlan '2'
        option ports '4 5t'

What I conclude out of this is that the switching part does not function properly, I've setup wireless as well and am able to connect with it and connect to luci, but the switch configuration shows that no ports are linked at the moment, just as the output of the commands above show.

I'm wondering what I can do to make the network config work, because as far as I can see, it should be setup correctly now with the right modules loaded.

I think that your device have 2 switches:
- switch0 = rt305x (internal ralink switch with port6 as CPU port or eth0)
- switch1 = rtl8366rb (external realtek GE switch)

Both switches are connected through ports 5  if I'm not mistaken. But your config for switch0 (ralink internal switch) isolates port6 (CPU port). So at least you need change 'switch0' to 'switch1' or explicitly 'rtl8366rb' in your config file. If unconfigured ralink switch acts as dumb hub (pass packet to all ports untouched) it may work. Else you may add vlan1 and vlan2 with tagged ports 5 6 explicitly to 'rt305x' switch.

Hi,

Thanks for yout tips! I've put them together in the following config, is that correct?

config interface 'loopback'
        option ifname 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config interface 'lan'
        option ifname 'eth0.1'
        option type 'bridge'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option macaddr '*removed*'

config interface 'wan'
        option ifname 'eth0.2'
        option proto 'dhcp'
        option macaddr '*removed*'

config switch
        option enable '1'
        option name 'rtl8366rb'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'rtl8366rb'
        option vlan '1'
        option ports '0 1 2 3 5t 6t'

config switch_vlan
        option device 'rtl8366rb'
        option vlan '2'
        option ports '4 5t 6t'

When I apply this, the results stays the same, but maybe I am misunderstanding you smile. What I do notice is when restarting the network, all switch leds light up for a second and then reset themselves, after a couple of seconds the WAN led comes back up, but still eth0.2 (wan interface) does not get an IP address. I feel that we're almost there.

(Last edited by langerak on 15 Feb 2013, 15:03)

Try next switch config

config switch
        option name 'switch1'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'switch1'
        option vlan '1'
        option ports '0 1 2 3 5t'

config switch_vlan
        option device 'switch1'
        option vlan '2'
        option ports '4 5t'

Then see recv_good of switch0 ports 5 6. If not work - add

config switch
        option name 'switch0'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'switch0'
        option vlan '1'
        option ports '5t 6t'

config switch_vlan
        option device 'switch0'
        option vlan '2'
        option ports '5t 6t'

FIXED!

I've updated the config file, the first part makes a differenct, it talks to the rtl8366rb chip, because upon restarting the network, all switch leds light up for a second and then reset themselves!

For reference, this config works on my WL-351 (still have some questions):

config interface 'loopback'
        option ifname 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config interface 'lan'
        option ifname 'eth0.1'
        option type 'bridge'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option macaddr '00:0c:f6:67:d1:80'

config interface 'wan'
        option ifname 'eth0.2'
        option proto 'dhcp'
        option macaddr '00:0c:f6:67:d1:81'

config switch
        option name 'switch1'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'switch1'
        option vlan '1'
        option ports '0 1 2 3 5t'

config switch_vlan
        option device 'switch1'
        option vlan '2'
        option ports '4 5t'

config switch
        option name 'switch0'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'switch0'
        option vlan '1'
        option ports '5t 6t'

config switch_vlan
        option device 'switch0'
        option vlan '2'
        option ports '5t 6t'

So thanks for your help! I hope that this will other users with this router as well smile!

Then I have some small questions remaining:

1. This router was for testing purposes and is already behind another router, a Linksys E3000, this Sitecom now works, can connect via Wifi and LAN and get a DHCP address, but am not able to connect to the internet. I see that DNS is working in such a way that I am able to use dig and lookup IP's, but when tracerouting them, it won't go past OpenWrt, do you happen to know some settings that I should look at?

2. Since this config works, where at openwrt can I make sure that this config (and the kernel module for the rtl8366rb) can be applied to the wl-351 image which the online version is now missing?

Thanks again!

Oh, one small question left:

I have IPv6 at home (configured via HE on the Linksys), the WAN interface has been given an IPv6 address, but Luci still says that I am not connected via IPv6, am I missing something?

Never mind question 1, it seems that the firewall was setup incorrectly, it was not set up to forward requests from LAN to WAN, therefore everything was stopped at the router smile.

One thing that constantly appears on the console is this message, are you familiar with it?

[15025.320000] br-lan: received packet on eth0.1 with own address as source address

By default the wifi led is on and shows no activity when there is traffic, this can be changed in /etc/config/system, add the following:

config led
        option name 'Wifi'
        option sysfs 'rt2800pci-phy0::radio'
        option default '1'
        option trigger 'netdev'
        option dev 'wlan0'
        option mode 'link tx rx'

This will light up the wifi led and let it blink if there is RX or TX on the wlan0 interface.

Thanks for the progress guys!
When I've time I will blow the dust of this project and start with fresh new inspiration. Ill posts the results anytime soon.

Regards,
Timeless

Right....

I've tested every configuration what is provided on this topic. but none of them works. Not even a statistic IP
But there is a little progress to notice:

I've flashed a new Image: Newest Image

After that the command :

root@OpenWrt:/# swconfig dev switch0 show

Does show me the switch layout and interface.

I also can login to Luci after Wireless is Enabled.

But for some reason i can't get my WAN connection to work, and because of that I can't use the commands:

opkg update

opkg install kmod-switch-rtl8366rb
root@OpenWrt:/# opkg update
Downloading http://downloads.openwrt.org/attitude_adjustment/12.09-rc1/ramips/rt305x/packages/Packages.gz.
wget: bad address 'downloads.openwrt.org'
Collected errors:
 * opkg_download: Failed to download http://downloads.openwrt.org/attitude_adjustment/12.09-rc1/ramips/rt305x/packages/Packages.gz, wget returned 1.

I've spend 4 hours on trying every config different images but there is no progress other that this.
What is the right Image and Config to get the Wan connecton to make an connection to my existing network so i can use the update command.

(Last edited by Timeless on 21 Feb 2013, 01:41)

I've experienced the same problems and could only get this to work with v12.09 rc2 (not with trunk). Note I've not tried rc1 or before.

I was able to flash the router using tftp with the binary:
http://downloads.openwrt.org/attitude_a … pgrade.bin

After that I could not modify the setup to get the WAN working (like Timeless and johndoe mention), I ended up doing the following:

- Manually download the following files to a wifi capable laptop:

http://downloads.openwrt.org/attitude_a … ramips.ipk
http://downloads.openwrt.org/attitude_a … ramips.ipk
http://downloads.openwrt.org/attitude_a … ramips.ipk
http://downloads.openwrt.org/attitude_a … ramips.ipk

- Enable WLAN on the router, (/etc/config/wireless), connect the wifi device with the files to it. DHCP should work (it did for me).

- Copy the files using scp to the router. I copied them to the /root/ user directory.

- Install the packages (in order of above list) using opkg install <insert package name>.ipk

- After this, the second switch was recognized and the /etc/config/network setup could be modified according to post #9 by langerak

Using the trunk snapshot (from the 22nd of April 2014 iirc) I was not able to get this to work. It seemed the rtl8366rb driver was already loaded, but the device was not available to swconfig.

I tried nearly a bin from each release, and even after adding the correct switch, I never was able to get any data going through the switch. After inserting the module (except for trunk) I can see and configure the switch; but no data at all. The RTL switch doesn't even function as a dumb switch. Since serial and tftp where used to load the image, the hardware seems to be fine.

Hmm, which hardware version do you have? There might be some different versions...?
There seems to be a lot of configurations that don't work. You could either have the newer firmwares rtl8366rb driver versions loaded which didn't work for me, or maybe some combination of not setting the switch config correctly (I used langerak's config). You probably used the RT3052 (or wireless RT28xx) for loading the image with tftp, so hardware might still be an issue (just the rtl8366rb malfunctioning). But then again, if with manufacturer firmware it just works...

Did you try with the 12.09rc2?

Hi people,

Long time no... eeuh "say"?
never mind, its been a while since I originally started this topic. But with the help from [langerak], others and a fresh mind/start I was able to config this device with working WAN LAN and WLAN.

Its now running version Attitude Adjustment 12.09. I also tried with the newest version Barrier Breaker 14.07 and loaded the correct drivers for the RTL8366RB switch but the LED's didn't light up. Also the switch was not accessible using the swconfig command.

Its strange since the rt305x switch was detected directly in version 14.07 where it is not in 12.09 and the RTL8366RB needed additional drivers in both versions. nevertheless the RB8366RB is not working with 14.07.

Next Question:

I see in the OpenWRT log something about USB smile

hub 1-0:1.0 USB hub found
hub 1-0:1.0: 1 port detected

Could it be that there is a hidden USB somewhere?
Maybe if someone is still working with this device. give me a reply wink

(Last edited by Timeless on 5 Feb 2015, 00:03)

Timeless, I'm having the same problem hehe.
Could you perhaps share the method how you got it working?

My problem is: no space on the device hehe. I think I'll try make a minimal image (without the USB stuff and possible without lots of other stuff that's not needed). Then it should be possible to have a full luci running for configuration.

If anyone would like the image, I'll just post it here if it works :-)

Hi,
Sorry for the late reply. hehe

but what I did was downloading the ramips-rt305x-wl-351-squashfs sysupgrade image and flashed it using tftp and commands on the ttl-serial bus.

The problems I had were related to network configurations and switch drivers. And not about storage problems.

What image are you trying? I'm kind of curious tongue

Ps.
I was not able to find the USB pinout or connections yet. So any help is appreciated

(Last edited by Timeless on 5 May 2015, 10:52)

Anyone having tips how to find the USB pinout on the wl-351 used RT3052 soc?

(Last edited by Timeless on 8 May 2015, 23:34)

Hello anyone.
I still have these kinds of problems on my unit.
The flashing works fine, I can do all the solutions provided here, even on a lot of different versions.
But the rtl8366 driver still does not seem to load.
swconfig list replies with only the rt305x as switch 0.
Can someone please explain this?
Thx!

jackorobot wrote:

Hello anyone.
I still have these kinds of problems on my unit.
The flashing works fine, I can do all the solutions provided here, even on a lot of different versions.
But the rtl8366 driver still does not seem to load.
swconfig list replies with only the rt305x as switch 0.
Can someone please explain this?
Thx!

the same as you. the openwrt couldn't work on wl-351 except 12.09.
also 14.07,15.05 and trunk couldn't work .and i have installed and loaded the driver(4 ipk files:swconfig rtl8366rb and then) ,the wl351 could recogize the switch 1 as rtl8366rb,and it could work in the router .

when i get in wl 351 with ssh, it shows the right status when the cable pluged to the port.
i will post the img later.sorry,my english is poor.

wuxeon wrote:

the same as you. the openwrt couldn't work on wl-351 except 12.09.
also 14.07,15.05 and trunk couldn't work .and i have installed and loaded the driver(4 ipk files:swconfig rtl8366rb and then) ,the wl351 could recogize the switch 1 as rtl8366rb,and it could work in the router .

when i get in wl 351 with ssh, it shows the right status when the cable pluged to the port.
i will post the img later.sorry,my english is poor.

Thanks for the reply.
As far as I understood I tried all you said.
I used 15.05, 14.07 and 12.09.
With all of those the rt305x switch was found without needing to update the module.
But even after installing all modules concerning the rtl8366 it still did not find the device.
I can access wireless no problem, but the switching part is still not working.
The WAN connection is also not working.

(Last edited by jackorobot on 9 Nov 2015, 14:32)