Skip to content

Instantly share code, notes, and snippets.

View amikhalev's full-sized avatar

Alex Mikhalev amikhalev

View GitHub Profile
repositories:
angles:
type: git
url: https://github.com/ros/angles.git
version: ros2
diagnostics:
type: git
url: https://github.com/ros/diagnostics.git
version: ros2-devel
geographic_info:
@amikhalev
amikhalev / opkg-upgrade.sh
Created August 31, 2018 01:02
opkg-upgade.sh
#! /bin/sh
# Write a list of packages currently installed or read that list,
# presumably after a firmware upgrade, in order to reinstall all packages
# on that list not currently installed
#
# (c) 2013 Malte Forkel <malte.forkel@berlin.de>
#
# Version history
# 0.2.1 - fixed typo in awk script for dependency detection
# needs to be filled out
regions = { "north": [ "WA" ], "east": [ "MA" ] }
def state_to_region(state):
for region_name, region_states in regions.items():
if state in region_states:
return region_name
return "unknown region"
dataframe["region"] = dataframe["state"].apply(state_to_region)
atom settings
#!/usr/bin/env bash
set -e
shopt -s nullglob
shopt -s globstar
shopt -s dotglob
# Load environment variables from .env file
export $(cat .env | xargs)
#include <Commands/ToggleOutput.h>
#include "WPILib.h"
#include "Commands/Command.h"
#include "CommandBase.h"
class Robot: public IterativeRobot {
private:
// Normally this would be stored in a subsystem class, and there would be
// a function on the class that could toggle the output, but for simplicity
// it is just stored in Robot.
We can make this file beautiful and searchable if this error is corrected: Unclosed quoted field in line 4.
"Calgary, AB Canada",August Electronics / International Society of Automation / General Electric / Qsine Corporation Limited & Bishop Carroll High School & Alberta Tech Alliance Association,4334
"Flagstaff, AZ USA",Science Foundation Arizona / Phoenix Analysis & Design Technologies / APS & Phoenix Suns STEM Mini Grant / GKC Geoscience LLC / WL Gore & Associates / Northern Arizona University / AZ Superbowl Planning Committee STEM Super Hero Award / Arizona FIRST / Arizona Tax Credit Donations / Flagstaff Unified School District #1 & COCONINO HIGH SCHOOL,2486
"Cupertino, CA USA",IBM / Platt Electric Supply / Brin-Wojcicki Foundation / Qualcomm / Western Digital / BAE Systems / De Anza College Machine Shop / Pinnacle Manufacturing / Intel / VMware / Teco Pneumatic / Google / Lockheed Martin / Fremont Union High School Foundation / Symantec Corporation / Intuitive Surgical / EMC2 & MONTA VISTA HIGH,115
"Los Angeles, CA USA","Milken Community School/Mitchell Academy of Science and Technology/Jay Manufacturing Corp
0:
1: WhenPressed MessageCommandOne
2:
- WhenPressed MessageCommandOne
- WhenReleased MessageCommandTwo
template<T>
void AddCommand() {
std::string name = T::GetName();
YAML::Node config = commands[name];
if (config.IsSequence) {
for (auto node : config) {
commands[name + node[name]] = new T(node);
}
} else if (config.IsObject()) {
commands[name] = new T(config);
sudo add-apt-repository ppa:byteit101/frc-toolchain
sudo apt-get update
sudo apt-get -y install frc-toolchain git mercurial libboost-dev
ln -s /usr/include/boost /usr/arm-frc-linux-gnueabi/include
hg clone https://code.google.com/p/yaml-cpp/
mkdir yaml-cpp/build
cd yaml-cpp/build
frcmake ..
make yaml-cpp