Skip to content

Instantly share code, notes, and snippets.

View dennisheitmann's full-sized avatar
👍
Having fun!

Dennis Heitmann dennisheitmann

👍
Having fun!
View GitHub Profile
@dennisheitmann
dennisheitmann / sma.py
Last active May 29, 2024 15:24
SMA Sunny Tripower 6.0 Modbus TCP Information to InfluxDB
#!/usr/bin/python
# -*- coding: utf-8 -*-
# @module: sma.py
# @description: Python Class to get data from a SMA unit via pymodbusTCP
# Clase Python para tomar datos de un equipo SMA utilizando pymodbusTCP
# @autor: Pac0 Arriaza (JanusHL) (except indicated...)
# @created: 20/05/2019
# @license: free use of this module class if no changes in the copyright from the autors are made.
#
@dennisheitmann
dennisheitmann / ping2excel.py
Last active August 22, 2022 07:18
Ping servers and save information in Excel-Sheet
# MIT License
#
# Copyright (c) 2022 Dennis Heitmann
import sys
import time
import datetime
import socks
import socket
from icmplib import ping
@dennisheitmann
dennisheitmann / ping2mqtt.py
Last active February 14, 2022 21:52
PING statistics to MQTT
# MIT License
#
# Copyright (c) 2022 Dennis Heitmann
from icmplib import ping
import paho.mqtt.client
pingHosts = ['192.168.15.194', '192.168.57.111']
mqttServer = '__SERVER__'
@dennisheitmann
dennisheitmann / viessmann-to-influxdb.py
Last active July 5, 2023 06:51
Viessmann API to InfluxDB (using PyViCare)
# MIT License
#
# Copyright (c) 2022 Dennis Heitmann
import sys
import logging
import datetime
from PyViCare.PyViCare import PyViCare
from influxdb import InfluxDBClient
@dennisheitmann
dennisheitmann / lambda_function.py
Created June 7, 2021 08:33
Check own MQTT server using AWS lambda and send alarm messages using AWS SNS in case of failure
"""
Check if own MQTT server runs
"""
import json
import paho
import boto3
import paho.mqtt.client as mqtt
import ssl
import time
import os
@dennisheitmann
dennisheitmann / funnyCharacters.py
Last active February 14, 2022 21:53
Funny Characters (ƒυתתу ¢нαяα¢τєяѕ)
# MIT License
#
# Copyright (c) 2021 Dennis Heitmann
import sys
def funnyCharacters(inputtext=""):
linput = inputtext.lower()
def convertChar(inputchar):
mapping = {'a': 'α', 'b': 'в', 'c': '¢', 'd': '∂', 'e': 'є', 'f': 'ƒ', 'g': 'g', 'h': 'н', 'i': 'ι', 'j': 'נ', 'k': 'к', 'l': 'ℓ', 'm': 'м',
@dennisheitmann
dennisheitmann / tuya-power.py
Last active February 14, 2022 21:54
Tuya Power Socket: Get Voltage and Switch Power (on/off)
#!/usr/bin/python3
#
# MIT License
#
# Copyright (c) 2021 Dennis Heitmann
import sys
import json
import hmac
import hashlib
@dennisheitmann
dennisheitmann / corona_rolling.ipynb
Last active April 2, 2022 07:42
Corona_Rolling.ipynb
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
#include <WiFi.h>
#include <ESPmDNS.h>
#include <WiFiUdp.h>
#include <ArduinoOTA.h>
int ota_once = 0;
#define HOSTNAME "ESP32TemplateSketch"
#include <IotWebConf.h>
#include <ESP8266WiFi.h>
#include <ESP8266mDNS.h>
#include <DNSServer.h>
#include <ESP8266WebServer.h>
#include <WiFiManager.h>
#include <WiFiUdp.h>
#include <ArduinoOTA.h>
//#define LED_BUILTIN 2
//unsigned long previousMillis = 0;