Tag: snapdragon-410

  • OpenStick adventures Part 2: GPS

    It would be great if the GPS part of the modem could be used.

    Modem manager supports this, and it should be as simple as running the command below:

    sudo mmcli -m 0 --location-enable-gps-nmea --location-enable-gps-raw --location-enable-3gpp

    This command enables NMEA and Raw output as well as the coarse network location derived from the mobile network.

    I have yet to acquire any satellite signals.

    sudo mmcli -m 0 --location-get
    ... 3GPP Output cut ...
      --------------------------
      GPS  |               nmea: $GPGSA,A,1,,,,,,,,,,,,,,,*1E
           |                     $GPRMC,,V,,,,,,,,,,N*53
           |                     $GPVTG,,T,,M,,N,,K,N*2C
           |                     $GPGGA,,,,,,0,,,,,,,,*66
    

    The first line shows that no satellites are available and the rest just confirm that no fix is possible.

    The link below shows common NMEA sentences and how to decode them properly.

    https://pe2bz.philpem.me.uk/Comm/-%20Receivers/-%20GPS/Info-921-GPS/Site1/Gps-Diags/NMEA_sentences.htm

    Maybe I need to find a better location to put the stick and give it longer for a cold fix. The building I am in has thick stone walls and I haven’t found a suitable location for a power supply that has good visibility of the sky. I might try the conservatory over night.

    AGPS

    Augmented GPS should, in theory massively improve fix times on basic GPS devices. there are two modes of operation MSB and MSA. MSB is a simpler mode where an aGPS server is used to proved network time, this can reduce the time taken to get an initial fix. MSA lets the aGPS server carry out much more of get calculation required. This is provided by fewer aGPS providers.

    In my experimentation I was able to enable MSA, but reveived and error when I tried to enable MSB. I am currently not sure whether this is due to a configuration error (URLS and servers) or an issue with my modem.

    The flags: --location-enable-agps-msb and --location-enable-agps-msa are used to control this behaviour.

    When enabling MSB mode I receive the following error:
    error: couldn't setup location gathering: 'GDBus.Error:org.freedesktop.ModemManager1.Error.Core.Aborted: Couldn't enable location 'agps-msb' gathering: Failed to receive operation mode indication'

    Update 2025/01/15

    After nearly 24 hours to acquire a signal there is still no change.
    I have to assume that the antenna or other parts required for GNSS are not present or configured properly in these dongles. This would make sense if an active antenna is required or additional hardware for such a cheap device, it would have been just too good to be true.

  • Openstick Adventures

    I recently purchased a selection of cheap LTE dongles that contain the MSM8916 chip (AKA Snapdragon 410). These are available from the usual east asian websites, or for slightly higher prices on local e commerce sites.

    They provide a similar compute performance to a raspberry pi zero in a very similar form factor. the primary

    Here is an overview of the specs:

    https://www.qualcomm.com/products/mobile/snapdragon/smartphones/snapdragon-4-series-mobile-platforms/snapdragon-processors-410

    I want the companion computer to achieve several things:

    1. Forward MavLink messages between the ground station and the Flight Controller (FC), securely, either via either wifi (direct) or via LTE.
    2. Serve as a platform for onboard logic to add higher level functionality to the drone.
    3. It may be possible to enable the GNSS (GPS) receiver onboard the modem. this could then be used as a backup location source for the FC

    There are a couple options for connecting to the FC: directly over serial; if the serial port on the dongle can be used for a purpose other than the default serial console then this would be the most direct and easiest solution. As an alternative to this the dongle support both gadget and host USB modes which could be used to connect to the FC over USB. this would open up other options for USB devices to be used on the drone, such as a webcam.

    I initially purchased a single stick which tunred out to be a UZ801 3.0 after flashing it with debian and running some benchmarks and failing to get the modem to connect to LTE I decided to purchase a few more to play with and hopefully find one that “Just Works ™”. I ordered a pair of dongles like the first, with one being the same revision as the first and the other a slighly later model 3.2 this is missing the eSIM chip that is present on th earlier version.

    I also bought a version that includes a screen, I am hoping that this too may be possible to use in linux at some point. I am not entirely sure what the the model of display is.

    Feature\StickBlack-1Black-2White-1MF880s
    ModelUZ801 3.0UZ801 3.2UZ801 3.0MF880S
    DebianYes (buster & bookworm)Yes (Bookworm)still running stock firmwareNot tried
    WiFiYesYesYesYes
    LTENo- Sim enabled, modem enabled, error on registrationYes, fully functionalYes (in stock firmware)Yes (in stock firmware)
    eSIM N/ANot TriedN/ANot Tried
    GNSSNot TriedNot TriedNot TriedNot Tried
    USB HOST ModeNot TriedNot TriedNot TriedNot Tried
    USB GadgetsEthernet (default)Ethernet (default)
    HW UART (other than serial console)
    Yes,
    SystemD script to disable on successful boot
    Yes,
    SystemD script to disable on successful boot
    Yes

    Security

    Once I had the LTE modem working on the second stick I tried installing wireguard. I already have a wireguard network and I thought that adding the stick to this existing private network would be the simplest method to achieve some level of privacy.

    Unfortunately although wireguard installs fine through sudo apt install wireguard the required kernel module was not compiled in, more specifically it was compiled as a module and I was not able to enable it.

    A (temporary) fix for this is to install wireguard-go, this is a userspace implementation of the wireguard protocol and plays nice with wg-quick and wireguard commands installed.

    I also configured several WiFi networks so that regardless of which building I am in the stick connects to a known network if possible. it also automatically connects to the wireguard network and displays its status via the blue LED on the stick (rapid flashing for internet connected, slow flashing for wireguard connected). So now I know immediately whether the stick is available on a known private IP.

    Update 25/12/24

    I have been using some tools from the repo below to configure the system on boot, I have tweaked some values to better suit my needs.

    https://github.com/hyx0329/openstick-failsafe-guard

    I now have it reconfigure the serial port from a console to the MAVLink port once the succesfull boot has been confirmed.

    Update 2025/01/19 (Getting into EDL mode)

    There are two methods of getting into EDL mode once the stick as been flashed with debian:
    1. Hold the button on the stick for 5 seconds while plugging in. This gets you to fastboot. Then on the host use the command fastboot oem reboot-edl .

    2. the other is to short two pads on the stick itself while plugging the device in. This method is fiddly but more reliable if you have really messed up

    When trying to restore a backup using the EDL tool. I have encountered an issue where the tool gets stuck with the last message being main - Device detected :). Rebooting the device into EDL again fixed this issue for me.