Hi,
Hope someone can help me.
I have an FX30S that I’m trying to develop apps for and having trouble with the “cm data connect” command not connecting. I had loaded wrong firmware (WP8545) by mistake and when I tried the “cm data connect”, it worked fine.
Now that I have the correct firmware loaded again, I can’t get it to connect.
Here are some of the logs and queries…
root@fx30s:~# cm data
Index: 1
APN: wap.voicestream.com
PDP Type: IPV4
Connected: no
root@fx30s:~# cm radio
Power: ON
Current Network Operator: T - Mobile
RAT: GSM network (LE_MRC_RAT_GSM)
Status: Registered, home network (LE_MRC_REG_HOME)
Signal: Strong signal strength (4)
root@fx30s:~# cm info
Device: FX30S
IMEI: 353984080192477
FSN: LL738500900310
Firmware: SWI9X15Y_07.12.09.00 r34123 CARMD-EV-FRMWR1 2017/04/26 23:34:19
Bootloader: SWI9X15Y_07.12.09.00 r34123 CARMD-EV-FRMWR1 2017/04/26 23:34:19
priIdPn: 9906770
priIdRev: 01.02
skuId: 1103232
root@fx30s:~# fwupdate query
Connecting to service …
Firmware Version: SWI9X15Y_07.12.09.00 r34123 CARMD-EV-FRMWR1 2017/04/26 23:34:19
Bootloader Version: SWI9X15Y_07.12.09.00 r34123 CARMD-EV-FRMWR1 2017/04/26 23:34:19
Linux Version: 3.14.29ltsi-a00e464379_499694411b #2 PREEMPT Tue Jun 12 16:49:03 PDT 2018
FX30 Version: R14.0.4.002
root@fx30s:~# cm data connect
Connected through interface ‘rmnet0’
^C
Apr 11 17:11:14 | dcsDaemon[596]/dataConnectionService T=main | dcsServer.c LoadSelectedTechProfile() 828 | No value set for ‘SSID’!
Apr 11 17:11:14 | dcsDaemon[596]/dataConnectionService T=main | dcsServer.c TryStartWifiSession() 1703 | Impossible to use Wifi profile, result -1 (LE_NOT_FOUND)
Apr 11 17:11:19 | wifiService[604]/daemon T=main | le_wifiClient.c le_wifiClient_Disconnect() 1198 | Disconnect
Apr 11 17:11:19 | wifiService[604] | | WIFICLIENT_DISCONNECT
Apr 11 17:11:19 | wifiService[604] | | Failed to connect to non-global ctrl_ifname: wlan0 error: No such file or directory
Apr 11 17:11:19 | wifiService[604]/daemon T=main | pa_wifi_client_ti.c pa_wifiClient_Disconnect() 1041 | WiFi Client Command Failed: (24832)wlan0 WIFICLIENT_DISCONNECT
Apr 11 17:11:19 | wifiService[604]/framework T=main | le_wifiClient_server.c Handle_le_wifiClient_Disconnect() 1228 | Sending response to client session 0x27dcc : 4 bytes sent
Apr 11 17:11:19 | dcsDaemon[596]/dataConnectionService T=main | dcsServer.c TryStopWifiSession() 1951 | Impossible to disconnect wifi client
Apr 11 17:11:19 | modemDaemon[600]/le_pa T=main | pa_mrc_qmi.c pa_mrc_GetNetworkRegState() 2211 | called
Apr 11 17:11:19 | dcsDaemon[596]/dataConnectionService T=main | dcsServer.c CellNetStateHandler() 2250 | Device is attached, ready to start a data session
Apr 11 17:11:22 | dcsDaemon[596]/dataConnectionService T=main | dcsServer.c SetModemGateway() 1603 | Could not save the default gateway
Apr 11 17:11:23 | dcsDaemon[596]/dataConnectionService T=main | dcsServer.c AddNameserversToResolvConf() 1281 | Set DNS ‘10.177.0.34’ ‘10.177.0.210’
Any help is appreciated! Thanks.
Regards,
Eddie
Hi Eddie,
Your FX30 established a data session but you hit ^C
You have to either keep cm running, or run it in the background (note the &):
cm data connect&
BR,
Chris
Hi Chris,
Thanks for the response!
The ^c was because after I used the “cm data connect” command, it just hung there.
I tried the “cm data connect&” like you mentioned, but it still didn’t solve my problem. See results below:
root@fx30s:~# cm data connect&
root@fx30s:~#
root@fx30s:~# cm data
Index: 1
APN: fast.t-mobile.com
PDP Type: IPV4
Connected: yes
root@fx30s:~# telnet telehack.com
telnet: can’t connect to remote host (64.13.139.230): Connection timed out
root@fx30s:~#
If I load this firmware: 9999999_9904559_SWI9X15Y_07.13.07.00_00_GENERIC_001.040_000-full.spk,
these are my results:
root@fx30s:~# fwupdate query
Connecting to service …
Firmware Version: SWI9X15Y_07.13.07.00 92cfd2c jenkins 2018/08/22 19:18:52
Bootloader Version: SWI9X15Y_07.13.07.00 92cfd2c jenkins 2018/08/22 19:18:39
Linux Version: 3.14.29ltsi-yocto-standard #2 PREEMPT Sat Aug 4 23:41:40 UTC 2018
root@fx30s:~# cm data
Index: 1
APN: fast.t-mobile.com
PDP Type: IPV4
Connected: no
root@fx30s:~# cm data connect
Setting up profile 1
Connecting … ok
Checking if device ‘rmnet0’ is up … ok
Routing inet … ok
Updating /etc/resolv.conf … ok
Updating /etc/resolv.conf … ok
Testing connection … ok
root@fx30s:~# cm data
Index: 1
APN: fast.t-mobile.com
PDP Type: IPV4
Connected: yes
Interface: rmnet0
Family[IPv4]: inet
IP[IPv4]: 28.212.56.151
Gateway[IPv4]: 28.212.56.152
Dns1[IPv4]: 10.177.0.34
Dns2[IPv4]: 10.177.0.210
root@fx30s:~# telnet telehack.com
Connection closed by foreign host
You can see that the “cm data connect” command connects with no problem, and I’m able to open a telnet session with no problem.
But, the problem with this firmware, as you probably already know, is that I loose uart1 and GPIOs, and I need these for the app I’m developing.
Is the problem with the FX30S firmware? Thanks for your help!
Regards,
Eddie
Hi Eddie,
The SPK you’re loading is the WP stock image which has a different set of firewall rules compared to the FX30. The FX30 is shipped with the firewall mostly closed because it’s a commercial product so we want customers to purposefully and knowingly open ports to prevent security issues.
Try opening port 23:
iptables -I INPUT -m state --state NEW -p tcp --dport 23 -j ACCEPT
If this works, you can make the change persistent by editing the file:
/etc/iptables.rules
However, make sure you add the rule specifically to the rmnet0 interface and before the DROP rule.
BR,
Chris
Hi Chris,
I tried your suggestion above with no success. Still not able to connect using the telnet command.
How do I disable the firewall? I wanna see if that helps. Thanks!
Regards,
Eddie
Hi Eddie,
You can temporarily disable the firewall (until reboot) by:
iptables -F
BR,
Chris
Chris,
By disabling the firewall I was able to successfully open a telnet session to our server. So now I just have to figure out what in the firewall is keeping me from connecting to the server in the first place. Thanks for your help!
Eddie
Hi Eddie,
That’s great. Maybe you can try adding this rule in combination with opening the Telnet port:
iptables -I INPUT -m conntrack --ctstate RELATED,ESTABLISHED -j ACCEPT
This allows replies for traffic that originates from the FX30.
Also, carefully check the order of your rules. Make sure your DROP rule is not first. You can list out your rules:
iptables -L INPUT
BR,
Chris
Hi Chris,
That worked great! I appreciate the help! Thanks!
Regards,
Eddie