Skip to content

Instantly share code, notes, and snippets.

@jmtatsch
jmtatsch / tesla_request_option_codes.py
Created March 24, 2019 20:10
How to query option codes via the Teslajson Api
import teslajson
user = "your_tesla_login@email.com"
password = "your_tesla_email"
c = teslajson.Connection(user, password)
for vehicle in c.vehicles:
print( "{} has the following options enabled: ".format(vehicle["display_name"]))
for option in vehicle["option_codes"].split(","):
print(option)
@jmtatsch
jmtatsch / gist:44e7c1a55fc29432254bdc61559d91c7
Last active April 12, 2018 05:10
ROS Kinetic on Sierra Work in Progress
# NOTE: These instructions do not represent a robust, self-troubleshooting install; they
# are definitely not suitable for dumping to a giant script and running as one. If you
# use them, they should be run one at a time, with an eye out for errors or problems
# along the way.
#
# The #1 issue you are likely to encounter is with Homebrew or Python packages whose
# binary components link against system Python. This will result in runtime segfaults,
# especially in rviz. If you suspect this is occurring, you can attempt to remove and
# reinstall the offending packages, or go for the nuclear option--- empty your Cellar
# and site-packages folders and start over with brewed python from the beginning.
@jmtatsch
jmtatsch / jupyter
Last active July 31, 2019 15:42 — forked from lambdalisue/jupyterhub
A service (init.d) script for jupyter
#! /bin/sh
### BEGIN INIT INFO
# Provides: jupyter
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Start jupyter
# Description: This file should be used to construct scripts to be
# placed in /etc/init.d.
@jmtatsch
jmtatsch / maxPerf.sh
Created January 8, 2016 19:51
Nvidia's Max Performance Script for Tegra X1
#!/bin/sh
# turn on fan for safety
echo "Enabling fan for safety..."
if [ ! -w /sys/kernel/debug/tegra_fan/target_pwm ] ; then
echo "Cannot set fan -- exiting..."
fi
echo 255 > /sys/kernel/debug/tegra_fan/target_pwm
echo 0 > /sys/devices/system/cpu/cpuquiet/tegra_cpuquiet/enable
@jmtatsch
jmtatsch / homebridge.service
Last active November 7, 2015 10:20
Homebridge service
[Unit]
Description=Start homebridge server
[Service]
Type=simple
ExecStart=/usr/bin/homebridge
[Install]
WantedBy=multi-user.target
@jmtatsch
jmtatsch / config.json
Last active October 24, 2015 10:43
config.json for fhem & homebridge
{
"bridge": {
"name": "Homebridge",
"username": "CC:22:3D:E3:CE:30",
"port": 51826,
"pin": "031-45-154"
},
"description": "This is an example configuration file with all supported devices. You can use this as a template for creating your own configuration file containing devices you actually own.",
@jmtatsch
jmtatsch / compile.log
Created October 16, 2015 19:59
Trouble compiling ogre1.9 on El Cap
This file has been truncated, but you can view the full file.
brew install https://raw.githubusercontent.com/jmtatsch/homebrew-simulation/master/ogre1.9.rb --devel -vv tatsch@JRetinaMacbookPro
/usr/bin/curl -fLA Homebrew 0.9.5 (Ruby 2.0.0-645; OS X 10.11) https://raw.githubusercontent.com/jmtatsch/homebrew-simulation/master/ogre1.9.rb -o /Library/Caches/Homebrew/Formula/ogre1.9.rb
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 3475 100 3475 0 0 3871 0 --:--:-- --:--:-- --:--:-- 3869
==> Downloading https://bitbucket.org/sinbad/ogre/get/v1-9.tar.bz2
Already downloaded: /Library/Caches/Homebrew/ogre1.9-1.9.1-devel.tar.bz2
==> Verifying ogre1.9-1.9.1-devel.tar.bz2 checksum
tar xf /Library/Caches/Homebrew/ogre1.9-1.9.1-devel.tar.bz2
==> Downloading https://gist.github.com/NikolausDemmel/2b11d1b49b35cd27a102/raw/bf4a4d16020821218f73db0d56aa111ab2fde679/fix-1.9-HEAD.diff
@jmtatsch
jmtatsch / telegram-daemon
Last active August 29, 2015 14:26
telegram-daemon
#! /bin/sh
### BEGIN INIT INFO
# Provides: telegram-daemon
# Required-Start:
# Required-Stop:
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: telegram daemon
# Description: telegram daemon
### END INIT INFO
@jmtatsch
jmtatsch / bw.launch
Created July 24, 2015 08:12
bw.launch
<launch>
<arg name="nodelet_manager_name" value="nodelet_manager" />
<arg name="camera_name" value="camera" />
<node pkg="nodelet" type="nodelet" name="$(arg nodelet_manager_name)" args="manager" output="screen" />
<node pkg="nodelet" type="nodelet" name="ueye_cam_nodelet"
args="load ueye_cam/ueye_cam_nodelet $(arg nodelet_manager_name)">
<param name="camera_name" type="str" value="$(arg camera_name)" /> <!-- == namespace for topics and services -->
<param name="camera_topic" type="str" value="image_raw" />
@jmtatsch
jmtatsch / setup.sh
Last active March 15, 2017 13:00 — forked from mikepurvis/gist:9837958
Install ROS Jade on OS X El Capitan
# NOTE: These instructions do not represent a robust, self-troubleshooting install; they
# are definitely not suitable for dumping to a giant script and running as one. If you
# use them, they should be run one at a time, with an eye out for errors or problems
# along the way.
#
# The #1 issue you are likely to encounter is with Homebrew or Python packages whose
# binary components link against system Python. This will result in runtime segfaults,
# especially in rviz. If you suspect this is occurring, you can attempt to remove and
# reinstall the offending packages, or go for the nuclear option--- empty your Cellar
# and site-packages folders and start over with brewed python from the beginning.