Skip to content

Instantly share code, notes, and snippets.

View wecsam's full-sized avatar

David Tsai wecsam

View GitHub Profile
@darconeous
darconeous / tesla-key-card-protocol.md
Last active June 27, 2024 15:08
Tesla Key Card Protocol

Tesla Key Card Protocol

Researched by Robert Quattlebaum darco@deepdarc.com.

Last updated 2020-02-03.

Image of Tesla Key Card Image of Tesla Model 3 Key Fob

@austind
austind / Parse-CamTable.ps1
Created October 20, 2017 16:58
Parses CAM table output from a Cisco switch, adding IP address, hostname, and OUI vendor info from a Windows DHCP server (2012 R2+)
# Show all dynamic MACs, excluding the uplink trunk port
# Don't includer any header ouptput, only actual entries
# e.g., show mac address-table dynamic | ex Gi0/24
$ShMacAddrOutput = @"
1 0023.ae57.3df2 DYNAMIC Gi0/7
1 0023.aeaf.77b2 DYNAMIC Gi0/6
1 14b3.1f01.00e4 DYNAMIC Gi0/2
1 28b2.bd8e.5459 DYNAMIC Gi0/3
1 28f1.0e32.a204 DYNAMIC Gi0/1
1 2c76.8ac4.f7e5 DYNAMIC Gi0/3
// to compile (using mingw-w64)
// g++ this_filename.c -lole32
// outputs current system volume (out of 0-100) to stdout, ex: output "23"
// mostly gleaned from examples here: http://msdn.microsoft.com/en-us/library/windows/desktop/dd370839(v=vs.85).aspx
// download a compiled version here:
// https://sourceforge.net/projects/mplayer-edl/files/adjust_get_current_system_volume_vista_plus.exe.exe (updated, can set it too now!)
#include <windows.h>
#include <commctrl.h>
#include <mmdeviceapi.h>
#include <endpointvolume.h>