<p dir="ltr">I'll take a look at what can be done with the `wifi` script. I think it's pretty long overdue with IoT modules being huge now. </p>
<div class="gmail_quote">On 28 Apr 2016 20:23, "Piotr Dymacz" <<a href="mailto:pepe2k@gmail.com">pepe2k@gmail.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello,<br>
<br>
2016-04-28 13:12 GMT+02:00 Andrew Yong <<a href="mailto:me@ndoo.sg">me@ndoo.sg</a>>:<br>
[...]<br>
<br>
> Many SOM modules and mini routers (and the Zsun card reader<br>
> <a href="https://wiki.hackerspace.pl/projects:zsun-wifi-card-reader" rel="noreferrer" target="_blank">https://wiki.hackerspace.pl/projects:zsun-wifi-card-reader</a>) don't have<br>
> Ethernet ports and manufacturers ship custom OpenWrt with preconfigured WiFi<br>
> for this, and probably will never be supported by OpenWrt releases because<br>
> of how wifi-detect disables WiFi by default.<br>
<br>
Fully agree.<br>
There are other interesting devices, like D-Link DCH-M225 (MT7620A + audio) [1].<br>
<br>
I know only one way how to use such devices with OpenWrt: define<br>
hardware button as rfkill and use it after flash.<br>
<br>
Cheers,<br>
Piotr<br>
<br>
[1] <a href="https://wikidevi.com/wiki/D-Link_DCH-M225_rev_A1" rel="noreferrer" target="_blank">https://wikidevi.com/wiki/D-Link_DCH-M225_rev_A1</a><br>
<br>
><br>
> On 28 Apr 2016 18:48, "@<a href="http://SRCHACK.ORG" rel="noreferrer" target="_blank">SRCHACK.ORG</a>" <<a href="mailto:tochiro.srchack@gmail.com">tochiro.srchack@gmail.com</a>> wrote:<br>
>><br>
>> Hi, Dear Piotr.<br>
>><br>
>> Status quo, is the only way there is access in the UART.<br>
>> Looking for a good way. I'm thinking.<br>
>><br>
>><br>
>> On 2016/04/28 19:24, Piotr Dymacz wrote:<br>
>>><br>
>>> Hello YuheiOKAWA,<br>
>>><br>
>>> Just small question.<br>
>>> How the user can access the device if it doesn't have Ethernet and the<br>
>>> WiFi is disabled by default in OpenWrt?<br>
>>><br>
>>> Cheers,<br>
>>> Piotr<br>
>>><br>
>>><br>
>>> 2016-04-28 11:49 GMT+02:00 YuheiOKAWA <<a href="mailto:tochiro.srchack@gmail.com">tochiro.srchack@gmail.com</a>>:<br>
>>>><br>
>>>> add support for Planex MZK-EX750NP.<br>
>>>> MZK-EX750NP is MT7620A and MT7610E based 11ac wifi repeater.<br>
>>>> Built-in power supply.<br>
>>>> 64MiB RAM, 8MiB SPI Flash, non Wired Ethernet.<br>
>>>><br>
>>>> Signed-off-by: YuheiOKAWA <<a href="mailto:tochiro.srchack@gmail.com">tochiro.srchack@gmail.com</a>><br>
>>>> ---<br>
>>>>  target/linux/ramips/base-files/etc/board.d/01_leds |   4 +<br>
>>>>  .../linux/ramips/base-files/etc/board.d/02_network |   1 +<br>
>>>>  target/linux/ramips/base-files/etc/diag.sh         |   3 +-<br>
>>>>  target/linux/ramips/base-files/lib/ramips.sh       |   3 +<br>
>>>>  .../ramips/base-files/lib/upgrade/platform.sh      |   1 +<br>
>>>>  target/linux/ramips/dts/MZK-EX750NP.dts            | 150<br>
>>>> +++++++++++++++++++++<br>
>>>>  target/linux/ramips/image/<a href="http://mt7620.mk" rel="noreferrer" target="_blank">mt7620.mk</a>                |   2 +<br>
>>>>  target/linux/ramips/mt7620/profiles/<a href="http://planex.mk" rel="noreferrer" target="_blank">planex.mk</a>      |  11 ++<br>
>>>>  8 files changed, 174 insertions(+), 1 deletion(-)<br>
>>>>  create mode 100644 target/linux/ramips/dts/MZK-EX750NP.dts<br>
>>>><br>
>>>> diff --git a/target/linux/ramips/base-files/etc/board.d/01_leds<br>
>>>> b/target/linux/ramips/base-files/etc/board.d/01_leds<br>
>>>> index aeaab33..47e1e6a 100755<br>
>>>> --- a/target/linux/ramips/base-files/etc/board.d/01_leds<br>
>>>> +++ b/target/linux/ramips/base-files/etc/board.d/01_leds<br>
>>>> @@ -206,6 +206,10 @@ mr-102n)<br>
>>>>         set_wifi_led "$board:green:wlan"<br>
>>>>         set_usb_led "$board:green:usb"<br>
>>>>         ;;<br>
>>>> +mzk-ex750np)<br>
>>>> +       ucidef_set_led_default "power" "power" "$board:red:power" "1"<br>
>>>> +       set_wifi_led "$board:red:wifi"<br>
>>>> +       ;;<br>
>>>>  na930)<br>
>>>>         set_usb_led "$board:blue:status"<br>
>>>>         ;;<br>
>>>> diff --git a/target/linux/ramips/base-files/etc/board.d/02_network<br>
>>>> b/target/linux/ramips/base-files/etc/board.d/02_network<br>
>>>> index c6c740f..ee690f6 100755<br>
>>>> --- a/target/linux/ramips/base-files/etc/board.d/02_network<br>
>>>> +++ b/target/linux/ramips/base-files/etc/board.d/02_network<br>
>>>> @@ -165,6 +165,7 @@ ramips_setup_interfaces()<br>
>>>>         d105|\<br>
>>>>         hpm|\<br>
>>>>         mzk-ex300np|\<br>
>>>> +       mzk-ex750np|\<br>
>>>>         na930|\<br>
>>>>         wli-tx4-ag300n|\<br>
>>>>         wrh-300cr)<br>
>>>> diff --git a/target/linux/ramips/base-files/etc/diag.sh<br>
>>>> b/target/linux/ramips/base-files/etc/diag.sh<br>
>>>> index 20ff8ff..c638d16 100644<br>
>>>> --- a/target/linux/ramips/base-files/etc/diag.sh<br>
>>>> +++ b/target/linux/ramips/base-files/etc/diag.sh<br>
>>>> @@ -41,7 +41,8 @@ get_status_led() {<br>
>>>>         hlk-rm04|\<br>
>>>>         jhr-n825r|\<br>
>>>>         mpr-a1|\<br>
>>>> -       mpr-a2)<br>
>>>> +       mpr-a2|\<br>
>>>> +       mzk-ex750np)<br>
>>>>                 status_led="$board:red:power"<br>
>>>>                 ;;<br>
>>>>         ai-br100|\<br>
>>>> diff --git a/target/linux/ramips/base-files/lib/ramips.sh<br>
>>>> b/target/linux/ramips/base-files/lib/ramips.sh<br>
>>>> index 2c669c5..0ac0f68 100755<br>
>>>> --- a/target/linux/ramips/base-files/lib/ramips.sh<br>
>>>> +++ b/target/linux/ramips/base-files/lib/ramips.sh<br>
>>>> @@ -298,6 +298,9 @@ ramips_board_detect() {<br>
>>>>         *"MZK-EX300NP")<br>
>>>>                 name="mzk-ex300np"<br>
>>>>                 ;;<br>
>>>> +       *"MZK-EX750NP")<br>
>>>> +               name="mzk-ex750np"<br>
>>>> +               ;;<br>
>>>>         *"MZK-W300NH2"*)<br>
>>>>                 name="mzk-w300nh2"<br>
>>>>                 ;;<br>
>>>> diff --git a/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>
>>>> b/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>
>>>> index 2b24030..86ea4a3 100755<br>
>>>> --- a/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>
>>>> +++ b/target/linux/ramips/base-files/lib/upgrade/platform.sh<br>
>>>> @@ -90,6 +90,7 @@ platform_check_image() {<br>
>>>>         mzk-750dhp|\<br>
>>>>         mzk-dp150n|\<br>
>>>>         mzk-ex300np|\<br>
>>>> +       mzk-ex750np|\<br>
>>>>         mzk-w300nh2|\<br>
>>>>         mzk-wdpr|\<br>
>>>>         nbg-419n|\<br>
>>>> diff --git a/target/linux/ramips/dts/MZK-EX750NP.dts<br>
>>>> b/target/linux/ramips/dts/MZK-EX750NP.dts<br>
>>>> new file mode 100644<br>
>>>> index 0000000..9b5b418<br>
>>>> --- /dev/null<br>
>>>> +++ b/target/linux/ramips/dts/MZK-EX750NP.dts<br>
>>>> @@ -0,0 +1,150 @@<br>
>>>> +/dts-v1/;<br>
>>>> +<br>
>>>> +/include/ "mt7620a.dtsi"<br>
>>>> +<br>
>>>> +/ {<br>
>>>> +       compatible = "ralink,mt7620a-soc";<br>
>>>> +       model = "Planex MZK-EX750NP";<br>
>>>> +<br>
>>>> +       palmbus@10000000 {<br>
>>>> +               gpio2: gpio@660 {<br>
>>>> +                       status = "okay";<br>
>>>> +               };<br>
>>>> +<br>
>>>> +               gpio3: gpio@688 {<br>
>>>> +                       status = "okay";<br>
>>>> +               };<br>
>>>> +<br>
>>>> +               spi@b00 {<br>
>>>> +                       status = "okay";<br>
>>>> +<br>
>>>> +                       m25p80@0 {<br>
>>>> +                               #address-cells = <1>;<br>
>>>> +                               #size-cells = <1>;<br>
>>>> +                               compatible = "jedec,spi-nor";<br>
>>>> +                               reg = <0 0>;<br>
>>>> +                               linux,modalias = "m25p80", "w25q64";<br>
>>>> +                               spi-max-frequency = <10000000>;<br>
>>>> +<br>
>>>> +                               partition@0 {<br>
>>>> +                                       label = "u-boot";<br>
>>>> +                                       reg = <0x0 0x30000>;<br>
>>>> +                                       read-only;<br>
>>>> +                               };<br>
>>>> +<br>
>>>> +                               partition@30000 {<br>
>>>> +                                       label = "u-boot-env";<br>
>>>> +                                       reg = <0x30000 0x10000>;<br>
>>>> +                                       read-only;<br>
>>>> +                               };<br>
>>>> +<br>
>>>> +                               factory: partition@40000 {<br>
>>>> +                                       label = "factory";<br>
>>>> +                                       reg = <0x40000 0x10000>;<br>
>>>> +                                       read-only;<br>
>>>> +                               };<br>
>>>> +<br>
>>>> +                               partition@50000 {<br>
>>>> +                                       label = "firmware";<br>
>>>> +                                       reg = <0x50000 0x730000>;<br>
>>>> +                               };<br>
>>>> +<br>
>>>> +                               partition@780000 {<br>
>>>> +                                       label = "Udata";<br>
>>>> +                                       reg = <0x780000 0x80000>;<br>
>>>> +                               };<br>
>>>> +                       };<br>
>>>> +               };<br>
>>>> +       };<br>
>>>> +<br>
>>>> +       pinctrl {<br>
>>>> +               state_default: pinctrl0 {<br>
>>>> +                       gpio {<br>
>>>> +                               ralink,group = "uartf", "nd_sd",<br>
>>>> "rgmii2", "wled";<br>
>>>> +                               ralink,function = "gpio";<br>
>>>> +                       };<br>
>>>> +               };<br>
>>>> +       };<br>
>>>> +<br>
>>>> +       ethernet@10100000 {<br>
>>>> +               pinctrl-names = "default";<br>
>>>> +               pinctrl-0 = <&ephy_pins>;<br>
>>>> +               mtd-mac-address = <&factory 0x4>;<br>
>>>> +               mediatek,portmap = "llllw";<br>
>>>> +       };<br>
>>>> +<br>
>>>> +       wmac@10180000 {<br>
>>>> +               ralink,mtd-eeprom = <&factory 0>;<br>
>>>> +       };<br>
>>>> +<br>
>>>> +       pcie@10140000 {<br>
>>>> +               status = "okay";<br>
>>>> +<br>
>>>> +               pcie-bridge {<br>
>>>> +                       mt76@0,0 {<br>
>>>> +                               reg = <0x0000 0 0 0 0>;<br>
>>>> +                               device_type = "pci";<br>
>>>> +                               mediatek,mtd-eeprom = <&factory 0x8000>;<br>
>>>> +                               mediatek,2ghz = <0>;<br>
>>>> +                       };<br>
>>>> +               };<br>
>>>> +       };<br>
>>>> +<br>
>>>> +       gpio-leds {<br>
>>>> +               compatible = "gpio-leds";<br>
>>>> +<br>
>>>> +               power {<br>
>>>> +                       label = "mzk-ex750np:red:power";<br>
>>>> +                       gpios = <&gpio0 14 1>;<br>
>>>> +               };<br>
>>>> +<br>
>>>> +               wifi {<br>
>>>> +                       label = "mzk-ex750np:red:wifi";<br>
>>>> +                       gpios = <&gpio3 0 1>;<br>
>>>> +               };<br>
>>>> +<br>
>>>> +               wps {<br>
>>>> +                       label = "mzk-ex750np:green:wps";<br>
>>>> +                       gpios = <&gpio0 10 1>;<br>
>>>> +               };<br>
>>>> +<br>
>>>> +               rep {<br>
>>>> +                       label = "mzk-ex750np:blue:rep";<br>
>>>> +                       gpios = <&gpio2 16 1>;<br>
>>>> +               };<br>
>>>> +<br>
>>>> +               wifi1 {<br>
>>>> +                       label = "mzk-ex750np:blue:wifi1";<br>
>>>> +                       gpios = <&gpio2 19 1>;<br>
>>>> +               };<br>
>>>> +<br>
>>>> +               wifi2 {<br>
>>>> +                       label = "mzk-ex750np:blue:wifi2";<br>
>>>> +                       gpios = <&gpio2 18 1>;<br>
>>>> +               };<br>
>>>> +<br>
>>>> +               wifi3 {<br>
>>>> +                       label = "mzk-ex750np:blue:wifi3";<br>
>>>> +                       gpios = <&gpio2 17 1>;<br>
>>>> +               };<br>
>>>> +       };<br>
>>>> +<br>
>>>> +       gpio-keys-polled {<br>
>>>> +               compatible = "gpio-keys-polled";<br>
>>>> +               #address-cells = <1>;<br>
>>>> +               #size-cells = <0>;<br>
>>>> +               poll-interval = <20>;<br>
>>>> +<br>
>>>> +               reset {<br>
>>>> +                       label = "reset";<br>
>>>> +                       gpios = <&gpio0 9 1>;<br>
>>>> +                       linux,code = <0x198>;<br>
>>>> +               };<br>
>>>> +<br>
>>>> +               wps {<br>
>>>> +                       label = "wps";<br>
>>>> +                       gpios = <&gpio0 13 0>;<br>
>>>> +                       linux,code = <0x211>;<br>
>>>> +               };<br>
>>>> +       };<br>
>>>> +};<br>
>>>> diff --git a/target/linux/ramips/image/<a href="http://mt7620.mk" rel="noreferrer" target="_blank">mt7620.mk</a><br>
>>>> b/target/linux/ramips/image/<a href="http://mt7620.mk" rel="noreferrer" target="_blank">mt7620.mk</a><br>
>>>> index 35cb46a..09c0ec2 100644<br>
>>>> --- a/target/linux/ramips/image/<a href="http://mt7620.mk" rel="noreferrer" target="_blank">mt7620.mk</a><br>
>>>> +++ b/target/linux/ramips/image/<a href="http://mt7620.mk" rel="noreferrer" target="_blank">mt7620.mk</a><br>
>>>> @@ -102,6 +102,7 @@ Image/Build/Profile/NA930=$(call<br>
>>>> BuildFirmware/CustomFlash/$(1),$(1),na930,NA930<br>
>>>>  Image/Build/Profile/DB-WRT01=$(call<br>
>>>> BuildFirmware/Default8M/$(1),$(1),db-wrt01,DB-WRT01)<br>
>>>>  Image/Build/Profile/MZK-750DHP=$(call<br>
>>>> BuildFirmware/Default8M/$(1),$(1),mzk-750dhp,MZK-750DHP)<br>
>>>>  Image/Build/Profile/MZK-EX300NP=$(call<br>
>>>> BuildFirmware/Default8M/$(1),$(1),mzk-ex300np,MZK-EX300NP)<br>
>>>> +Image/Build/Profile/MZK-EX750NP=$(call<br>
>>>> BuildFirmware/Default8M/$(1),$(1),mzk-ex750np,MZK-EX750NP)<br>
>>>>  Image/Build/Profile/HC5661=$(call<br>
>>>> BuildFirmware/Default16M/$(1),$(1),hc5661,HC5661)<br>
>>>>  Image/Build/Profile/HC5761=$(call<br>
>>>> BuildFirmware/Default16M/$(1),$(1),hc5761,HC5761)<br>
>>>>  Image/Build/Profile/HC5861=$(call<br>
>>>> BuildFirmware/Default16M/$(1),$(1),hc5861,HC5861)<br>
>>>> @@ -149,6 +150,7 @@ define Image/Build/Profile/Default<br>
>>>>         $(call Image/Build/Profile/DB-WRT01,$(1))<br>
>>>>         $(call Image/Build/Profile/MZK-750DHP,$(1))<br>
>>>>         $(call Image/Build/Profile/MZK-EX300NP,$(1))<br>
>>>> +       $(call Image/Build/Profile/MZK-EX750NP,$(1))<br>
>>>>         $(call Image/Build/Profile/NA930,$(1))<br>
>>>>         $(call Image/Build/Profile/HC5661,$(1))<br>
>>>>         $(call Image/Build/Profile/HC5761,$(1))<br>
>>>> diff --git a/target/linux/ramips/mt7620/profiles/<a href="http://planex.mk" rel="noreferrer" target="_blank">planex.mk</a><br>
>>>> b/target/linux/ramips/mt7620/profiles/<a href="http://planex.mk" rel="noreferrer" target="_blank">planex.mk</a><br>
>>>> index 157cf8d..f461aeb 100644<br>
>>>> --- a/target/linux/ramips/mt7620/profiles/<a href="http://planex.mk" rel="noreferrer" target="_blank">planex.mk</a><br>
>>>> +++ b/target/linux/ramips/mt7620/profiles/<a href="http://planex.mk" rel="noreferrer" target="_blank">planex.mk</a><br>
>>>> @@ -39,3 +39,14 @@ define Profile/MZK-EX300NP/Description<br>
>>>>         Package set optimized for the Planex MZK-EX300NP.<br>
>>>>  endef<br>
>>>>  $(eval $(call Profile,MZK-EX300NP))<br>
>>>> +<br>
>>>> +<br>
>>>> +define Profile/MZK-EX750NP<br>
>>>> +       NAME:=Planex MZK-EX750NP<br>
>>>> +       PACKAGES:= kmod-mt76 kmod-mt7610e<br>
>>>> +endef<br>
>>>> +<br>
>>>> +define Profile/MZK-EX750NP/Description<br>
>>>> +       Package set optimized for the Planex MZK-EX750NP.<br>
>>>> +endef<br>
>>>> +$(eval $(call Profile,MZK-EX750NP))<br>
>>>> --<br>
>>>> 1.9.1<br>
>>>> _______________________________________________<br>
>>>> openwrt-devel mailing list<br>
>>>> <a href="mailto:openwrt-devel@lists.openwrt.org">openwrt-devel@lists.openwrt.org</a><br>
>>>> <a href="https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel" rel="noreferrer" target="_blank">https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel</a><br>
>>><br>
>>><br>
>><br>
>><br>
>> --<br>
>> ------------------------------------------------------<br>
>> @<a href="http://SRCHACK.ORG" rel="noreferrer" target="_blank">SRCHACK.ORG</a><br>
>> <a href="mailto:tochiro.srchack@gmail.com">tochiro.srchack@gmail.com</a><br>
>> <a href="http://www.srchack.org/" rel="noreferrer" target="_blank">http://www.srchack.org/</a><br>
>> ------------------------------------------------------<br>
>> _______________________________________________<br>
>> openwrt-devel mailing list<br>
>> <a href="mailto:openwrt-devel@lists.openwrt.org">openwrt-devel@lists.openwrt.org</a><br>
>> <a href="https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel" rel="noreferrer" target="_blank">https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel</a><br>
</blockquote></div>