1 (edytowany przez rybirek 2024-02-14 16:41:11)

Temat: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

Potrzebuję awaryjnego łącza i chciałbym wykorzystać sprzęt z tematu.
OpenWrt 23.05.2 r23630-842932a63d
USB przełączone na mPCI

echo 0 > /sys/class/gpio/power-usb/value
echo 1 > /sys/class/gpio/power-pcie/value 
config interface 'wan'
        option proto 'ncm'
        option device '/dev/ttyACM0'
        option apn 'internet'
        option ipv6 '0'
Tue Feb 13 20:00:35 2024 daemon.notice netifd: wan (13340): Command failed: ubus call network.interface notify_proto { "action": 0, "link-up": false, "keep": false, "interface": "wan" } (Permission denied)
Tue Feb 13 20:00:35 2024 daemon.notice netifd: Interface 'wan' is now down
Tue Feb 13 20:00:35 2024 daemon.notice netifd: Interface 'wan' is setting up now
Tue Feb 13 20:00:35 2024 daemon.notice netifd: wan (13355): ls: /sys/devices/platform/ahb/1b000000.usb/usb1/1-1/1-1:1.2/../*/net: No such file or directory
Tue Feb 13 20:00:36 2024 daemon.warn odhcpd[1452]: No default route present, overriding ra_lifetime!
Tue Feb 13 20:00:38 2024 daemon.notice netifd: wan (13355): sending -> AT+CFUN=1
Tue Feb 13 20:00:38 2024 daemon.notice netifd: wan (13355): Configuring modem
Tue Feb 13 20:00:38 2024 daemon.notice netifd: wan (13355): sending -> AT+ZGDCONT=1,"IP","internet","",0,0
Tue Feb 13 20:00:40 2024 daemon.notice netifd: wan (13355): sending -> AT+ZGPCOAUTH=1,"","",0
Tue Feb 13 20:00:40 2024 daemon.notice netifd: wan (13355): Starting network wan
Tue Feb 13 20:00:40 2024 daemon.notice netifd: wan (13355): Connecting modem
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): sending -> AT+ZGACT=1,1
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): Setting up 3g.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): dhcp.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): dhcpv6.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): ncm.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): ppp.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): wwan.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): Command failed: ubus call network.interface notify_proto { "action": 0, "ifname": "3g.sh\ndhcp.sh\ndhcpv6.sh\nncm.sh\nppp.sh\nwwan.sh", "link-up": true, "data": { "manufacturer":
 "\"marvell\"" }, "keep": false, "interface": "wan" } (Invalid argument)
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): Usage: ubus [<options>] <command> [arguments...]
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): Options:
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  -s <socket>:               Set the unix domain socket to connect to
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  -t <timeout>:              Set the timeout (in seconds) for a command to complete
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  -S:                        Use simplified output (for scripts)
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  -v:                        More verbose output
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  -m <type>:         (for monitor): include a specific message type
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):                     (can be used more than once)
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  -M <r|t>           (for monitor): only capture received or transmitted traffic
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): Commands:
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  - list [<path>]                    List objects
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  - call <path> <method> [<message>] Call an object method
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  - subscribe <path> [<path>...]     Subscribe to object(s) notifications
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  - listen [<path>...]                       Listen for events
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  - send <type> [<message>]          Send an event
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  - wait_for <object> [<object>...]  Wait for multiple objects to appear on ubus
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):  - monitor                          Monitor ubus traffic
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355):
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13471): Stopping network wan
root@OpenWrt:/# ubus call network.interface.wan status
{
        "up": false,
        "pending": true,
        "available": true,
        "autostart": true,
        "dynamic": false,
        "proto": "ncm",
        "data": {

        }
}

Jakiś błąd w skrypcie ?

Edit:

/usr/share/3ginfo-lite/3ginfo.sh
uci: Entry not found
{
"connt":"-",
"conntx":"-",
"connrx":"-",
"modem":"Marvell LINUX",
"mtemp":"",
"firmware":"BD_PKTPLMF286R1MODULEV1.0.0B03",
"cport":"/dev/ttyACM0",
"protocol":"",
"csq":"",
"signal":"",
"operator_name":"",
"operator_mcc":"",
"operator_mnc":"",
"location":"-",
"mode":"-",
"registration":"",
"simslot":"",
"imei":"863210040xxxx",
"imsi":"2600215234xxxx",
"iccid":"8948022222104xxxxx",
"lac_dec":"",
"lac_hex":"",
"tac_dec":"",
"tac_hex":"-",
"tac_h":"",
"tac_d":"",
"cid_dec":"",
"cid_hex":"",
"pci":"",
"earfcn":"",
"pband":"",
"s1band":"",
"s1pci":"",
"s1earfcn":"",
"s2band":"",
"s2pci":"",
"s2earfcn":"",
"s3band":"",
"s3pci":"",
"s3earfcn":"",
"s4band":"",
"s4pci":"",
"s4earfcn":"",
"rsrp":"",
"rsrq":"",
"rssi":"",
"sinr":""
}

2

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

Tue Feb 13 20:00:38 2024 daemon.notice netifd: wan (13355): Configuring modem
Tue Feb 13 20:00:38 2024 daemon.notice netifd: wan (13355): sending -> AT+ZGDCONT=1,"IP","internet","",0,0
Tue Feb 13 20:00:40 2024 daemon.notice netifd: wan (13355): sending -> AT+ZGPCOAUTH=1,"","",0
Tue Feb 13 20:00:40 2024 daemon.notice netifd: wan (13355): Starting network wan
Tue Feb 13 20:00:40 2024 daemon.notice netifd: wan (13355): Connecting modem
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): sending -> AT+ZGACT=1,1
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): Setting up 3g.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): dhcp.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): dhcpv6.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): ncm.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): ppp.sh
Tue Feb 13 20:00:41 2024 daemon.notice netifd: wan (13355): wwan.sh

Tu są skrypty wymienione, więc gdzies chyba masz gwiazdkę wpisaną i pojechało po plikach w katalogu proto zamiast znaleźć interfejs. Sprawdź co masz w pliku /etc/gcom/ncm.json czy coś podobnego (w każdym razie .json)

Masz niepotrzebny router, uszkodzony czy nie - chętnie przygarnę go.

3 (edytowany przez rybirek 2024-02-14 17:19:34)

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

Nic nie zmianiałem,  ani nie znalazłem żadnej *
W definicji ncm.json był dodawany ten marvell

        "\"marvell\"": {                                                                       
                "initialize": [                                                                
                        "AT+CFUN=1"                                                            
                ],                                                                             
                "configure": [                                                                 
                        "AT+ZGDCONT=${profile},\\\"${pdptype}\\\",\\\"${apn}\\\",\\\"\\\",0,0",
                        "AT+ZGPCOAUTH=${profile},\\\"${username}\\\",\\\"${password}\\\",0"                            
                ],                                                                             
                "connect": "AT+ZGACT=1,${profile}",                                            
                "disconnect": "AT+ZGACT=0,${profile}"                                          
        },   

root@OpenWrt:# gcom -d /dev/ttyACM0 info
##### Wireless WAN Modem Configuration #####
Product text:
====

OK
+ZCONSTAT: 0,1
====
Manufacturer:           
IMEI and Serial Number: 
Manufacturer's Revision: comgt 20:19:44 -> -- Error Report --
comgt 20:19:44 -> ---->                      ^
comgt 20:19:44 -> Error @982, line 56, String is shorter than second argument. (7)
root@OpenWrt:# gcom -d /dev/ttyACM0 -s /etc/gcom/getcardinfo.gcom

+CGMI: "Marvell"

OK

4

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

Wykasowałem sekcję wan i stworzyłem od nowa, zrestartowałem i teraz jest tak.

Tue Feb 13 20:16:38 2024 daemon.notice netifd: Interface 'wan' is setting up now
Tue Feb 13 20:16:38 2024 daemon.notice netifd: wan (2576): ls: /sys/devices/platform/ahb/1b000000.usb/usb1/1-1/1-1:1.2/../*/net: No such file or directory
Tue Feb 13 20:16:40 2024 daemon.notice netifd: wan (2576): WARNING: Variable 'marvell' does not exist or is not an array/object
Tue Feb 13 20:16:40 2024 daemon.notice netifd: wan (2576): Unsupported modem
Tue Feb 13 20:16:40 2024 daemon.notice netifd: wan (2618): Stopping network wan
Tue Feb 13 20:16:43 2024 daemon.notice netifd: wan (2618): sending -> AT+ZGACT=0,1
Tue Feb 13 20:16:44 2024 authpriv.info dropbear[2629]: Child connection from 192.168.1.103:37462
Tue Feb 13 20:16:45 2024 daemon.notice netifd: Interface 'wan' is now down

