This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# use the latest ubuntu environment (18.04) available on travis | |
dist: xenial | |
language: go | |
# Force-enable Go modules. Also force go to use the code in vendor/ | |
# These will both be unnecessary when Go 1.13 lands. | |
env: | |
- GO111MODULE=on | |
- GOFLAGS='-mod vendor' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
""" | |
Get reading from Nova PM Sensor SDS011 | |
(dust sensor, air quality sensor, PM10, PM2,5) | |
Designed to run from cron and append CSV file. | |
Script tested using Python3.4 on Ubuntu 14.04. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# -*- coding: utf-8 -*- | |
## 2019, Felix Niederwanger | |
## My matplotlib skeleton code for creating a plot based on CSV | |
## This python script reads in a CSV file with an arbitrary number of columns | |
## and creates a matplotlib plot out of it | |
## In the CSV file, the following parameters can be set: | |
## | |
## :title = STRING Set plot title |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <sys/time.h> | |
long long system_ms() { | |
struct timeval te; | |
gettimeofday(&te, NULL); // get current time | |
long long milliseconds = te.tv_sec*1000LL + te.tv_usec/1000; | |
return milliseconds; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Configuration file reader | |
* 2018, Felix Niederwanger | |
*/ | |
#include <string> | |
#include <fstream> | |
#include <map> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
from Crypto.Cipher import AES | |
key = "00000000aaaaaaaa00000000aaaaaaaa" | |
iv = "0000000000000000" | |
message = "A really secret message. Not for prying eyes." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This script changes my wallpepr to a random picture from my unsplash 'Landscape' collection in MATE | |
# 2018, phoenix, WTFPL Licence (http://www.wtfpl.net/) | |
COLLECTION="1356987" ## Or select your own collection id (must be public) | |
RESOLUTION="1366x768" ## Set to the resolution of your screen | |
cd /tmp | |
FILE="$HOME/Pictures/wallpaper.jpg" | |
#echo "Downloading picture ... " |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package cat; | |
import java.io.Closeable; | |
import java.io.EOFException; | |
import java.io.IOException; | |
import java.io.InputStream; | |
import java.io.OutputStream; | |
import java.io.PrintWriter; | |
import java.net.Socket; | |
import java.net.UnknownHostException; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# -*- coding: utf-8 -*- | |
# Python script for downloading the current GARMIN maps | |
import os | |
import requests | |
import random | |
import string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
##### hostapd configuration file ############################################## | |
# Empty lines and lines starting with # are ignored | |
# AP netdevice name (without 'ap' postfix, i.e., wlan0 uses wlan0ap for | |
# management frames with the Host AP driver); wlan0 with many nl80211 drivers | |
# Note: This attribute can be overridden by the values supplied with the '-i' | |
# command line parameter. | |
interface=wlan0 | |
# In case of atheros and nl80211 driver interfaces, an additional |