Skip to content

Instantly share code, notes, and snippets.

S57 END conversion

How to convert an electronic navigational chart to map tiles and how to use them to update OSM data.

I will describe the procdure I used to update the buoys in the Waddenzee. The necessary commands are stored in the makefile, which is in the ZIP with all other resources.

  1. download ENC from https://www.vaarweginformatie.nl/frp/main/#/page/infra_enc
  2. extract the ZIP make unzip
  3. convert the ENC to shape files with ogr2ogr make waddenzee
  4. open them in QGIS using waddenzee.qgs
@quantenschaum
quantenschaum / tile_proxy.py
Last active August 25, 2020 13:44
simple tile proxy for osmand allowing to use quadkey named tiles
#!/usr/bin/env python3
from flask import Flask, abort, send_file, request
from mercantile import quadkey
from requests import get
from os import makedirs
from os.path import isfile, join, dirname
cache_dir = 'cache'
# https://www.genesismaps.com/SocialMap/Index
@quantenschaum
quantenschaum / Python and other stuff.md
Last active March 26, 2019 20:27
Python and other cool stuff

Python

Python is great - Batteries included! 🐍

implementations and extensions

  • CPython - the reference
  • IronPython - for the .NET Framework
  • PyPy - alternative implementation with JIT
  • Jython - Python running on Java VM
@quantenschaum
quantenschaum / ausweisapp2.sh
Created August 8, 2018 09:33
create appimage of ausweisapp2
#!/bin/bash -e
DIR="$(pwd)"
APP="$DIR/AusweisApp2"
TOOLS="$APP-Tools"
BUILD="$APP-Build"
IMAGE="$APP-Image"
git clone https://github.com/Governikus/AusweisApp2.git $APP
@quantenschaum
quantenschaum / make-software.md
Last active June 4, 2018 12:37
my little guide on how to get started with writing software

Start to make software

  1. Use english language, because it's the language of the international community. There is more useful stuff out there in english than in any other language.
  2. Google is your friend! Have a question? Try googling it!

I don't want to give full explanations here, it's just a set of hints and enrty points to get you started.

There are many links in this document. Follow them and read, read, read ...

Open Source Software

@quantenschaum
quantenschaum / backup.sh
Created April 15, 2018 18:55
borg backup cron script
#!/bin/bash -e
if [[ $# < 2 ]]; then
echo "usage: backup REPO check | list | PREFIX SRC [--force] [borg_opts]"
exit
fi
if [[ "$USER" != "root" ]]; then
exec sudo -H systemd-inhibit "$0" "$@"
fi
@quantenschaum
quantenschaum / kodi-setup.sh
Last active December 19, 2023 17:08
install script for kodi standalone mediacenter
#!/bin/bash
# prepare a Ubuntu server minimal installation with working network using network manager
# this works on raspbian, too
apt-get install software-properties-common -y
# install KODI
add-apt-repository ppa:team-xbmc/ppa -y
apt-get update && apt-get install -y kodi xserver-xorg xinit dbus-x11 alsa-utils avahi-daemon
@quantenschaum
quantenschaum / default.conf
Created January 7, 2018 17:02
nginx default config
server {
listen 80 default_server;
server_name _;
# For Lets Encrypt, this needs to be served via HTTP
location /.well-known/acme-challenge/ {
root /var/www/html; # Specify here where the challenge file is placed
}
# enforce https