5

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

smile

Masz niepotrzebny router, uszkodzony czy nie - chętnie przygarnę go.

6

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

Problem rozwiązany, zainstalowałem ostatnią wersję od Ciebie i magicznie wstało.
Ciekawe czego brakuje w oficjalnym 23.05.2 (pakiety ncm / acm doinstalowałem).

7

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

Ja nie mam żadnych specjalnych łatek do tego w tym obszarze. Możesz znów zainstalować 23.05.2 i zobaczyć czy wstanie ponownie,

Masz niepotrzebny router, uszkodzony czy nie - chętnie przygarnę go.

8 (edytowany przez rybirek 2024-02-14 18:39:40)

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

Brak kmod-usb-net-rndis ?

Sprawdzę w wolnej chwili.

Wed Feb 14 18:16:08 2024 kern.info kernel: [   53.563693] rndis_host 1-1:1.0 usb0: register 'rndis_host' at usb-1b000000.usb-1, ZTE RNDIS device, 06:e7:a7:2c:5e:5f
Wed Feb 14 18:16:08 2024 kern.info kernel: [   53.624039] cdc_acm 1-1:1.2: ttyACM0: USB ACM device
Wed Feb 14 18:16:11 2024 daemon.notice netifd: Interface 'wan' is setting up now
Wed Feb 14 18:16:14 2024 daemon.notice netifd: wan (4370): sending -> AT+CFUN=1
Wed Feb 14 18:16:15 2024 daemon.notice netifd: wan (4370): Configuring modem
Wed Feb 14 18:16:15 2024 daemon.notice netifd: wan (4370): sending -> AT+ZGDCONT=1,"IP","internet","",0,0

