Skip to content

Instantly share code, notes, and snippets.

View aschmelyun's full-sized avatar
Building something fun!

Andrew Schmelyun aschmelyun

Building something fun!
View GitHub Profile
const int ledPin = 0;// the number of the LED pin
// Variables will change :
int ledState = LOW; // ledState used to set the LED
// Generally, you should use "unsigned long" for variables that hold time
// The value will quickly become too large for an int to store
unsigned long previousMillis = 0; // will store last time LED was updated
// constants won't change :
@aschmelyun
aschmelyun / index.php
Created October 1, 2015 19:01
Convert .png images to HTML divs
<?php
$img = imagecreatefrompng('test.png');
$img_width = imagesx($img);
$img_height = imagesy($img);
?>
<!DOCTYPE html>
<html lang="en">
<head>
<title>Convert useless images to beautiful HTML!</title>
<style>
@aschmelyun
aschmelyun / gist:676efeac78a0ceeaf00c
Created May 11, 2015 20:21
Flattastic Palette SCSS Variables
$grapefruit: #ED5565;
$grapefruit-alt: #DA4453;
$bittersweet: #FC6E51;
$bittersweet-alt: #E9573F;
$sunflower: #FFCE54;
$sunflower-alt: #FCBB42;
$grass: #A0D468;