Community discussions

MikroTik App
 
jamesDD
just joined
Topic Author
Posts: 6
Joined: Wed Sep 15, 2021 11:27 am

KNOT and issues connecting with blank USER/PASS SIM

Wed Sep 15, 2021 1:47 pm

I've recently received a KNOT for evaluation as a IoT gateway, and figured that I would note issues that were encountered, and what resolved them.
It also seems that there is possibly a bug dealing with empty / space field User/Pass fields?

All interactions are via the WinBox v3.30 tool, over a wifi connection to the device from a Windows 10 laptop. Location is in Denmark.

After attachment of antenna/installation of SIM/power on/setting of country/setting of APN in interface/dial on demand disabled:
- unable to get the modem to register connections to antenna (info for ppp-out1 had ERROR for Current Operator/Access Technology/Signal strength)
- unable to get response to AT+COTS=?
- AT+CPIN was fine (SIM seen)

Setting modem init command to:
at+qcfg="iotopmode"
- Allowed for signal strength to be displayed in the INFO tab
- Allowed for AT+COTS=? to return observed networks

Attempting to enable the interface resulted in a continuously cycling "init - dial - auth - terminate - disconnect" loop.
Investigating the log, took a guess that something was incorrect in the authentication.
The SIM used does not have a Username or Pass for authentication; these had been left blank in the configuration.
Placing a single space " " in the User and Pass fields in Interface(ppp-out1) - PPP tab allowed for successful authentication.

Confirmed that traffic was going out the ppp-interface by successfully pinging 8.8.8.8, and noting the traffic change on the ppp-out1 interface.

Decided to determine if the init command was required: removed it, reset the router.

ppp-out1 interface is cycling in the "init - dial - auth - terminate - disconnect" loop.
Disabled the ppp-out1 interface, and checked the User/Pass setting. still a space in the User field, and a * in the Pass field.
While in the PPP tab, hit apply. Closed the interface window, re-enabled the ppp-out1 interface.
Connected fine.

So there seems that there may possibly be something hinky involved if a user/pass is not required?

I have another SIM from another provider that I'll be trying out as well (which has a defined User/Pass), just to see if there are differences.
 
jamesDD
just joined
Topic Author
Posts: 6
Joined: Wed Sep 15, 2021 11:27 am

Re: KNOT and issues connecting with blank USER/PASS SIM

Wed Sep 15, 2021 5:42 pm

Using another SIM (ESEYE), I'm unable to get this to function; connecting to the modem via the serial terminal has the following occuring (ad infinitum):
+CPIN: READY
+QUSIM: 1
+QIND: SMS DONE

Looking at the log while opening the info window and hitting Start:
Note:
# sep/15/2021 15:11:12 by RouterOS 6.48.4
# software id = G28V-LUK7
#
14:50:35 system,info device changed by dripdrop_admin_user 
14:51:02 async,debug usb2:2: sent AT+GMI 
14:51:02 async,debug usb2:2: rcvd  
14:51:02 async,debug usb2:2: rcvd Quectel 
14:51:02 async,debug usb2:2: sent AT+GMM 
14:51:02 async,debug usb2:2: rcvd  
14:51:02 async,debug usb2:2: rcvd BG77 
14:51:02 async,debug usb2:2: sent AT+GMR 
14:51:02 async,debug usb2:2: rcvd  
14:51:02 async,debug usb2:2: rcvd BG77LAR02A02 
14:51:02 async,debug usb2:2: sent AT+GSN 
14:51:02 async,debug usb2:2: rcvd  
14:51:02 async,debug usb2:2: rcvd 866349041039235 
14:51:02 async,debug usb2:2: sent AT+CPAS 
14:51:02 async,debug usb2:2: rcvd +CPAS: 0 
14:51:02 async,debug usb2:2: sent AT+CFUN? 
14:51:02 async,debug usb2:2: rcvd +CFUN: 1 
14:51:02 async,debug usb2:2: sent AT+CSQ 
14:51:02 async,debug usb2:2: rcvd +CSQ: 99,99 
14:51:02 async,debug usb2:2: sent AT+CSQ? 
14:51:02 async,debug usb2:2: rcvd ERROR: 3 
14:51:02 async,debug usb2:2: sent AT+CIMI 
14:51:02 async,debug usb2:2: rcvd  
14:51:02 async,debug usb2:2: rcvd 204046000228799 
14:51:02 async,debug usb2:2: sent AT+CGREG=2 
14:51:02 async,debug usb2:2: rcvd ERROR 
14:51:02 async,debug usb2:2: sent AT+CGREG? 
14:51:02 async,debug usb2:2: rcvd ERROR 
14:51:02 async,debug usb2:2: sent AT+CGREG=0 
14:51:02 async,debug usb2:2: rcvd ERROR 
14:51:02 async,debug usb2:2: sent AT+COPS? 
14:51:02 async,debug usb2:2: rcvd +COPS: 0 
14:51:02 async,debug usb2:2: sent AT+CPIN? 
14:51:02 async,debug usb2:2: rcvd +CPIN: READY 
14:51:04 async,debug usb2:2: sent AT+GMI 

