1 (edited by Barx 2011-01-06 16:13:38)

Topic: Need help for d-link DIR-300 rev. B1

sorry for the cross-post, I think it's better if I create a new thread

I've read these threads
https://forum.openwrt.org/viewtopic.php?id=27793
https://forum.openwrt.org/viewtopic.php?id=19281&p=1

I tried several times to build openwrt for DIR-300 B1, But I always get a brick.
I've done the following steps:

Got v2image from ftp://ftp.dlink.com/GPL/DIR-300_revB/dir300b.v2.02.source.tar.gz (I've extracted only the v2image executable file and put it in /usr/local/bin )

svn co svn://svn.openwrt.org/openwrt/trunk/
cd trunk
./scripts/feeds update -a
./scripts/feeds install -a
make menuconfig

I've set the following:
Target System - Ralink RT288x/RT305x
Subtarget - RT305x based boards

Added the packages autossh (the unique package I really need)
All the rest by default, no changes.

make
cd bin/ramips/

v2image -v -i openwrt-ramips-rt305x-dir-300-b1-squashfs-sysupgrade.bin -o openwrt-dir300b1-squashfs-webflash.bin -d /dev/mtdblock/2 -s wrgn23_dlwbr_dir300b
(as reported on http://wiki.openwrt.org/toh/d-link/dir-300revb )

The image is less then 3Mb

Flashed the new firmware (openwrt-dir300b1-squashfs-webflash.bin) using web Emergency Room.

The flash process seems to proceed without problems.
When the router reboots there no way to connect (I assume that it should get IP 192.168.1.1 on the LAN interface)
No way to connect via http, telnet or ssh, no wireless lan detected

Do anyone can help me to understand where I'm wrong?

Or someone can post the config and/or a working image for DIR-300 B1 ?

Re: Need help for d-link DIR-300 rev. B1

Hi Barx,
we've got the same problem with Rev. B. Only the recovery mode is working after flashing, nothing else.
The image was created on a Ubuntu x86 10.10 machine.
The program v2image was copied into the /trunk/bin/ramips/ directory before executing.

Is there anybody out there who can help?

BR schmelle2

Re: Need help for d-link DIR-300 rev. B1

+1

Have you tried to connect via serial interface? Mine is ready. I will post my results here, as soon as I can get the signal converter.

Re: Need help for d-link DIR-300 rev. B1

Thanks for your reply.
I'm back on Wednesday evening and will check if the DIR-300 will talk to me via the serial connection.

BR schmelle2

Re: Need help for d-link DIR-300 rev. B1

Maybe I can check the serial connection on Monday. Don't forget to use 3.3V only!

Re: Need help for d-link DIR-300 rev. B1

Hi,
the DIR-300 Rev. B1E is talking to me via the serial port by using 57600 8N1.
All Network ports are not working (no DHCP or other activities).
WLAN is only working if one line within /etc/network/wireless is commented out.
Because DHCP is not working properly (service is running), I got no IP via WLAN.
This is the state from this evening. It seems that one or two important packages are missed for VLAN and whatever.

Is there anybody out there who can help?

Tried with the last SVN from today.


Thanks,

schmelle2

Re: Need help for d-link DIR-300 rev. B1

My D-Link gets a whiered MAC-Adress, something like 11:22:33:44.. can you confirm that?

Re: Need help for d-link DIR-300 rev. B1

What is the status of this port, can we get some help from dd-wrt where they do have support?

Re: Need help for d-link DIR-300 rev. B1

For me it seems like it worked for some time, but some patches on different parts of OpenWRT "broke" the compatibility again. So maybe/hopefully it is just a "tiny" bug to fix...

Re: Need help for d-link DIR-300 rev. B1

Fix for wired network problem:
https://lists.openwrt.org/pipermail/openwrt-devel/2011-February/009759.html

11 (edited by RedDog 2011-03-03 22:16:55)

Re: Need help for d-link DIR-300 rev. B1

I've got Wifi working. :-)

trunk r25853:
* applied patch from scygan (link above)
* removed 002-disable_rfkill.patch from package/mac80211/patches/
* removed 015-remove-rt2x00-options.patch from package/mac80211/patches/
* added "CONFIG_RFKILL=y" to target/linux/ramips/rt305x/config-2.6.36
* Of course i have added rfkill userspace software.

Re: Need help for d-link DIR-300 rev. B1

Wired access is possible changing ./package/base-files/files/etc/config/network:

...
config interface lan
-      option ifname   eth0
+      option ifname   eth0.1
       option type     bridge
       option proto    static
...

WAN is not working (applying patch from scygan didn't help), wifi worked without any extra patches.
MAC addresses on wired are still broken (11:22:33:44..).

Any solution for WAN port and broken MAC addresses ?
Using trunk r25948

Re: Need help for d-link DIR-300 rev. B1

lblasc wrote:

Wired access is possible changing ./package/base-files/files/etc/config/network:

...
config interface lan
-      option ifname   eth0
+      option ifname   eth0.1
       option type     bridge
       option proto    static
...

WAN is not working (applying patch from scygan didn't help), wifi worked without any extra patches.
MAC addresses on wired are still broken (11:22:33:44..).

Any solution for WAN port and broken MAC addresses ?
Using trunk r25948

LAN works for you, but not WAN?

I'm having a similar problem getting the both the LAN and WAN to work on a RT3052.  See this thread:
https://forum.openwrt.org/viewtopic.php?id=28986

As for the MAC address, it appears to be hard-coded in the OpenWrt ramips ethernet driver.  It could be modified to pull the MAC from the chip, eeprom or nvram... but isn't a big issue at this time as it should still work with the fake MAC.

Re: Need help for d-link DIR-300 rev. B1

Hello,

I used the trunk (r26042) with

trunk/target/linux/ramips/base-files/etc/uci-defaults/network
trunk/package/base-files/files/etc/config/network

modifications (the 'eth0.1' and 'RT3.5' changes).

I can connect to the device. Both WAN and LAN are working just fine. I enable the wireless the usual way (/etc/config/wireless), restart the device and everything seems to be operational but none of my devices (3 different laptops) can find the WIFI SSID of the device.

I tried with r25948 again using only the two aforementioned changes. Again, same result, no wifi network found. I can see the hotstapd running fine. I tried to play with the configuration without any success.

Any ideas/recommendations/debug tips?

Thank you very much in advance.

15 (edited by LinkZ 2011-03-12 22:47:59)

Re: Need help for d-link DIR-300 rev. B1

@core-ix

Wifi should be working fine.  Please post your '/etc/config/network', '/etc/config/wireless', 'ifconfig' and 'iwconfig'.

On another note, I just found out that the ramips switch driver in OpenWrt does not currently support swconfig.  The VLANs for LAN and WAN are either hard-coded or derived somehow.  For my board, the VLANs were not configured properly by default (the WAN port was on one of the LAN ports).  I had to hard-code the proper VLANs into the ramips_esw driver.  This is a temporary fix... hopefully we'll have swconfig support soon.  But for now everything is working as expected (with my hack).

Re: Need help for d-link DIR-300 rev. B1

Hello,

I just upgraded trunk to r26158. The only modifications are as follows:

ivo@void:~/OpenWRT/openwrt/trunk> svn stat
M       target/linux/ramips/base-files/etc/uci-defaults/network
M       package/base-files/files/etc/config/network
ivo@void:~/OpenWRT/openwrt/trunk> svn diff target/linux/ramips/base-files/etc/uci-defaults/network
Index: target/linux/ramips/base-files/etc/uci-defaults/network
===================================================================
--- target/linux/ramips/base-files/etc/uci-defaults/network    (revision 26158)
+++ target/linux/ramips/base-files/etc/uci-defaults/network    (working copy)
@@ -1,5 +1,5 @@
 #!/bin/sh
-RT305X=`cat /proc/cpuinfo | grep RT305`
+RT305X=`cat /proc/cpuinfo | grep RT3.5`
 [ -z "${RT305X}" ] || {
     uci batch <<EOF
 set network.lan.ifname=eth0.1
ivo@void:~/OpenWRT/openwrt/trunk> svn diff package/base-files/files/etc/config/network
Index: package/base-files/files/etc/config/network
===================================================================
--- package/base-files/files/etc/config/network    (revision 26158)
+++ package/base-files/files/etc/config/network    (working copy)
@@ -7,7 +7,7 @@
     option netmask    255.0.0.0
 
 config interface lan
-    option ifname    eth0
+    option ifname    eth0.1
     option type     bridge
     option proto    static
     option ipaddr    192.168.1.1
ivo@void:~/OpenWRT/openwrt/trunk>

Here is the content of '/etc/config/wireless':

root@OpenWrt:/# cat /etc/config/wireless 
config wifi-device  radio0
        option type     mac80211
        option channel  11
        option macaddr  10:00:00:00:81:07
        option hwmode   11ng
        option htmode   HT20
        list ht_capab   GF
        list ht_capab   SHORT-GI-20
        list ht_capab   SHORT-GI-40
        list ht_capab   TX-STBC
        # REMOVE THIS LINE TO ENABLE WIFI:
        # option disabled 1

config wifi-iface
        option device   radio0
        option network  lan
        option mode     ap
        option ssid     OpenWrt
        option encryption none

root@OpenWrt:/#

... and the content of '/etc/config/network':

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' 'dhcp'

root@OpenWrt:/#

The output of 'ifconfig':

root@OpenWrt:/# ifconfig 
br-lan    Link encap:Ethernet  HWaddr 00:11:22:33:44:55  
          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:262 errors:0 dropped:0 overruns:0 frame:0
          TX packets:155 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:14405 (14.0 KiB)  TX bytes:19751 (19.2 KiB)

eth0      Link encap:Ethernet  HWaddr 00:11:22:33:44:55  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:262 errors:0 dropped:0 overruns:0 frame:0
          TX packets:285 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:15453 (15.0 KiB)  TX bytes:72225 (70.5 KiB)
          Interrupt:5 

eth0.1    Link encap:Ethernet  HWaddr 00:11:22:33:44:55  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:262 errors:0 dropped:0 overruns:0 frame:0
          TX packets:159 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:15453 (15.0 KiB)  TX bytes:20571 (20.0 KiB)

eth0.2    Link encap:Ethernet  HWaddr 00:11:22:33:44:55  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:126 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:0 (0.0 B)  TX bytes:51282 (50.0 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:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

mon.wlan0 Link encap:UNSPEC  HWaddr 10-00-00-00-81-07-00-00-00-00-00-00-00-00-00-00  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

wlan0     Link encap:Ethernet  HWaddr 10:00:00:00:81:07  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:21 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:4045 (3.9 KiB)

root@OpenWrt:/#

and 'iwconfig':

root@OpenWrt:/# iwconfig 
lo        no wireless extensions.

eth0      no wireless extensions.

eth0.1    no wireless extensions.

eth0.2    no wireless extensions.

br-lan    no wireless extensions.

wlan0     IEEE 802.11bgn  Mode:Master  Frequency:2.462 GHz  Tx-Power=20 dBm   
          RTS thr:off   Fragment thr:off
          Power Management:off
          
mon.wlan0  IEEE 802.11bgn  Mode:Monitor  Tx-Power=20 dBm   
          RTS thr:off   Fragment thr:off
          Power Management:off
          
root@OpenWrt:/#

I include the content of '/proc/cpuinfo' for reference if needed:

root@OpenWrt:/# cat /proc/cpuinfo 
system type             : Ralink RT3350   id:1 rev:2
machine                 : D-Link DIR-300 revB
processor               : 0
cpu model               : MIPS 24Kc V4.12
BogoMIPS                : 212.99
wait instruction        : yes
microsecond timers      : yes
tlb_entries             : 32
extra interrupt vector  : yes
hardware watchpoint     : yes, count: 4, address/irw mask: [0x0000, 0x0ff8, 0x0ff8, 0x0ff8]
ASEs implemented        : mips16
shadow register sets    : 1
core                    : 0
VCED exceptions         : not available
VCEI exceptions         : not available

root@OpenWrt:/#

Thanks in advance.

17

Re: Need help for d-link DIR-300 rev. B1

Do you happen to have the v2image tool laying around? D-link seems to have deleted it.


sorry for hijack

Re: Need help for d-link DIR-300 rev. B1

Yep. Here it is:

http://unilans.net/DIR-300B1/

Re: Need help for d-link DIR-300 rev. B1

Hi all, have any one succeeded with running OpenWRT on Dir-300 B1? What does work, what doesn't?  Is WAN working?
What patches should be applied?

A am going to try OpenWRT on dir-412, it seams to be the same, as dir-300 b1, but it has USB and ralink 3050F, how do you think, will it possible to use additional  USB-WiFi module (rtl8188-based) to be possible to use tow different WiFi modes in the same time?

---
Sorry for my English,
best regards.
Alex from Russia.

20 (edited by daryl 2011-03-20 01:27:22)

Re: Need help for d-link DIR-300 rev. B1

Hello, I followed the instructions on the Wiki and I've got wired network working on my unit. However wireless is reporting that it isn't enabled.

When I installed the file /etc/config/wireless was missing. And also iwconfig did not report any wireless extensions present.

I've tried various ways of enabling (like simply copying the config file shown in this thread, restarting the network service etc.) but unfortunately I'm new to OpenWRT and I haven't had any luck.

Could one of you suggest how to got about this? Thanks!

Re: Need help for d-link DIR-300 rev. B1

tried with the newest trunk ...

Used modifications:

* applied the 'eth0.1' and 'RT3.5' changes

Lan is working, but only after initial boot ... from second boot, there is no communication with router and I have to flash openwrt image again ... (cannot test serial interface though)

Anyway, there is no WIFI ... I mean it is there and it seems to work, but it just isn't ... no WIFI led and no SSID broadcasting ...

When applying the 'eth0.1' and 'RT3.5' changes and the modifications by RedDog (freifunk)

* removed 002-disable_rfkill.patch from package/mac80211/patches/
* removed 015-remove-rt2x00-options.patch from package/mac80211/patches/
* added "CONFIG_RFKILL=y" to target/linux/ramips/rt305x/config-2.6.36
* added rfkill userspace software.

I am back to prior 'eth0.1' and 'RT3.5' changes. No communication at all with router (don't know about serial) and defenitely no WIFI (router doesn't even have the wifi card "radio0")!

I did not have any luck in getting wifi up and running at all ... for none of the above configurations ...

German freifunk forum says that they experience a variety of problems, like no communication, problems with jffs2, kernel panic, etc. after a couple (2. or 3.) of boots: http://forum.freifunk-hannover.de/viewtopic.php?f=23&t=1142

I am really wondering what the dd-wrt guys did to get dd-wrt working on the device?

Has anyone made any progress? I am getting seriously frustrated sad

22 (edited by VIEX 2011-04-05 23:54:33)

Re: Need help for d-link DIR-300 rev. B1

OK - since some weeks I'm reading this threads - and I got the same problems ... getting/having a brick, need for ermergency update and so forth.

With my newest build

   Image Name:   MIPS OpenWrt Linux-2.6.37.6
   Created:      Tue Apr  5 22:18:01 2011

I'm able to connect to the router via telnet/ssh !!!

My next step is to check the whole configuration ... so please be a little bit patient for further information (if necessary, mail me).

HTH (at the moment) - VIEX

P.S: Some details / subversion (unfortunately I'm using KDE with the German language pack)

root@G62:/trunk# svn info
URL: svn://svn.openwrt.org/openwrt/trunk
...
Revision: 26490
...
Letzter Autor: acinonyx
Letzte geänderte Rev: 26485
Letztes Änderungsdatum: 2011-04-05 17:09:43 +0200 (Di, 05. Apr 2011)

--
Member of: funkfeuer.at

Re: Need help for d-link DIR-300 rev. B1

Hi. I want to build a firmware for Dlink DIR-600 rev B. Could someone add a config file for this device beside the existing one for DIR-300 rev B ? I know these models are basically the same hardware but it will be more helpful to have separate config files to properly identify each device.

Re: Need help for d-link DIR-300 rev. B1

boink wrote:

Hi. I want to build a firmware for Dlink DIR-600 rev B. Could someone add a config file for this device beside the existing one for DIR-300 rev B ? I know these models are basically the same hardware but it will be more helpful to have separate config files to properly identify each device.

I'm working on one.  Give me a day or two.

Regards,
Layne

Re: Need help for d-link DIR-300 rev. B1

http://patchwork.midlink.org/patch/865/