Skip to content

Instantly share code, notes, and snippets.

View azzlabs's full-sized avatar
Needs caffeine

Marco Azzari azzlabs

Needs caffeine
View GitHub Profile
@azzlabs
azzlabs / get_image.php
Last active February 16, 2021 18:03
Get a snapshot/still image from a Tmezon 7 inch doorbell network-enabled intercom
<?php
/*
By reverse-engineering a bit the web interface, I wrote this simple script to get a clean still of a Tmezon doorbell camera
This script has been tested with the old 720p version of this: https://www.tmezon.com/7-inch-ip-intercom-p0013.html
It outputs an inline image, so you can upload this page to a php server and curl it to get a nice image of the current view from your doorbell
As a bonus, notice that the doorbell password does not appear anywhere. NEAT :I
*/
// Basic token authentication
@azzlabs
azzlabs / cartella-tombola.js
Last active October 12, 2023 11:55
Genera una tabella della Tombola in JavaScript
class RandTools {
// Inizializza l'array interno sequenzialmente con interi
distRandInit (end, start = 0) {
this.dist_rand = [];
for (var i = start; i < end; i++) {
this.dist_rand.push(i);
}
}
// Ottiene casualmente un elemento dall'array e lo rimuove