general queries to the modem for make/model return correct
AT+CPAS is fine (returns 0)
AT+CFUN? is fine (returns 1)
AT+CSQ returns 99,99 -first indication something isn't quite right (signal strength not known, or not detectable)
AT+CSQ? returns ERROR 3 (Operation not allowed?)
AT+CIMI returns fine
AT+CREG=2 returns error
AT+CREG? returns error
AT+CREG=0 returns error
AT+COPS? returns 0
AT+CPIN? is fine (returns READY)
and it looks like it now cycles back modem queries.

When trying to enable the interface (example log file):
15:00:03 async,ppp,info ppp-out1: initializing... 
15:00:03 async,ppp,info ppp-out1: initializing... 
15:00:03 async,ppp,info ppp-out1: resetting link... 
15:00:03 async,ppp,info ppp-out1: resetting link... 
15:00:04 async,debug usb2:2: sent ATH 
15:00:04 async,debug usb2:2: rcvd OK 
15:00:04 async,ppp,info ppp-out1: initializing modem... 
15:00:04 async,ppp,info ppp-out1: initializing modem... 
15:00:05 async,ppp,info ppp-out1: dialing out... 
15:00:05 async,ppp,info ppp-out1: dialing out... 
15:00:05 async,debug usb2:2: sent AT+CGDCONT=1,"IP","ESEYE1" 
15:00:05 async,debug usb2:2: rcvd OK 
15:00:05 async,debug usb2:2: sent ATDT*99***1# 
15:00:05 async,debug usb2:2: rcvd CONNECT 150000000 
15:00:05 async,ppp,debug ppp-out1: LCP lowerup 
15:00:05 async,ppp,debug,packet  ppp-out1: sent LCP ConfReq id=0xd 
15:00:05 async,ppp,debug,packet    <magic 0x7a1eac49> 
15:00:05 async,ppp,debug,packet    <pcomp> 
15:00:05 async,ppp,debug,packet    <accomp> 
15:00:05 async,ppp,debug ppp-out1: LCP open 
15:00:05 async,ppp,debug,packet  ppp-out1: rcvd LCP ConfReq id=0xc7 
15:00:05 async,ppp,debug,packet    <asyncmap 0x0> 
15:00:05 async,ppp,debug,packet    <magic 0xd088289b> 
15:00:05 async,ppp,debug,packet    <pcomp> 
15:00:05 async,ppp,debug,packet    <accomp> 
15:00:05 async,ppp,debug,packet    <auth  chap> 
15:00:05 async,ppp,debug,packet  ppp-out1: sent LCP ConfAck id=0xc7 
15:00:05 async,ppp,debug,packet    <asyncmap 0x0> 
15:00:05 async,ppp,debug,packet    <magic 0xd088289b> 
15:00:05 async,ppp,debug,packet    <pcomp> 
15:00:05 async,ppp,debug,packet    <accomp> 
15:00:05 async,ppp,debug,packet    <auth  chap> 
15:00:05 async,ppp,debug,packet  ppp-out1: rcvd LCP ConfAck id=0xd 
15:00:05 async,ppp,debug,packet    <magic 0x7a1eac49> 
15:00:05 async,ppp,debug,packet    <pcomp> 
15:00:05 async,ppp,debug,packet    <accomp> 
15:00:05 async,ppp,debug ppp-out1: LCP opened 
15:00:05 async,ppp,debug,packet  ppp-out1: rcvd LCP DiscReq id=0xc8 
15:00:05 async,ppp,debug,packet     <magic 0xd088289b> 
15:00:05 async,ppp,debug,packet  ppp-out1: rcvd CHAP Challenge id=0x1 
15:00:05 async,ppp,debug,packet     <challenge len=16> 
15:00:05 async,ppp,debug,packet     <name UMTS_CHAP_SRVR> 
15:00:05 async,ppp,debug,packet  ppp-out1: sent CHAP Response id=0x1 
15:00:05 async,ppp,debug,packet     <response len=16> 
15:00:05 async,ppp,debug,packet  ppp-out1: rcvd CHAP Success id=0x1 
15:00:05 async,ppp,info ppp-out1: authenticated 
15:00:05 async,ppp,info ppp-out1: authenticated 
15:00:05 async,ppp,debug ppp-out1: IPCP lowerup 
15:00:05 async,ppp,debug ppp-out1: IPCP open 
15:00:05 async,ppp,debug,packet  ppp-out1: sent IPCP ConfReq id=0xd 
15:00:05 async,ppp,debug,packet     <addr 0.0.0.0> 
15:00:05 async,ppp,debug,packet     <ms-dns 0.0.0.0> 
15:00:05 async,ppp,debug,packet     <ms-dns 0.0.0.0> 
15:00:05 async,ppp,debug ppp-out1: IPV6CP open 
15:00:05 async,ppp,debug ppp-out1: MPLSCP lowerup 
15:00:05 async,ppp,debug ppp-out1: MPLSCP open 
15:00:05 async,ppp,debug,packet  ppp-out1: sent MPLSCP ConfReq id=0xd 
15:00:05 async,ppp,debug ppp-out1: BCP open 
15:00:05 async,ppp,debug ppp-out1: CCP lowerup 
15:00:05 async,ppp,debug ppp-out1: CCP open 
15:00:05 async,ppp,debug,packet  ppp-out1: rcvd LCP ProtRej id=0xc9 
15:00:05 async,ppp,debug,packet      82 81 01 0d 00 04 
15:00:05 async,ppp,debug,packet  ppp-out1: rcvd LCP TermReq id=0xca 
15:00:05 async,ppp,debug ppp-out1: LCP closed 
15:00:05 async,ppp,debug ppp-out1: CCP lowerdown 
15:00:05 async,ppp,debug ppp-out1: BCP lowerdown 
15:00:05 async,ppp,debug ppp-out1: BCP down event in starting state 
15:00:05 async,ppp,debug ppp-out1: IPCP lowerdown 
15:00:05 async,ppp,debug ppp-out1: IPV6CP lowerdown 
15:00:05 async,ppp,debug ppp-out1: IPV6CP down event in starting state 
15:00:05 async,ppp,debug ppp-out1: MPLSCP lowerdown 
15:00:05 async,ppp,debug,packet  ppp-out1: sent LCP TermAck id=0xca 
15:00:05 async,ppp,debug ppp-out1: LCP lowerdown 
15:00:05 async,ppp,debug ppp-out1: CCP close 
15:00:05 async,ppp,debug ppp-out1: BCP close 
15:00:05 async,ppp,debug ppp-out1: IPCP close 
15:00:05 async,ppp,debug ppp-out1: IPV6CP close 
15:00:05 async,ppp,debug ppp-out1: MPLSCP close 
15:00:05 async,ppp,info ppp-out1: terminating... 
15:00:05 async,ppp,info ppp-out1: terminating... 
15:00:05 async,ppp,debug ppp-out1: LCP lowerdown 
15:00:05 async,ppp,debug ppp-out1: LCP down event in starting state 
15:00:05 async,ppp,info ppp-out1: disconnected 
15:00:05 async,ppp,info ppp-out1: disconnected 
15:00:05 async,ppp,info ppp-out1: initializing... 


Hardware is the same; the SIM card was changed, and the APN/user/pass updated. Use of at+qcfg="iotopmode" has no impact.


Ugh. Next step is probably to swap back to the previous SIM card, and compare the logs.

If anyone has anything to chip in, feel free :D
 
jamesDD
just joined
Topic Author
Posts: 6
Joined: Wed Sep 15, 2021 11:27 am

Re: KNOT and issues connecting with blank USER/PASS SIM

Fri Sep 24, 2021 9:07 am

Long and short: after quite a bit of investigation, it seems that the SIM provider(s) did not have support for NBIoT; so a connection would occur, and an LCP TermReq would be received to close the session. I'm not entirely certain why NBIoT was being used preferentially, rather than the eMTC (even with iotopmode as 2), even though the priority is eMTC over NBIoT by default.

Setting the modem to LTE-M only (eMTC) by at+qcfg="iotopmode",0,1 was able to resolve the issue, where I can now reliably connect to a network.

Who is online

Users browsing this forum: No registered users and 20 guests