#simple step for enable UART3 H3 allwinner sunxi
download suite sunxi:
git clone https://github.com/linux-sunxi/sunxi-tools
compile:
make
convert /boot/script.bin in .fex ascii file for editing:
./bin2fex /boot/script.bin ~script.fex
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
#include <iostream> | |
#include <unistd.h> | |
#include <thread> | |
#include <vector> | |
#include <signal.h> | |
#include <semaphore.h> | |
using namespace std; | |
vector<thread*> th; |
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
#include <ESP8266WiFi.h> | |
const char* ssid = "************"; | |
const char* password = "************"; | |
WiFiServer server(5055); | |
int pinLeft = 13; | |
int pinRight = 12; | |
bool ValLeft = false; |
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
#include <iostream> | |
#include <vector> | |
#include <string> | |
#include <sstream> | |
#include <stdio.h> | |
#include <regex> | |
#include <fstream> | |
#include <curl/curl.h> | |
void write_file(std::string p, std::string d) |
#A small guide to compile openFrameworks armv7 with driver OpenGL ES / ES2 sunxi for H3 / Mali GPU on ARMBIAN OS, compatible with orangepi and bananapi.
tested on: orangepi one banana pi M2
dependencies:
apt-get install libx11-dev libxext-dev xutils-dev libdrm-dev \
x11proto-xf86dri-dev libxfixes-dev x11proto-dri2-dev xserver-xorg-dev \
build-essential automake pkg-config libtool ca-certificates git cmake subversion
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
void drawFHOG(ofPixels store, int x, int y) | |
{ | |
ofPixels pix; | |
ofImage debug; | |
ofPushMatrix(); | |
array2d<matrix<float,31,1> > hog; | |
array2d<rgb_pixel> img; | |
toDLib(store,img);//<-- view ofxDLib |
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
/* | |
http://dlib.net/train_object_detector.cpp.html | |
Usage: | |
first step create positive train: | |
./bin/imglab_commandline positive/ "30,20,520,520" "person" | |
second step create negative train in append positive train previously created: |
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
#include <iostream> | |
#include "ofxGPIO.h" | |
#define OLED 0x3C | |
#define WIDTH_OLED 128 | |
#define HEIGHT_OLED 64 | |
int main(int argc, char *argv[]) | |
{ | |
if(argc > 2) |
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
/* | |
Rewritten Code by Keijiro Takahashi | |
source: | |
https://github.com/keijiro/sketches2016/blob/master/Moblur/Moblur.pde | |
*/ | |
#include "ofMain.h" |
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
class ofLogAudio : public ofThread{ | |
public: | |
bool startSpeak = false; | |
string msg; | |
string speak; | |
void start(string _c="/usr/bin/espeak -v mb-it3") | |
{ | |
speak = _c; | |
startThread(true); |