Download OpenCV:
$ export OPENCV_VERSION=3.4.3
$ git co opencv_contrib && cd opencv_contrib && git co $OPENCV_VERSION
$ git co opencv
$ cd opencv
$ git co $OPENCV_VERSION
$ mkdir build-arm
import numpy as np | |
import xarray as xr | |
import cv2 | |
import imageio | |
def to_rgb(data, vmin=None, vmax=None, size=None, pmin=2, pmax=98, mask=None): | |
if isinstance(data, list): | |
n_channels = len(data) | |
elif isinstance(data, xr.DataArray): |
Download OpenCV:
$ export OPENCV_VERSION=3.4.3
$ git co opencv_contrib && cd opencv_contrib && git co $OPENCV_VERSION
$ git co opencv
$ cd opencv
$ git co $OPENCV_VERSION
$ mkdir build-arm
$ wget --no-check-certificate -P /tmp http://flydata-rpm.s3-website-us-east-1.amazonaws.com/patchelf-0.8.tar.gz | |
$ tar xvf /tmp/patchelf-0.8.tar.gz -C /tmp | |
$ cd /tmp/patchelf-0.8 && ./configure && make && sudo make install | |
$ sudo yum install -y blas-devel boost-devel lapack-devel gcc-c++ cmake python-devel git | |
$ git clone https://github.com/davisking/dlib.git | |
$ cd dlib/python_examples/ | |
$ mkdir build && cd build | |
$ cmake -D USE_SSE4_INSTRUCTIONS:BOOL=ON ../../tools/python | |
$ cmake --build . --config Release --target install |
from django.db import connection | |
from django.core.management import call_command | |
cursor = connection.cursor() | |
cursor.execute("DROP SCHEMA public CASCADE;") | |
cursor.execute("CREATE SCHEMA public;") | |
call_command('migrate') |
$ apt-get install automake cmake | |
$ git clone -b 2.2 https://github.com/tmux/tmux /opt/tmux | |
$ cd /opt/tmux | |
$ sh autogen.sh | |
$ ./configure | |
$ make | |
$ /opt/tmux/tmux -V |
import RPi.GPIO as GPIO | |
import time | |
LED_PINS = (31, 33, 35, 37) | |
BUTTON_PIN = 29 | |
GPIO.setmode(GPIO.BOARD) # use board pin numbering | |
for i in LED_PINS: | |
GPIO.setup(i, GPIO.OUT) |
#include <propeller.h> | |
#include <stdlib.h> | |
#define STP1_PIN 19 | |
#define DIR1_PIN 18 | |
#define STP2_PIN 17 | |
#define DIR2_PIN 16 | |
#define STEP_DELAY 10 |
You can use Ubuntu configuration files from https://www.cactusvpn.com/downloads/ to setup OpenVPN.
How to setup OpenVPN client for CactusVPN:
/etc/init.d/openvpn start
or make it start at boot as /etc/init.d/openvpn enable
.You can also start OpenVPN client manually as follows:
/* | |
* Press button FORWARD_BUTTON_ID to drive forward/backward and BACKWARD_BUTTON_ID to drive backward/forward respectively. | |
* | |
* How to compile: | |
* $ propeller-elf-gcc -mlmm -std=c99 test_stepper_motor.c -o test_stepper_motor | |
* | |
* How to load (EEPROM) and run: | |
* $ propeller-load -r -e test_stepper_motor | |
*/ |
.PHONY: all clean | |
TARGET = test_stepper_motor | |
WRITE_TO_EEPROM ?= true | |
# See https://sites.google.com/site/propellergcc/documentation for details. | |
MEMORY_MODEL ?= lmm | |
BOARD = QUICKSTART |