Skip to content

Instantly share code, notes, and snippets.

@ktemkin
ktemkin / maschine_mk3.md
Created May 18, 2023 00:26
Maschine Mk3 RE Notes

Display Format

The device has a "vendor defined interface" (5) with a single bulk OUT endpoint (4). This accepts commands that will set the screen value, with the following format:

Byte Meaning
0 const 0x84, command
1 const 0x00
2 screen number; 0 for left, 1 for right
3 const 0x60
@m0j0hn
m0j0hn / pwnagotchi notes
Created November 22, 2019 21:57 — forked from GermaniumSystem/pwnagotchi notes
How to set up a pwnagotchi in 25* simple steps.
Preface:
I have no idea if any of this is the "right" way of doing it. This is just how I got my unit working.
Good luck.
WARNING: Do not use a V1 Waveshare display module with a stock pwnagotchi! The pwnagotchi expects a V2 module, and may irreparably damage a V1 module!
A V1 display module *can* work, but you must modify `waveshare.py` and `display.py` beforehand. For the time being, this is left as an exercise for the reader.
If you have already burnt a V1 display, try disconnecting it from the Pi and leaving it overnight. This may rejuvenate the display somewhat, but it will likely still display signs of damage.
Installation:
1. `dd` Raspbian Lite to an SD card.
@blackcater
blackcater / diagrams.md
Created July 6, 2018 16:45
Markdown Diagrams

Diagrams

Markdown Preview Enhanced supports rendering flow charts, sequence diagrams, mermaid, PlantUML, WaveDrom, GraphViz, Vega & Vega-lite, Ditaa diagrams. You can also render TikZ, Python Matplotlib, Plotly and all sorts of other graphs and diagrams by using Code Chunk.

Please note that some diagrams don't work well with file exports such as PDF, pandoc, etc.

Flow Charts

This feature is powered by flowchart.js.

Favorites:
Unrefined:
!(@home|@$WIFE|@phone|@laptop|@desk|@errand|@office|##$EMPLOYER|##Someday/Maybe) & !search:* |
(no priority & !search:* & !recurring & !##Someday/Maybe) |
(!search:: & !##Someday/Maybe & !recurring & !no priority) |
##Inbox,
(##Someday/Maybe|@not_now) & (!no due date|@next)
Home:
@soywiz
soywiz / gradle_to_m2.kts
Created December 6, 2016 17:27
Copy gradle cache structure into local m2 folder structure
import java.io.File
import java.security.MessageDigest
val gradleBase = System.getenv("HOME") + "/.gradle/caches/modules-2/files-2.1"
val m2Base = System.getenv("HOME") + "/.m2/repository"
fun ByteArray.toHex() = this.map { "%02x".format(it) }.joinToString("")
operator fun File.get(name: String) = File(this, name)
for (groupFolder in File(gradleBase).listFiles().filter { it.isDirectory }) {
val group = groupFolder.name
http://stackoverflow.com/questions/6612344/prevent-unit-tests-in-maven-but-allow-integration-tests
The maven-failsafe-plugin is for running Integration Tests.
Integration Tests, according to Maven lifecycle definition, come after Unit Tests - and after packaging.
And the maven-failsafe-plugin provides hooks to call code to install those packages, and reliably spin-up and tear-down services used by the Integration Tests regardless of success/failure of the test.
This is something the maven-surefire-plugin Unit Test plugin does not do, as it expects all its operations to be wholly confined to the JVM
My intent in adding the maven-failsafe-plugin is to give us better control over our tests, and to provide an easy way to migrate slow, non-Unit Tests to a different test harness, to be run after Unit Tests have passed. Once the maven-failsafe-plugin is available, this is as simple as renaming tests from Test.java or *Test.java to IT.java or *IT.java. And I will note that there are already some tests which match th
@m0j0hn
m0j0hn / Maven Speedups.md
Last active July 12, 2016 17:53
Maven Speedups

Maven Speedups

There are several things one can do to speed up routine Maven builds - here is a non-exhaustive list of things to try - please let me know which ones work / don't work for you!

  • TODO: (multicore/multithread options!!!)

  • Prepare for offline mode: Tell Maven to download everything you depend on, so you can work offline.

@chinshr
chinshr / Jenkinsfile
Last active October 16, 2023 09:25
Best of Jenkinsfile, a collection of useful workflow scripts ready to be copied into your Jenkinsfile on a per use basis.
#!groovy
# Best of Jenkinsfile
# `Jenkinsfile` is a groovy script DSL for defining CI/CD workflows for Jenkins
node {
}
@shuffle2
shuffle2 / dbg.py
Created July 8, 2015 08:23
powersaves-amiibo-frida stuffs
'''
Input MD5 : BB4E83D7A77AADD7F62728314EF09461
File Name : C:\Program Files (x86)\Powersaves For AMIIBO\Powersaves For AMIIBO.exe
0x108fd0 : schannel_recv -> log buffer on end
0x1090d0 : schannel_recv end
0x108d10 : schannel_send -> log buffer on start
0xce61 : deals with https "Token"
0xceab : deals with https "Vuid"
@scottslowe
scottslowe / yaml-vagrantfile
Created October 21, 2014 21:16
This Vagrantfile works with an external data file (a YAML file, named servers.yaml) to create multiple Vagrant boxes easily. The servers.yaml file contains all the specifics and can be easily edited to change the number and type of boxes to create. The Vagrantfile remains unchanged.
# -*- mode: ruby -*-
# # vi: set ft=ruby :
# Specify minimum Vagrant version and Vagrant API version
Vagrant.require_version ">= 1.6.0"
VAGRANTFILE_API_VERSION = "2"
# Require YAML module
require 'yaml'