Skip to content

Instantly share code, notes, and snippets.

@yusukeyusuke
yusukeyusuke / wipeshader
Created March 31, 2019 14:04
オブジェクトサイズ単位でワイプするシェーダー
Shader "test/wipe" {
Properties{
_MainTex("Water Texture", 2D) = "blue" {}
}
SubShader{
Tags { "RenderType" = "Opaque" }
LOD 200
CGPROGRAM
#pragma surface surf Standard fullforwardshadows
#include <M5Stack.h>
int isRandomScreen = 0;
int isRandomMode = 0;
int colorMode = 0;
int colorChangeCounter = 0;
int COLORCHANGEWAIT = 80000;
int colorNumber[] = {BLACK, MAROON, RED, ORANGE, YELLOW, GREEN, BLUE, PURPLE, LIGHTGREY, WHITE};
int color[] = {0,0,0};
int screenColor[] = {-1,-1,-1};
#include <M5Stack.h>
#include <WiFi.h>
#include <time.h>
#include "AquesTalkTTS.h"
#include <WS2812FX.h>
#define LED_COUNT 24
#define LED_PIN 5
@yusukeyusuke
yusukeyusuke / main.py
Last active June 3, 2018 15:14
M5Stack(M5Cloud) MH-Z19
from m5stack import *
from machine import UART
import time
val = ''
lcd.setColor(lcd.BLACK, lcd.WHITE)
lcd.clear(lcd.WHITE)
uart2 = UART(2, tx=17, rx=16)
@yusukeyusuke
yusukeyusuke / android_configure.sh
Created November 17, 2017 06:21 — forked from nddrylliog/android_configure.sh
Cross-compile autotools library for Android / arm-linux-androideabi I stick that in ~/bin/, chmod +x, and then run it in place of "./configure" in my project. Then a make and make install later, the prefix contains libraries built for android. Neato eh?
#!/bin/sh
# I put all my dev stuff in here
export DEV_PREFIX=$HOME/Dev/
# Don't forget to adjust this to your NDK path
export ANDROID_NDK=${DEV_PREFIX}/android-ndk-r8d/
export CROSS_COMPILE=arm-linux-androideabi