Skip to content

Instantly share code, notes, and snippets.

View tricky1.py
from mindstorms import MSHub, Motor, MotorPair, ColorSensor, DistanceSensor, App
from mindstorms.control import wait_for_seconds, wait_until, Timer
from mindstorms.operator import greater_than, greater_than_or_equal_to, less_than, less_than_or_equal_to, equal_to, not_equal_to
import math
# Create your objects here.
tricky = MSHub()
movement_motors = MotorPair('A','B')
distance_sensor = DistanceSensor('D')
View alarm.groovy
import groovy.json.JsonSlurper;
preferences {
section() {
input("integrateSHM", "boolean", title: "Integrate with SHM", description: "Whether to integrate this partition with Smart Home Monitor", required: true)
}
}
metadata {
definition (name: "DSC Alarm Partition", namespace: "TenStartups", author: "Marc Lennox") {
@marclennox
marclennox / docker-compose.yml
Last active Jun 26, 2020
Using PRY remote seamlessly in a Rails server
View docker-compose.yml
# config/docker-compose.yml
...
rails-web:
hostname: rails-web
env_file:
- application.env
environment:
- RAILS_ENV
- PORT=9292