Blog

  • Open Location Code

    Open Location Code (OLC) is a geocoding system that encodes latitude/longitude coordinates into a short string of typically 9-12 characters, the idea being that these strings can be communicated better than the latitude/longitude coordinates themselves.

    Individual codes are also called plus codes, because the OLC specification mandates a ‘+’ character after the eighth code digit for easier identification. An example is the plus code 9F4MG98H+G3, encoding the location (52.516312,13.377688) – or rather, a small area of around 100m² including the location.

    Full vs. Short codes

    Full plus codes – codes with eight characters preceding the ‘+’ – are globally unique, and can be decoded offline and without any additional information. Alternatively, a reference location can be used to shorten plus codes by dropping leading characters.

    This reference location needs to be known to properly decode the shortened plus code. It can be added to the end in form of a place name, in which case the example location given above becomes G98H+G3, Berlin. It may also be shared knowledge, for example when arranging a meeting in a certain city.

    One promoted use case for short plus codes are postal services in regions where street adresses don’t exist. After getting a postal item to the correct city, a short plus code like G98H+G3M could be used within the city to identify the correct dwelling to deliver to.

    Exact vs. coarse location

    While plus codes are mostly designed to address a specific location, they can also be used to identify larger areas, by removing characters (or replacing them with ‘0’ as a padding character) from the end:

    example codeapproximate size
    9F4MG98H+G3Mprecise enough to identify a specific entrance to a building
    9F4MG98H+G3single-family house
    9F4MG98H+small neighborhood
    9F4MG900+city district
    9F4M0000+larger than Berlin, Germany
    9F000000+most of the Scandinavian peninsula plus surrounding seas, large parts of Germany, Poland, the Netherlands, Belgium etc.
    comparison between plus codes of various lengths and the area identified by that code

    The multi-colored elephant in the room

    The Open Location Code system was developed by one of Google’s engineering teams, and is actively used on Google Maps: you can search for any plus code, and points of interest will typically display their shortened plus code.

    While that makes the use of short codes somewhat controversial – the typical argument being that decoding a short code will only work while having access to the same geocoding database that was used to shorten the code in the first place – it doesn’t affect the use of full plus codes at all, and is a mostly theoretical concern in many other scenarios.

    Links

  • How to use FirebaseUI for Android

    Firebase is an app development platform by Google, offering various services for Android, iOS and the web. The services themselves are supported by a set of open-source libraries like FirebaseUI Android. According to the Firebase Open Source website,

    FirebaseUI is an open-source library for Android that allows you to quickly connect common UI elements to Firebase APIs.

    At the time of writing this in January 2025, the latest release of this library (v8.0.2) was published in September 2022, more than 2.5 years ago. The main branch of the GitHub repository has not seen a single commit since then – and while other branches at first glance suggest that a potential v8.1.0 or even v9.x is being worked on, none of these branches have seen any meaningful changes after their respective initial commits.

    For all intents and purposes, the FirebaseUI library version that can be used today is the version that was published while Android 13 was still new and the latest Firebase BoM was v30.5.0 (compare to the most recent BoM here) – and it shows:

    • FirebaseUI depends on SafetyNet, which was announced to be deprecated in 2022, with full turndown at the end of January 2025 after an extended timeline (issue)
    • FirebaseUI does not work with Android SDK 34 released in 2023 (issue)
    • FirebaseUI can’t be compiled using a dependency on Play Services Auth >= 21.1.0 since early 2024 (issue)
    • FirebaseUI comes with its own Play Services dependencies, although those are no longer required by Firebase (issue)
    • FirebaseUI uses the deprecated Google Sign-In that will be removed in 2025 instead of Credential Manager (issue)

    Adding insult to injury, the official Firebase Auth documentation suggests to add dependencies for the even older v7.2.0 released in June 2021.

    tl;dr

    Do not use FirebaseUI for Android, because its codebase is rotten.

  • Hello, World!

    This is the beginning – or, if you’re reading in reverse chronological order, the end. All beginnings (and endings) are hard, so without further ado: I’m Andreas and I’ve been fascinated by computers and related technology for as far as I can think back.

    Photo of an Amiga 500 Plus home computer, showing the "AMIGA" and "Commodore A-500 Plus" logos in the upper right corner, and parts of the keyboard below it.
    Detail of an AMIGA 500 Plus, the first home computer I owned.

    This might become a place where I put longer texts about technology, computing, coding and related, both new and old – or it might stay just another mostly empty web page. We’ll see… 😉