search was done on 21.06.22, updated on 20.09.22
I used pictures for reference, picture-less connectors were not investigated
#include <Wire.h> | |
class LCDI2C4Bit { | |
public: | |
LCDI2C4Bit(int devI2CAddress, int num_lines, int lcdwidth); | |
void commandWrite(int command); | |
void init(); | |
void print(int value); | |
void printIn(char value[]); | |
void clear(); |
#!/usr/bin/env python | |
import os | |
import sys | |
import web | |
web.config.debug = False | |
from web import database | |
BASEPATH = "/home/user/Scans" | |
DIR = "/var/lib/pybssort/" | |
DB_NAME = os.path.join(DIR, "pybssort.db") |
#!/bin/bash | |
#NAT script from !!!!!!!!!!!!!!!, modified by CRImier | |
# Exit status 0 if operation is correct | |
# Exit status 1 if trying to use last interface used when running for the first time | |
# Exit status 2 if interface doesn't exist | |
EIF='' | |
IIF='eth0' | |
PATH=/usr/sbin:/sbin:/bin:/usr/bin | |
LOGFILE=/etc/nat-if.conf | |
touch $LOGFILE |
import csv | |
f = open("statement.csv", "r", encoding="iso8859_13") | |
#def reencode(file): | |
# for line in file: | |
# yield line.decode('iso8859_13').encode('utf-8') | |
r = csv.reader(f, delimiter=";", quotechar='"') | |
l = [line for line in r] |
# This code is available on 192.168.88. :8000 (you can download it using your web browser) | |
# All examples are written to work on Python 3 | |
######################################################### | |
# Basic syntax, "while" and "if" | |
######################################################### | |
# REPL works well as a simple calculator | |
2+2*2 | |
# Answer: 6 |
def hexdump(data=None, col_width=16): | |
#This function follows the i2cdump output format, as it's the most readable out there | |
if data is None: data = d | |
# character conversion function | |
conv = lambda x: chr(x) if x in range(0x20, 0x7f) else '.' | |
# getting row count | |
row_count = ceil(len(data)/col_width) | |
max_row_num_len_hex = len(hex(row_count)[2:]) | |
# first line - header | |
hex_digits = [hex(i)[2:] for i in range(16)] |
import os | |
import shutil | |
directory_name = "playlist/" | |
playlist_name = "playlist.m3u" | |
f = open(playlist_name, "r") | |
files = [] | |
for line in f: | |
line = line.strip().strip("\n").strip("\r") |
#!/usr/bin/sudo /usr/bin/python3 | |
from evdev import InputDevice, list_devices, categorize, ecodes | |
from time import sleep | |
import threading | |
def listen_for_events(dev): | |
for event in dev.read_loop(): | |
#if event.type == ecodes.EV_KEY: | |
print (dev.name, ": ", str(categorize(event))) |
search was done on 21.06.22, updated on 20.09.22
I used pictures for reference, picture-less connectors were not investigated