A html canvas based screencasting server with occasional ground-truth updates via screenshots and very fast input drawing

Overview

rm2canvas

A html canvas based screencasting server for the reMarkable 1/2 digital paper systems. It draws live on the canvas from the remarkables touchscreen input, but also fetches ground truth via occasional screenshots from the remarkable, trying to (seamlessly) integrate these two.

Why is it cool?

  • High quality screencast, with native 1872x1404 resolution (These are unfortunately a few seconds old, bad for live presentations)!
  • Instantanious updates on what is drawn/removed on the rm via the Wacom pen (30 times per second)!
  • Smooth interpolation between those two!
  • Low data usage: Updates are only send if there is something to update. As the event stream is rather small and the PNG backgrounds are just updated every few seconds, the whole streaming experience uses just ~20-50kb/s.

These features make it ideal for streaming a course too many students. That's why I developed it, at least.

Usage

  1. enable SSH access on your remarkable

Warning: Please be aware of the risks of running go code as root on a potentially brickable device. Be especially aware on software updates of xochitl. I do not think that there are extended risks, but please try to understand what this script is doing.

  1. Install imagemagick as we both need the convert and the compare tool as well as websockets via pip.
  2. start the server via python3 server.py HOSTADDRESS, where HOSTADDRESS could be either localhost or some IPv4/IPv6 address. This opens a (maybe publicly reachable!) HTTP Server on Port 7622. Be aware that the file request sanitzier was programmed at 02:53 in the morning.

ToDo:

  • enable rm1 support. Should be almost trivial, I just don't have any device to test this with.
  • remove canvas strokes with a smooth transition instead of abruptly deleting them (eyecandy)
  • Hunt bugs. Please report any you encounter!
  • Fix rotation.

Planned bigger features

  • detect swipes to new pages and save a backlog of pages in the html
  • Make setup easier
  • Switch to a "real" http server, not something made in websockets.
  • Make HTTPS support easier

Background

Building upon others work:

The original idea of drawing to a html canvas with input capured from the reMarkable is @afandians idea, see https://gitlab.com/afandian/pipes-and-paper. We modified (and hopefully improved) his code significantly, but the basic idea remains.

Furthermore, the rm2 screenshotter is due to a gist of https://gist.github.com/owulveryck (https://gist.github.com/owulveryck/4007cbf14e0028f373e4294f66c4ad07), who himself builds upon a lot of other peoples work, see https://github.com/rien/reStream/issues/28.

Input parsing was easy thanks to the information here: https://github.com/canselcik/libremarkable/wiki/Reading-from-Wacom-I2C-Digitizer

I (flomlo) also recevied generous amounts of help of my friends

Thank you

Working principles

The reMarkable features a full Linux with root access. This means that we may just read the input device /dev/input/event1 (or event0 on rm1) via the following command:ssh -o ConnectTimeout=2 {rm_user}@{rm_host} cat {input_device}. This information is parsed in tipa.py according to the rules described in the libremarkable wiki and send to the JavaScript frontend via the websocketInput. There the input is drawn on a html canvas (and saved in an Array together with a timestamp).

Concurrently a new screenshot is grabbed every few seconds and send (together with a timestamp tsBg) to the JavaScript frontend via the websocketBackground. There it triggers a transition to the newest screenshot as well as triggering the removal of all Canvas strokes older than that timestamp.

The websocket server is happy to serve as many clients as there are, the only limits are currently the bandwith (and CPU, as it is single-threaded via pythons asyncio). Simultanious streaming to ~20 devices was already tested.

A Minimalistic Backup GUI for your Windows, Mac or Linux

BlobBackup is a minimalistic backup utility for your Windows, Mac or Linux computer. With an excellent engine, extensive storage support, and an easy

283 Nov 30, 2022
GUI Python Auto text bot.

Bagel Text Bot Auto text bot. Written in Python. Contributing Pull requests are welcome. For major changes, please open an issue first to discuss what

Toby 3 May 14, 2022
UI to save and load gnome-shell extension templates.

Gnome Extensions Loader GUI to save and load gnome shell extensions and extension settings. This app makes it easier to share your gnome extensions se

