This file contains hidden or 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
| # ライブラリのインストール | |
| # gem install serialport | |
| require 'io/console' | |
| require 'serialport' | |
| sp = SerialPort.new('/dev/ttyS0', 9600, 8, 1, 0) # device, rate, data, stop, parity | |
| puts "Angle( C-c: exit )\n1. 0°\n2. 90°\n3. 180°" |
This file contains hidden or 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
| require 'io/console' | |
| puts "Angle( C-c: exit )\n1. 0°\n2. 90°\n3. 180°" | |
| while c = STDIN.getch | |
| exit if c == ?\C-c | |
| if c == "1" || c == "2" || c == "3" | |
| print c | |
| puts "\nAngle( C-c: exit )\n1. 0°\n2. 90°\n3. 180°" |
This file contains hidden or 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
| # ruby input_test.c | |
| require 'io/console' | |
| puts "Angle( C-c: exit )\n1. 0°\n2. 90°\n3. 180°" | |
| while c = STDIN.getch | |
| exit if c == ?\C-c | |
| print c |
This file contains hidden or 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
| ####################################### | |
| ## test draw 1dimmantion(6144) | |
| ####################################### | |
| def pic_1dimput(pic, width=128, height=48) | |
| for i in 0..height-1 do | |
| rawdim = [] | |
| for j in 0..width-1 do | |
| rawdim << ( (pic[ i*128 + j ] != 0) ? "$" : " " ) | |
| end | |
| rawdim << "\n" |
This file contains hidden or 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
| sudo bluetoothctl | |
| > scan on | |
| > scan off | |
| > exit | |
| sudo apt-get install dbus | |
| wget https://raw.githubusercontent.com/mk-fg/fgtk/master/bt-pan | |
| chmod +x bt-pan | |
| # sudo apt-get install python-pip |
This file contains hidden or 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 <WiFi.h> | |
| // Replace with your network credentials | |
| const char* ssid = "your SSID"; | |
| const char* password = "your PASS"; | |
| WiFiServer server(80); | |
| const int heat = 13; | |
| const int cooldown = 12; |
This file contains hidden or 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
| ssh [email protected] | |
| > raspberry | |
| sudo apt-get install bridge-utils -y --no-install-recommends | |
| > raspberry | |
| sudo emacs /etc/network/interfaces | |
| " | |
| auto br0 | |
| iface br0 inet dhcp | |
| bridge_ports eth0 wlan0 | |
| " |
This file contains hidden or 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
| ssh [email protected] | |
| > raspberry | |
| sudo apt-get update | |
| > raspberry | |
| sudo apt-get upgrade | |
| sudo useradd -M tmp | |
| sudo gpasswd -a tmp sudo | |
| sudo passwd tmp | |
| > a |
This file contains hidden or 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
| <table id="vote_system"> | |
| <thead> | |
| <tr> | |
| <th>名前</th> | |
| <th>得票数</th> | |
| <th></th> | |
| <th></th> | |
| </tr> | |
| </thead> | |
| <tbody></tbody> |
This file contains hidden or 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
| <?xml version="1.0" encoding="utf-8" ?> | |
| <package> | |
| <job> | |
| <runtime></runtime> | |
| <script language="JScript"> | |
| <![CDATA[ | |
| /****************************************************************************** | |
| ** | |
| ** now_playing_win.wsf | |
| ** Created by Takuya Noaki on 17/06/20. |