Wcześniej było

Tue Feb 13 20:00:35 2024 daemon.notice netifd: wan (13355): ls: /sys/devices/platform/ahb/1b000000.usb/usb1/1-1/1-1:1.2/../*/net: No such file or directory

9

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

no to też potrzebujesz.

Masz niepotrzebny router, uszkodzony czy nie - chętnie przygarnę go.

10

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

rybirek napisał/a:

Brak kmod-usb-net-rndis ?

Sprawdzę w wolnej chwili.

Raz dwa możesz sobie sprawdzić, czy to masz, czy nie
opkg list-installed | grep kmod-usb-net-rndis

11

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

Zbudowane imagebuilder'em wstało od razu.

make image PROFILE="mikrotik_routerboard-912uag-2hpnd" PACKAGES="comgt-ncm kmod-usb-acm kmod-usb-net-rndis" FILES="files"

Dziękuję za pomoc.

12

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

Nie lubię tego modemu. To już odkryłem jak wsparcie dla mf286r było robione, jest bardzo wrażliwy i ciężki w codziennym życiu.

Masz niepotrzebny router, uszkodzony czy nie - chętnie przygarnę go.

13

Odp: MikroTik RouterBOARD 912UAG-2HPnD + modem z ZTE MF286R

Złom.Mam jedna sztuke i moge komus oddac