Skip to content

Instantly share code, notes, and snippets.

View nejdetckenobi's full-sized avatar

Nejdet Çağdaş Yücesoy nejdetckenobi

View GitHub Profile
@RomanKharin
RomanKharin / test_esp32_5110.py
Last active May 14, 2020 20:13
Test LCD 5110 (PCD8544) on esp32 (ESP-WROOM-32) with micropython (1.9.3)
# Test esp32 (ESP-WROOM-32) with nokia 5110 (pcd8544)
# https://github.com/mcauser/micropython-pcd8544/
# https://forum.micropython.org/viewtopic.php?t=4329
# pip install adafruit-ampy
# ampy -p /dev/ttyUSB0 put micropython-pcd8544/pcd8544.py
# ampy -p /dev/ttyUSB0 put test_esp32_5110.py
# shell screen /dev/ttyUSB0 115200
# PCD8544 -> ESP32-WROOM
@ferdiunal
ferdiunal / array2json.php
Last active June 27, 2023 00:54
Ülkelerin İl, İlçeleri. Şimdilik Türkiye'yi ekleyebildim.
#!/usr/bin/env php
<?php
/**
* @author Ferdi ÜNAL
* @email [email protected]
*/
$location = require "location.php";
$json = fopen('location.json', 'w');
#!/usr/bin/perl
#-----------------------------------------------------------------------------
#
# Copyright (C) 2011
# Michael Theall (mtheall)
# Dave Murphy (WinterMute)
#
# This software is provided 'as-is', without any express or implied
# warranty. In no event will the authors be held liable for any
# damages arising from the use of this software.
@eribeiro
eribeiro / gource-ffmpeg.sh
Last active February 11, 2022 16:23
Run Gource on a git repo, outputs as a movie (movie.mp4) and compresses it (output.mp4)
gource -s .06 -1280x720 --auto-skip-seconds .1 --multi-sampling --stop-at-end --key --highlight-users --hide mouse,progress,files,filenames,dirnames --file-idle-time 0 --max-files 0 --background-colour 000000 --font-size 22 --title "Lucene/Solr" --output-ppm-stream - --output-framerate 30 | avconv -y -r 30 -f image2pipe -vcodec ppm -i - -b 65536K movie.mp4
&& ffmpeg -i movie.mp4 -b:v 3048780 -vcodec libx264 -crf 24 output.mp4
@cgoldberg
cgoldberg / gource.sh
Created July 2, 2013 14:05
Gource - Mir development video
# install bzr and gource
# get a branch of Mir's trunk code
# create gource video
$ sudo apt-get install bzr gource
$ bzr branch lp:mir
$ cd mir
$ gource \
-s .06 \
@ebidel
ebidel / handle_file_upload.php
Created April 18, 2012 03:23
Uploading files using xhr.send(FormData) to PHP server
<?php
$fileName = $_FILES['afile']['name'];
$fileType = $_FILES['afile']['type'];
$fileContent = file_get_contents($_FILES['afile']['tmp_name']);
$dataUrl = 'data:' . $fileType . ';base64,' . base64_encode($fileContent);
$json = json_encode(array(
'name' => $fileName,
'type' => $fileType,
'dataUrl' => $dataUrl,
@tsabat
tsabat / zsh.md
Last active October 10, 2025 00:44
Getting oh-my-zsh to work in Ubuntu