Skip to content

Instantly share code, notes, and snippets.

curl https://apitest.vrsinfo.de:4443/trias -H 'Content-Type: text/xml' -d @trias-stop.xml -v
@noerw
noerw / drop-revisions.js
Created April 18, 2021 21:06
etherpad-lite: drop version history of old pads
#!/bin/env node
const fetch = require('node-fetch')
const { toQueryString } = require('@norwin/javascript-is-bad')
async function etherRequest (instance, func, apikey, params = {}) {
const query = toQueryString(params)
const url = `${instance}/api/1.2.15/${func}?apikey=${apikey}&${query}`
const response = await fetch(url)
if (response.status !== 200)
@noerw
noerw / covid-test-karte-nrw.geojson
Last active November 5, 2020 08:52
Corona Testende Arztpraxen NRW
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@noerw
noerw / gefaehrliche_kreuzungen_2019.json
Last active August 11, 2020 16:33
Straßenkreuzungen in DE mit 6 oder mehr Radunfällen in 2019. (Kann bspw als Routing-Filter für OpenRouteService.org genutzt werden)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@noerw
noerw / leipsch.geojson
Last active June 21, 2020 16:33
Kayaking in Leipzig
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@noerw
noerw / meckpomm.geojson
Last active July 4, 2019 20:23
Kayaking related POI in MeckPomm
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#!/usr/bin/env bash
# export OSEM_BOX=yourboxid
BOX=${OSEM_BOX:-5b26181b1fef04001b69093c}
API="https://api.opensensemap.org"
boxMeta=`curl "${API}/boxes/${BOX}"`
sensors=`curl "${API}/boxes/${BOX}/sensors"`
updated=`echo $boxMeta | jq -r '.lastMeasurementAt'`
weblink=`echo $boxMeta | jq -r '.weblink'`
@noerw
noerw / all_osem_faulty_sensors.md
Last active February 11, 2019 12:01
opensensemap.org faulty sensors

checked measurement_faulty for all boxes via https://github.com/noerw/osem_notify.

Note that many boxes show up because SDS011 reads 0.0. Looking at these boxes, the value fluctuates between 0 and 0.3 for a lot of sensors. Not sure if these are valid measurements, or the sensor is broken!

Note that only sensors HDC1008, BMP280 and SDS 011 are checked!

Check summary:

{
@noerw
noerw / plasmakreis.frag
Last active October 19, 2018 11:20
animating a glowing colorful circle (first shader, for glslViewer)
#define ROTATION_PERIOD 0.22
#define BEAM_RADIUS 0.72
#define BEAM_WIDTH 1.2
#define BEAM_PERIOD 0.1667
#define RIPPLE_COUNT 30.0
#define RIPPLE_INTENSITY 0.06
#define RIPPLE_PERIOD 0.5
#define FILL_INTENSITY 0.3 // !!!
#define FILL_PERIOD 0.2