EMRECAN ALTINSOY 2 Nov 25, 2022
Dear PyGui: A fast and powerful Graphical User Interface Toolkit for Python with minimal dependencies

(This library is available under a free and permissive license however, if you Enjoy Dear PyGui please consider becoming a Sponsor) Dear PyGui is a si

Jonathan Hoffstadt 9.4k Jan 04, 2023
A Url Shortener with GUI made in Python.

Url-Shortener-with-GUI-in-python A Url Shortener with GUI made in Python. To Run this download the zip file and run the main file or Clone this repo.

SidTheMiner 1 Nov 12, 2021
Randomly picks between your favourite meals for you when you're feeling indecisive.

Food Recommendations Desktop application created with python and tkinter. The goal for this application is to provide a way for users to enter and sav

Jesse Kartabani 1 Dec 07, 2021
Turn (almost) any Python command line program into a full GUI application with one line

Gooey Turn (almost) any Python 2 or 3 Console Program into a GUI application with one line Support this project Table of Contents Gooey Table of conte

Chris 17k Jan 09, 2023
A little Python library for making simple Electron-like HTML/JS GUI apps

Eel Eel is a little Python library for making simple Electron-like offline HTML/JS GUI apps, with full access to Python capabilities and libraries. Ee

Chris Knott 5.4k Jan 07, 2023
Text to Binary Converter

Text to Binary Converter Programmed in Python | PySimpleGUI If you like it give it a star How it works Simple text to binary and binary to text conver

Adrijan 11 Dec 06, 2022
Json IDE made with Python tkinter!

JIDE Json IDE made with Python tkinter! Download: https://github.com/LouisTheXIV/JIDE/releases/tag/v0.1 Features In JIDE everything is customisable do

n0 7 May 14, 2022
Criando interfaces gráficas com Python e Qt 6 (PyQt6)

Criando interfaces gráficas com Python e Qt 6 (PyQt6) Qt O Qt é um framework para criação de interfaces gráficas multiplataforma, atualmente ele é des

Renato Cruz 1 Jun 07, 2022
Example GUI for Command line capable machine learning programs

Example GUI for Command line capable machine learning programs This is an example GUI made in PysimpleGUI and Tkinter, mainly for machine learning pro

Kim Yongwook 4 May 31, 2022
A simple quiz app using API and GUI

GUI-Quiz-APP It's a simple quiz app using API and GUI.

KALPAK KUMAR DAS 1 Feb 03, 2022
Multi-handle range slider widget for PyQt/PySide

QtRangeSlider The missing multi-handle range slider widget for PyQt & PySide The goal of this package is to provide a Range Slider (a slider with 2 or

Talley Lambert 28 Dec 26, 2022
Weather-API-GUI-Tkinter - A weather tool made using tkinter which works by fetching query city weather using an API

Weather-API-GUI-Tkinter ☁️ ❄️ version- 1️⃣ . 0️⃣ . 0️⃣ This repo contains a weat

SasiVatsal 4 Jul 08, 2022
The quick and easy way to add versatile graphical interfaces with networking capabilities to your Python programs.

The quick and easy way to add versatile graphical interfaces with networking capabilities to your Python programs. Give instant access to your application to whoever you want on the Internet, without

Claude SIMON 215 Dec 28, 2022
All you need to learn Tkinter!

Tkinter This repository contains the codes and resources which I used to learn the standard GUI library of Python, Tkinter! Best Tkinter Resources Vid

Samyak Jain 3 May 02, 2022
A Virtual Desktop Assistant Written in Python

DesktopAssitant A Virtual Desktop Assistant Written in Python. It's generally a basic virtual assistant The basic purpose of this is to make work easi

Technerd brainiac 609 Jan 07, 2023
AppQuickLauncher is a tool that can quickly launch apps by clicking the app tray icon.

AppQuickLauncher AppQuickLauncher is a tool that can quickly launch apps by clicking the app tray icon. On Windows 7 or Windows 10, we can add a folde

yin kaisheng 2 Sep 11, 2022