This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
import socket | |
import threading | |
import logging | |
import mraa | |
# change this to the values from MCS web console | |
DEVICE_INFO = { | |
'device_id' : 'YOUR_DEVICE_ID', | |
'device_key' : 'YOUR_DEVICE_KEY' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* grove_ds18b20.cpp | |
* | |
* Copyright (c) 2012 seeed technology inc. | |
* Website : www.seeed.cc | |
* Author : Kai | |
* | |
* The MIT License (MIT) | |
* | |
* Permission is hereby granted, free of charge, to any person obtaining a copy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SYSTEM_MODE(SEMI_AUTOMATIC); | |
#define PIN_POWER A7 //Pin 1 on LCD | |
#define PIN_SCE A2 //Pin 3 on LCD | |
#define PIN_RESET A0 //Pin 4 on LCD | |
#define PIN_DC A1 //Pin 5 on LCD | |
#define PIN_SDIN A5 //Pin 6 on LCD | |
#define PIN_SCLK A3 //Pin 7 on LCD | |
#define PIN_LED D0 //Pin 8 on LCD |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
#!/usr/bin/python | |
import subprocess | |
import os | |
import picamera | |
import time | |
import shlex | |
from datetime import datetime | |
from datetime import timedelta | |
import datetime as dt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sys | |
import time | |
import csv | |
import sqlite3 | |
from google.appengine.datastore import entity_pb | |
from google.appengine.api import datastore |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from flask import Flask, render_template, request, jsonify | |
# Initialize the Flask application | |
app = Flask(__name__) | |
import pigpio | |
pi = pigpio.pi() # Connect to local Pi. | |
# Motor PINs |
NewerOlder