Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
#based on this site http://thezanshow.com/electronics-tutorials/raspberry-pi/tutorial-30 | |
#Please run on your raspberry pi. | |
#This code is client side. | |
from time import sleep, time | |
from picamera import PiCamera | |
import socket | |
from io import BytesIO | |
PORT = 5560 | |
ADDRESS = "XXX.XXX.XXX.XXX"#server ip |
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 "MPU9250.h"//bolderflight/MPU9250 | |
// an MPU9250 object with the MPU-9250 sensor on I2C bus 0 with address 0x68 | |
MPU9250 IMU(Wire,0x68); | |
int status; | |
#define xao 0//value offsets | |
#define yao -0.33 | |
#define zao -2.05 | |
#define xmo -168 | |
#define ymo 6 |
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
//Calculate differential from coeffients | |
Complex[] differential(Complex ... coeffs){ | |
Complex[] result = new Complex[coeffs.length-1]; | |
for(int i=1; i<coeffs.length; i++){ | |
result[i-1] = coeffs[i].mult(i); | |
} | |
return result; | |
} |
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
import themidibus.*; | |
import javax.sound.midi.MidiMessage; | |
import javax.sound.midi.ShortMessage; | |
MidiBus myBus; // MidiBus | |
void setup() { | |
MidiBus.list(); //MIDI list | |
myBus = new MidiBus(this, 0, 4); //MIDI input,output |
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 <Adafruit_NeoPixel.h> | |
#define PIN 2 | |
#define NUMPIXELS 300 | |
#define DELAY 10 | |
const float briLen = 150;//length of lightning area | |
const float hueLen = 150;//length of hue cycle | |
float bri = 50;//=brightness/2 | |
const float briSpeed = 1;//brightness transition speed | |
const float hueSpeed = 1.1;//hue transition speed |
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
//based on this site (jp)https://sw1227.hatenablog.com/entry/2018/12/03/235105 | |
int n = 3; | |
int res = 50; | |
float a = 0; | |
float scale = 70; | |
void setup(){ | |
colorMode(HSB, 360, 100, 100); | |
size(500, 500, P3D); | |
} |
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 <Adafruit_NeoPixel.h> | |
#define PIN 2 | |
#define NUMPIXELS 300 | |
#define DELAY 10 | |
int frameCount = 0; | |
Adafruit_NeoPixel pixels(NUMPIXELS, PIN, NEO_GRB + NEO_KHZ800); | |
void setup() { | |
pixels.begin(); |
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 <Adafruit_NeoPixel.h> | |
#define PIN 2 | |
#define NUMPIXELS 300 | |
#define DELAY 1 | |
int frameCount = 0; | |
Adafruit_NeoPixel pixels(NUMPIXELS, PIN, NEO_GRB + NEO_KHZ800); | |
void setup() { | |
pixels.begin(); |