Android notifications in GNOME Linux with GSConnect

MacOS’s Continuity show the possible level of integration between an iPhone and a Mac computer when a single company controls the OS stack of both devices. Sync notifications, make and pick-up phone calls from the desktop, file sharing, etc. Less powerful, but on the same line, the Android – ChromeOS integration offered by Google.

I’ve always missed something similar to show my Android phone notifications on my Linux desktop, without using questionable cloud services (in terms of privacy). But today I almost completely filled the gap, thanks to KDE Connect.

KDE Connect allows devices to securely share content like notifications or files and other features like SMS messaging, clipboard sync and remote control. The complete list of features supported by KDE Connect is impressive:

  • Receive phone notifications on the desktop computer and reply to messages
  • Control music playing on the desktop from the phone
  • Use the phone as a remote control for the desktop
  • Run predefined commands on the desktop PC from connected devices
  • Check the phone’s battery level from the desktop
  • Ring the phone to help find it
  • Share files and links between devices
  • Browse the phone from the desktop
  • Control the desktop’s volume using the phone
  • Send SMS from the desktop

And there are two additional good news: everything runs locally on the Linux desktop computer (no cloud needed), and there is a porting for GNOME, called GSConnect. It uses GNOME Shell with Nautilus, Chrome and Firefox integration.

KDE Connect wiki has detailed instructions on how to install and configure the software. Below, I’ll report what I did to install and configure GSConnect on my Linux box with Ubuntu 20.04.

GSConnect installation

Despite being available as gnome-shell-extension-gsconnect package since Focal (20.04), it seems the recommended way to install GSConnect is via a GNOME Shell extension. So, I opened the relative GNOME Shell Extensions website on my Linux desktop computer, and agreed in installing the extension.

Alternatively, there is a manual installation procedure, consisting in download the latest release of the Extension from GitHub, and then installing it using the following command:

gnome-extensions install --force gsconnect@andyholmes.github.io.zip

A restart of GNOME Shell is required, and there are different ways of doing it, based on Wayland or X11/Xorg (how to know the server in use).

Android installation

In parallel, the app KDE Connect needs to be installed from Google Play or F-Droid.

Then, the setup can continue following the standard instructions, both on Android phone, and on the desktop computer. In a couple of minutes, the mobile device should be paired with the desktop.

The GSConnect extension menu, after paired with the mobile device

Several app features will work only after granting the respective Android App Permissions to KDE Connect. The app shows a list of those that are disabled, and tapping on one of them opens the corresponding system setting, where the permission can be given.

For example, to share notifications with the desktop computer, open the app, tap on the “Notification sync”, and then tap again to open the corresponding system setting for granting the permission.

To enable integration with Nautilus, in order to send files from the desktop computer to the mobile device, the python-nautilus package has to be installed:

sudo apt install python-nautilus
Easily send files from desktop to the configured destination folder on the mobile device

In case of problems, the Help section of the wiki contains troubleshooting instructions to follow.

Conclusions

GSConnect desktop app, and the KDE Connect mobile app, offer a long list of feature that will require some time to be explored and mastered. But they almost allow to forget to have a mobile phone while using a desktop computer.

As a final note, there are early releases of KDE Connect for Windows and MacOS.

AS/400 tn5250 terminal on Linux

as400term-xt5250_tn
There are lot of ways for accessing to the AS400 functionalities (today know as iSeries, a wide-used “mainframe” produced by IBM) and one of the most important is, surely, the tn5250 terminal emulation.

Under Gnu/Linux, we can do this with different software, and each one has is pros and cons.

Personally i used the tn5250 software for simply terminal emulation, but also the IBM iSeries Access for Linux can be used for most advanced functions.

tn5250 – Linux tn5250 emulator

Under Debian and Debial-like distros (like Kubuntu, that i use), first step is install the tn5250 software

sudo apt-get install tn5250

or use your preferred package manager (synaptic, kpackage, others)

After this, you are virtually ready to connect to your AS400. Just run the following command (172.16.1.1 is the IP address of my AS400):

xt5250 172.16.1.1

The software, like the tn5250 protocol itself, has lot of options, but for my needs the most important are:

  • map: set the translation table between ASCII and EBCDIC. In my case, i use an italian translation map, corresponding to the code 280. For a list of all translation maps, run this command: man tn5250rc and search for the Translation Maps section
  • env.DEVNAME: set the device name for the AS/400 to assign to the 5250 session. In my case, this name is DSP002A
  • env.TERM: Set the terminal model name for the emulation session to use. In my case is IBM-3477-FC (80×132 color mode). For a list of all terminal models, run the same command of above, man tn5250rc, and search for Display Types section
  • font_80: the font used when terminal is in 80 column mode
  • font_132: the font used when terminal is in 132 column mode

Ok, with this parameters, my launch string became:

/usr/bin/xt5250 map=280 env.DEVNAME=DSP002A env.TERM=IBM-3477-FC font_80=10×20 font_132=10×20 172.16.1.1

I put this string in a new menu entries, using the icon from the file /usr/share/pixmaps/tn5250-48×48.png

Kde menu with tn5250 shortcut

Joke is done :)

Little trick: with Ctrl + Right click over the tn5250 window, you can access to the “VT Fonts” menu, and with Ctrl + Left click you can access to the “Main Options” menu.

You can also create a config file with all the options and then launch xt5250 <filename>. Search under the tn5250rc manual page for more information and take a look to this and this useful topic

{mxc}