Skip to content

Instantly share code, notes, and snippets.

@Chisight
Chisight / gist:cdad0c2e2f9a4165f1b86a47f29cf591
Last active February 22, 2025 18:10
Magic Home WiFi LED controller
Corrections to: https://github.com/Danielhiversen/flux_led/issues/53 for the newer Magic Home LED controller.
My Magic Home WiFi LED controller https://www.amazon.com/dp/B08GLSHJGS (non affiliate link) didn't work quite as described in the issue. It has a version identifier AK001-ZJ2145 which is different, so not surprising that it behaves differently. Some of the changes appear to be them actually fixing the well known security problems with these controllers, they're still not safe to put on the public Internet and still will respond with your wifi SSID and password with the following command:
echo -e "AT+WSKEY\r" | nc -u -v -w 3 $IP 48899; echo
I powered the controller up with 12VDC and scanned for new SSIDs. It came up as LEDnet003325A63A where the MAC address ends with 25A63A. I had used the above instructions and managed to soft-brick it so needed to reset to get back to a working state. These controllers no longer revert to AP mode if they can't connect (it was a security problem) so you have to fact
@Tucos
Tucos / buttonpress.c
Created August 4, 2014 19:17
Clickable conky thingies
/* Compile with `make CFLAGS='-std=c99' LOADLIBES='-lX11' buttonpress` */
#include <X11/Xlib.h>
#include <stdio.h>
#include <stdbool.h>
#include <stdlib.h>
Window GetWindowFromID(Display *display, Window start, int targetid, int level) {
Window root, parent, *children;
unsigned int nchildren;
@wxg4net
wxg4net / conky-cairo-imlib2
Created October 29, 2013 07:46
paint images in conky
require 'cairo'
require 'imlib2'
--~ require 'cairo_imlib2_helper'
--~ cairo_draw_image('/home/Data/pictres/500px/18.jpg' , cs, 0, 0, 0.2, 0.2)
function conky_images()
if conky_window == nil then return end
local sw = conky_window.width
local sh = conky_window.height
local cs = cairo_xlib_surface_create(conky_window.display, conky_window.drawable, conky_window.visual, sw, sh)