Skip to content

Instantly share code, notes, and snippets.

View bugduino's full-sized avatar

William Bergamo bugduino

View GitHub Profile
@bugduino
bugduino / components.expandable-table.js
Last active May 30, 2017 18:20
ember-light-table-issue
import Ember from 'ember';
import Table from 'ember-light-table';
const { computed, Component, get, set } = Ember;
export default Component.extend({
init() {
this._super(...arguments);
set(this, 'table', new Table(get(this, 'columns'), get(this, 'model')));

Keybase proof

I hereby claim:

  • I am bugduino on github.
  • I am bugman (https://keybase.io/bugman) on keybase.
  • I have a public key ASA7VfGDS05LQFjiQfr60KWCl-RfMQb4ZM8vzx4CWi3jvAo

To claim this, I am signing this object:

import paho.mqtt.client as paho
import RPi.GPIO as GPIO
import json, time
# device credentials
device_id = '<DEVICE_ID>' # * set your device id (will be the MQTT client username)
device_secret = '<DEVICE_SECRET>' # * set your device secret (will be the MQTT client password)
random_client_id = '<CLIENT_ID>' # * set a random client_id (max 23 char)
# -------------- #
#include <WiFi.h>
#include <PubSubClient.h>
#include <JsonParser.h>
using namespace ArduinoJson::Parser;
#define WIFI_SSID "XXX"
#define WIFI_PWD "XXXXX"
/* Properties of light type */
#define LIGHT_STATUS "54986537bbd5a45b84000001" // on || off

Keybase proof

I hereby claim:

  • I am giulyquinto on github.
  • I am bugman (https://keybase.io/bugman) on keybase.
  • I have a public key whose fingerprint is DA98 6477 73C5 7575 4F53 6B56 7433 A429 4941 196F

To claim this, I am signing this object:

epoch_to_YYYY-MM-DD (seconds) ->
if seconds != null
date = new Date(0)
date.setSeconds(seconds)
yyyy = date.getFullYear()
mm = date.getMonth() + 1
dd = date.getDate()
if dd < 10
dd = "0" + dd
if mm < 10
/*
Google Stock (GOOG) quotation on LCD
Arduino + Ethernet shield + LCD Screen
*/
// Include lib for Ethernet and LCD
#include <SPI.h>
#include <Ethernet.h>
#include <LiquidCrystal.h>