Nimberlink Skyware User manual

Skywire™
DevelopmentKit
Using the USB Qualcomm MSM
Interface(QMI)ProtocolinLinux
NimbeLinkCorp.
Revised:June2015
PN30052rev1 NimbeLinkCorp.AllRightsReserved. 1

TableofContents
1. INTRODUCTION
1.1. APPLIESTOTHESEPARTNUMBERS
1.2. OVERVIEW
1.3. PREREQUISITES
2. QMISETUPANDUSE
2.1. CHECKFORUPDATES
2.2. INSTALLTHELIBQMIPACKAGE
2.3. CONFIGUREAPN
2.4. CONNECTSKYWIRE™DEVELOPMENTKIT
2.5. POWERONTHEMODEM
2.6. VERIFYUSBANDWWAN0CONNECTIONS
2.7. TAKEDOWNTHEETHERNETINTERFACE
2.8. BRINGUPTHEQMICONNECTION
2.9.STARTDHCPCLIENT
2.10. TESTTHEQMICONNECTION
2.11. BRINGDOWNTHEQMICONNECTION
PN30052rev1 NimbeLinkCorp.AllRightsReserved. 2

1. Introduction
1.1. AppliestothesePartNumbers
OrderableDevice
Description
Carrier
NLSWDK
Skywire™DevelopmentKit
Any
NLABBBBC
Skywire™BeagleBoneBlack
Cape
Any
NLSWLTETSVG
LTEwithoutFallback,GPS,
GLONASS
Verizon
NLSWLTETNAG
LETwithHSPA+Fallback,GPS,
GLONASS
AnyGSM(AT&T,TMobile,
etc.)
NLSWLTETEUG
LTEwithHSPA+Fallback,GPS,
GLONASS,EU
AnyEUGSM
1.2. Overview
This document describes using the Qualcomm MSM (Mobile Station Modems)
Interface (QMI) protocol to interface a Skywire™ 4G modem over USB to the
Linuxoperatingsystemandaccessthe4GnetworkasanIPinterface.
With the protocol in place, the interface to the modem looks more like an
Ethernet device than a serial communication device. It is therefore more efficient
intermsofmovingdatainandoutoftheLinuxnetworkstack.
Examplesprovidedhavebeentestedwith:
NLSWLTETSVG firmwareversion17.00.573
NLSWLTETNAGfirmwareversion1x.xx.x.x
Hardware setup is the Skywire™ modem plugged into the Skywire Development
KitandUSBcableconnectingMiniUSBconnectorJ5into:
BeagleBoneBlackUSBhostportor
RaspberryPiUSBhostport
Alternative configuration is the Skywire modem plugged into BeagleBone Black
Cape (NLABBBBC) and Cape plugged into BeageleBone Black with USB cable
connectingtheCapetotheBeagleBoneUSBHostport.
These examples were prepared using Arch Linux (release as of 04/01/2015) on
theRaspberryPiandtheBeaglebone.
PN30052rev1 NimbeLinkCorp.AllRightsReserved. 3

1.3 Prerequisites
This document assumes you have completed the initial setup
of your modem and development kit. If you have not
completed those steps, refer to the Skywire™ Development
Kit User Manual and complete the modem setup before
proceeding. . The modem must already be provisioned or
PDP context set before continuing. See the Development Kit
UserManualfordetailsonhowtoaccomplishthesesteps.
Your Linux platform will need kernel version 3.10 or later.
There are issues in earlier kernels that prevent the required
driver from working correctly and the USB IDs of the
Skywire™4Gmodemsarenotpresent.
Your kernel will need the "qmi_wwan" driver installed. This
drivercanbeeitherbuiltinoraloadablemodule.
If you are using a Raspberry Pi, Beaglebone, or other embedded
platform without keyboard and video console, you will need to be
connected to that platform via the serial console since later we will
take down the Ethernet interface that may be serving as your
consoleconnection.
PN30052rev1 NimbeLinkCorp.AllRightsReserved. 4

2. QMISetupandUse
2.1. CheckforUpdates
Make sure your Arch Linux system is fully updated by typing the following
command:
#pacmanSyu
followedbytheenterkey,anddownloadingthelatestupdates.
2.2. InstallthelibqmiPackage
Thelibqmipackageisrequired.Toinstallit,type:
#pacmanSlibqmi
followedbytheenterkey.
2.3. ConfigureAPN
LTE modems must use specific Access Point Names (APN) provided by the
cellularcarrier.
The“qminetwork”toolrequiresthattheAPNbeconfiguredinthefile:
/etc/qminetwork.conf
To create this file, we will use the nano text editor; however you can use
whatevertexteditoryouprefer.Typethefollowingcommand:
#nano/etc/qminetwork.conf
followedbytheenterkey,andaddthefollowingline:
APN=yourAPN
Where “yourAPN” is the APN your cellular provider has told you should be used
forthismodemandtheSIMitisoperatingwith.Exampleswouldbe:
APN=VZWINTERNET
APN=broadband
APN=mw01.VZWSTATIC
PN30052rev1 NimbeLinkCorp.AllRightsReserved. 5

