Skip to content

Instantly share code, notes, and snippets.

@marcelrv
marcelrv / Onkyo_mount_Image.md
Last active November 25, 2023 12:12
Onkyo Firmware analysis / hacking
@marcelrv
marcelrv / SeaChartCreator.md
Last active December 10, 2020 07:55
Installing and creating mbtiles with SeaChartCreator

SeaChartCreator

git clone https://github.com/stevo01/SeaChartCreator.git
git clone https://github.com/stevo01/imgkap.git
@marcelrv
marcelrv / gist:013d721b303a60fcb4456ae20c72265c
Created December 3, 2020 09:38
VNC with default desktop on Ubuntu 20.04
https://www.teknotut.com/en/install-vnc-server-with-gnome-display-on-ubuntu-18-04/#Install_Gnome
Key:
nano ~/.vnc/xstartup
Then fill in the following code.
#!/bin/sh
@marcelrv
marcelrv / gist:6e3300cd5ac85af66ef2152d60539411
Last active September 15, 2023 10:11
miio powerstrip power settings
data: {"id":3552,"method":"set_lowpower_autooff","params":[{"lp_autooff":1,"lp_autooff_delay":5,"lp_threshold":2}]}
gateway
data: {"id":7765,"method":"get_device_prop_exp","params":[["lumi.158d0001e09bd","temperature","humidity","pressure"]]}
lamp uit
data: {"id":7482,"method":"set_rgb","params":[0]}
data: {"id":7481,"method":"get_prop","params":["rgb"]}
@marcelrv
marcelrv / python-miio.md
Last active March 31, 2020 09:59
Docker to run python-miio

nano Dockerfile add the following to it:

FROM python:3.8
#FROM python:3.7-alpine
RUN apt-get install  libffi-dev libssl-dev
#RUN apt add --no-cache  libffi-dev libssl-dev
RUN pip3 install python-miio
http://miot-spec.org/miot-spec-v2/instances?status=all
http://miot-spec.org/miot-spec-v2/instances?status=debug
http://miot-spec.org/miot-spec-v2/instances?status=released
and for example air purifier 3 cn (zhimi.airpurifier.ma4)
https://miot-spec.org/miot-spec-v2/instance?type=urn:miot-spec-v2:device:air-purifier:0000A007:zhimi-ma4:1
http://miot-spec.org/miot-spec-v2/instance?type=urn:miot-spec-v2:device:light:0000A001:philips-bulb:1
http://miot-spec.org/miot-spec-v2/instance?type=urn:miot-spec-v2:device:fan:0000A005:zhimi-sa1:1
@marcelrv
marcelrv / TSD build error.txt
Last active December 1, 2019 20:31
TSD build error
marcel@docker-server:~/TheSpaghettiDetective$ docker-compose --verbose up --build -d
compose.config.config.find: Using configuration files: ./docker-compose.yml
docker.utils.config.find_config_file: Trying paths: ['/home/marcel/.docker/config.json', '/home/marcel/.dockercfg']
docker.utils.config.find_config_file: Found file at path: /home/marcel/.docker/config.json
docker.auth.load_config: Couldn't find auth-related section ; attempting to interpret as auth-only file
docker.auth.parse_auth: Auth data for auths is absent. Client might be using a credentials store instead.
docker.auth.parse_auth: Auth data for HttpHeaders is absent. Client might be using a credentials store instead.
urllib3.connectionpool._make_request: http://localhost:None "GET /v1.35/version HTTP/1.1" 200 535
compose.cli.command.get_client: docker-compose version 1.24.1, build 4667896b
docker-py version: 3.7.3
@marcelrv
marcelrv / read.py
Last active July 15, 2019 18:48
Vaarkaarten
import urllib.request
import json
url = 'https://vaarweginformatie.nl/frp/api/webcontent/downloads?pageId=infra/enc'
req = urllib.request.Request(url)
##parsing response
r = urllib.request.urlopen(req).read()
cont = json.loads(r.decode('utf-8'))
counter = 0
print (cont)
@marcelrv
marcelrv / Bluez Install.txt
Created December 12, 2018 12:06
Installation Bluez 5.46 on Ubuntu 16.04
Based on https://askubuntu.com/questions/883713/using-bluez-5-43-on-ubuntu-16-04
sudo apt-get install debhelper dh-autoreconf flex bison libdbus-glib-1-dev libglib2.0-dev libcap-ng-dev libudev-dev libreadline-dev libical-dev check dh-systemd libebook1.2-dev devscripts
#unless you have already a gpg key
sudo apt-get install rng-tools
gpg --gen-key