Hi,
I using the vintage_net_mobile library to establish a CAT-M1 cellular connection with the Sixfab Raspberry Pi Cellular IoT HAT.
If I understand correctly UART is enabled by default on the device v1.1.0. For the v1.3.0 HAT, UART is disabled by default and 2 jumpers need to be soldered. But I have the v1.1.0 version (and these jumpers don’t even exist).
Also UART doesn’t seem to have any non-default requirements for Nerves on rpi4.
Does anybody have experience with this kind of issue, to help me out a bit?
Using the USB connection this works beautifully:
iex> VintageNet.get_by_prefix(["interface", "ppp0"])
[
{["interface", "ppp0", "addresses"],
[
%{
address: {100, 85, 118, 2},
family: :inet,
netmask: {255, 255, 255, 255},
prefix_length: 32,
scope: :universe
}
]},
{["interface", "ppp0", "config"],
%{
type: VintageNetMobile,
vintage_net_mobile: %{
modem: VintageNetMobile.Modem.QuectelBG96,
scan: [:lte_cat_m1],
service_providers: [%{apn: "wm"}]
}
}},
{["interface", "ppp0", "connection"], :internet},
{["interface", "ppp0", "hw_path"], "/devices/virtual"},
{["interface", "ppp0", "lower_up"], true},
{["interface", "ppp0", "mobile", "access_technology"], "CAT-M1"},
{["interface", "ppp0", "mobile", "band"], "LTE BAND 8"},
{["interface", "ppp0", "mobile", "channel"], 3700},
{["interface", "ppp0", "mobile", "cid"], 2639383},
{["interface", "ppp0", "mobile", "iccid"], "..."},
{["interface", "ppp0", "mobile", "imsi"], "..."},
{["interface", "ppp0", "mobile", "lac"], 260},
{["interface", "ppp0", "mobile", "mcc"], 204},
{["interface", "ppp0", "mobile", "mnc"], 16},
{["interface", "ppp0", "mobile", "network"], "T-Mobile NL"},
{["interface", "ppp0", "mobile", "signal_4bars"], 4},
{["interface", "ppp0", "mobile", "signal_asu"], 30},
{["interface", "ppp0", "mobile", "signal_dbm"], -53},
{["interface", "ppp0", "present"], true},
{["interface", "ppp0", "state"], :configured},
{["interface", "ppp0", "type"], VintageNetMobile}
]
It does claim 4 USB slots, but I’m not sure whether that is not normal.
iex()> Circuits.UART.enumerate
%{
"ttyAMA0" => %{},
"ttyS0" => %{},
"ttyUSB0" => %{
description: "Qualcomm CDMA Technologies MSM",
manufacturer: "Qualcomm, Incorporated",
product_id: 662,
serial_number: "...",
vendor_id: 11388
},
"ttyUSB1" => %{
description: "Qualcomm CDMA Technologies MSM",
manufacturer: "Qualcomm, Incorporated",
product_id: 662,
serial_number: "...",
vendor_id: 11388
},
"ttyUSB2" => %{
description: "Qualcomm CDMA Technologies MSM",
manufacturer: "Qualcomm, Incorporated",
product_id: 662,
serial_number: "...",
vendor_id: 11388
},
"ttyUSB3" => %{
description: "Qualcomm CDMA Technologies MSM",
manufacturer: "Qualcomm, Incorporated",
product_id: 662,
serial_number: "...",
vendor_id: 11388
}
}
But then I disconnect the USB, the modem cannot be found over UART alone.
iex(16)> Circuits.UART.enumerate
%{"ttyAMA0" => %{}, "ttyS0" => %{}}
It states as not present:
iex(5)> VintageNet.Info.info
VintageNet 0.9.2
All interfaces: ["eth0", "lo", "wlan0", "wwan0"]
Available interfaces: ["wlan0"]
Interface ppp0
Type: VintageNetMobile
Present: false
Configuration:
%{
type: VintageNetMobile,
vintage_net_mobile: %{
modem: VintageNetMobile.Modem.QuectelBG96,
scan: [:lte_cat_m1],
service_providers: [%{apn: "wm"}]
}
}
I did build a custom system-rpi4 with PPP and additional USB flags enabled as stated in the vintage_net_mobile docs. See GitHub - basvanwesting/custom_rpi4: nerves_system_rpi4 for mobile for that custom system-rpi4 setup.
I did find a small deviation from the docs there as the CONFIG_USB_NET_CDC_NCM flag cannot be enabled explicitly through make linux-menuconfig
, but seems implicitly enabled though CONFIG_USB_NET_HUAWEI_CDC_NCM, which also enabled CONFIG_USB_USBNET). So I just edited the linux-4.19.defconfig
manually. But that doesn’t seem related. I just mentioned it for completeness.
Regards, Bas