Once you have entered your APN according to the above format, save the file.
In nano press CTRLX. It will ask if you want to save your changes: press y.
nano will then ask what you would like to name the file. Verify that it is named
/etc/qminetwork.conf and press the Enter key. You will then be returned to the
commandline.
2.4. ConnectSkywire™DevelopmentKit
Plug in your USB cable to port J5 on your Skywire™ Development Kit. Then,
plugthecableintothecomputer.
2.5. PowerontheModem
Power on your Skywire™ modem according to the Skywire™ Development Kit
User Manual, and after approximately five seconds, you should see syslog
entriesappearasthesystemenumeratesthenewUSBdevice:
[61583.248406]sub11.5:newhighspeedUSBdevicenumber5usingdwc_otg
[61583.385322]usb11.5:NewUSBdevicefound,idVendor=1bc7,
idProduct=1201
[61583.401475]usb11.5:NewUSBdevicestrings:Mfr=1,Product=2,
SerialNumber=3
[61583.417954]usb11.5:Product:Android
[61583.430903]usb11.5:Manufacturer:Android
[61583.444012]usb11.5:SerialNumber:0123456789ABCDEF
[61583.487521]option11.5:1.0:GSMmodem(1port)converterdetected
[61583.514644]usb11.5:GSMmodem(1port)converternowattachedto
ttyUSB0
[61583.551854]qmi_wwan11.5:1.2:cdcwdm0:USBWDMdevice
[61583.592282]qmi_wwan11.5:1.2wwan0:register'qmi_wwan'at
usbbcm2708_usb1.5,WWAN/QMIdevice,2a:d5:e4:1c:f1:82
[61583.621759]option11.5:1.3:GSMmodem(1port)converterdetected
[61583.637369]usb11.5:GSMmodem(1port)converternowattachedto
ttyUSB1
[61583.654202]option11.5:1.4:GSMmodem(1port)converterdetected
[61583.669672]usb11.5:GSMmodem(1port)converternowattachedto
ttyUSB2
[61583.686265]option11.5:1.5:GSMmodem(1port)converterdetected
[61583.708173]usb11.5:GSMmodem(1port)converternowattachedto
ttyUSB3
[61583.739549]option11.5:1.6:GSMmodem(1port)converterdetected
[61583.771578]usb11.5:GSMmodem(1port)converternowattachedto
ttyUSB4
PN30052rev1 NimbeLinkCorp.AllRightsReserved. 6

2.6. VerifyUSBandwwan0Connections
TypethefollowingcommandtoverifythattheUSBmodemispresent:
#lsusb
Typicalresponse:
Bus001Device005:ID1bc7:1201TelitWirelessSolutions
You should also see the wwan0 device appear in the network stack as shown
aboveorifqueried,
#ifconfigwwan0
TypicalResponse:
wwan0: flags=4098<BROADCAST,MULTICAST>mtu1500ether
2a:d5:e4:1c:f1:82txqueuelen1000(Ethernet)
RXpackets0bytes0(0.0B)RXerrors0dropped0overruns
0frame0
TXpackets0bytes0(0.0B)
TXerrors0dropped0overruns0carrier0collisions0
2.7. TakeDowntheEthernetInterface
A QMI connection requires that any existing Ethernet connection be taken down.
This is required so that the DHCP client serving the cellular link can correctly
configurethesystemgatewayandDNSresolver.
TobringdowntheEthernetconnection,typethefollowingcommand:
#ifconfigeth0down
2.8. BringuptheQMIConnection
TobringuptheQMIconnection,typethefollowingcommands:
#ifconfigwwan0up
#qmiclid/dev/cdcwdm0
dmssetoperatingmode=online
Typicalresponse:
[/dev/cdcwdm0]Operatingmodesetsuccessfully
#qminetwork/dev/cdcwdm0start
Typicalresponse:
PN30052rev1 NimbeLinkCorp.AllRightsReserved. 7

Loadingprofile...
APN:broadband
Startingnetworkwith'qmiclid/dev/cdcwdm0
wdsstartnetwork=broadbandclientnoreleasecid'...
Savingstate...(CID:10)
Savingstate...(PDH:1205860592)
Networkstartedsuccessfully
2.9. StartDHCPClient
TostarttheDHCPclient,typethefollowingcommand:
#dhcpcdwwan0
Typicalresponse:
DUID00:01:00:01:1d:00:d0:a3:3e:2a:2d:5f:50:26
wwan0:IAIDe4:1c:f1:82
wwan0:solicitingaDHCPlease
wwan0:offered10.124.149.216from10.124.149.217
wwan0:leased10.124.149.216for7200seconds
wwan0:addingrouteto10.124.149.216/30
wwan0:addingdefaultroutevia10.124.149.217
forkedtobackground,childpid2465
2.10.TesttheQMIConnection
TotesttheQMIconnection,typethefollowingcommand:
#ping–c3www.google.com
Typicalresponse:
PING www.google.com (74.125.198.99) 56(84) bytes of data.
64 bytes from oginf99.1e100.net (74.125.198.99): icmp_seq=1 ttl=41 time=110 ms
64 bytes from oginf99.1e100.net (74.125.198.99): icmp_seq=2 ttl=41 time=89.9 ms
64 bytes from oginf99.1e100.net (74.125.198.99): icmp_seq=3 ttl=41 time=88.6 ms
www.google.com ping statistics
3 packets transmitted, 3 received, 0% packet loss, time 2002ms
rtt min/avg/max/mdev = 88.625/96.521/110.976/10.235 ms
2.11.BringDowntheQMIConnection
TobringdowntheQMIconnection,typethefollowingcommand:
#qminetwork/dev/cdcwdm0stop
TostoptheDHCPclient,type:
#kill`cat/var/run/dhcpcd.pid`
PN30052rev1 NimbeLinkCorp.AllRightsReserved. 8

Finally,tobringdownthewwan0interface,type:
#ifconfigwwan0down
PN30052rev1 NimbeLinkCorp.AllRightsReserved. 9
Table of contents
Popular Microcontroller manuals by other brands

NimbeLink
NimbeLink Skywire NL-SW-1 RTT-A Series user manual

New Micros
New Micros TiniARM user manual

Nvidia
Nvidia JETSON NANO user guide

Microchip Technology
Microchip Technology PIC16F18076 user guide

adafruit learning system
adafruit learning system Trinket introduction

Texas Instruments
Texas Instruments CC2520EM quick start guide