Skip to content

Instantly share code, notes, and snippets.

@timurbakibayev
timurbakibayev / tetris.py
Last active March 18, 2025 19:22
Tetris game in Python
import pygame
import random
colors = [
(0, 0, 0),
(120, 37, 179),
(100, 179, 179),
(80, 34, 22),
(80, 134, 22),
(180, 34, 22),
@bitbank2
bitbank2 / arduino_perf.ino
Created June 27, 2020 22:49
An example of why it's important to know your target machine when writing software
//
// Arduino Perf
//
// This sketch is to show how much time it takes for the CPU to work
// with different variable types. Knowing that you're running on an
// 8-bit CPU vs a 32-bit CPU can have a huge effect on the performance
// of your code and your design choices. The Cortex-M4F has a hardware
// floating point unit, so integer versus float doesn't make much difference.
// while the AVR has to calculate floating point values using software and
// is much slower at it than integer calculations. It's also clear that the
@kianryan
kianryan / accel_demo.go
Created March 17, 2020 12:20
tinygo demo for BBC MicroBit using accelerometer and matrix display
package main
import (
"time"
"machine"
"image/color"
"tinygo.org/x/drivers/microbitmatrix"
"tinygo.org/x/drivers/mma8653"
)
@bushidocodes
bushidocodes / wasm-summit-2020-notes.md
Last active July 30, 2020 23:47
WebAssembly Summit 2020 Notes

WebAssembly Summit 2020

https://webassembly-summit.org/

Lin Clark's Talk - "WebAssembly Nanoprocess"

https://www.youtube.com/watch?v=IBZFJzGnBoU

  • the missing functionality alongside WASI and Interface Types is something that provides "capability-based security".
  • Delegation of permissions to propagate down transitive dependencies
  • plan to use fine-grain form of per-module virtualization
  • A "WebAssembly nanoprocess" is just wasm, but follows a particular pattern.
@zouppen
zouppen / README.md
Last active September 13, 2024 09:35
Push to talk microphone with Pulseaudio

Microphone PTT for Pulseaudio

This tool helps you with many absolutely proprietary software which doesn't include proper push-to-talk key. I wrote this with Google Meet in mind but is also useful for many other browser based apps as well.

It works so that when Caps Lock is held down, the microphone is unmuted. If you want to toggle it (for example during a demonstration), just press Ctrl + Caps Lock.

@IanColdwater
IanColdwater / twittermute.txt
Last active April 14, 2025 16:31
Here are some terms to mute on Twitter to clean your timeline up a bit.
Mute these words in your settings here: https://twitter.com/settings/muted_keywords
ActivityTweet
generic_activity_highlights
generic_activity_momentsbreaking
RankedOrganicTweet
suggest_activity
suggest_activity_feed
suggest_activity_highlights
suggest_activity_tweet
@monperrus
monperrus / README-anbox.Debian
Last active November 1, 2020 16:25
Content of /usr/share/doc/anbox/README.Debian
***** Latest version: https://salsa.debian.org/zhsj/anbox/blob/master/debian/README.Debian
Anbox for Debian
----------------
* Setup
In order to run Android system inside container, you need two kernel
modules: ashmem_linux and binder_linux. Since Debian kernel 4.17, these
two modules are enabled. You can find theme at,
@mlh758
mlh758 / go.mod
Last active June 19, 2019 20:32
Go Excelize Perf Test
module github.com/mlh758/exc_test
go 1.12
require github.com/360EntSecGroup-Skylar/excelize v1.4.1
@m1cr0lab
m1cr0lab / snake.py
Last active July 2, 2019 16:17
Learn to Code a Snake Game with CircuitPython on Gamebuino META
# ----------------------------------------------------------
# Learn to Code a Snake Game with Python
# Gamebuino Academy Workshop
# https://gamebuino.com/academy/workshop/learn-to-code-a-snake-game-with-python
# ----------------------------------------------------------
# This game is based on the CircuitPython environment, which
# is an implementation of the Python language specific to
# microcontrollers. CircuitPython runs on the SAMD21G18
# architecture of the Gamebuino META.
# ----------------------------------------------------------
@mamemomonga
mamemomonga / MCP2221A.md
Last active March 27, 2024 04:16
MCP2221Aメモ