Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
RPi-and-restroom
Search
fukayatsu
January 15, 2014
Technology
360
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
RPi-and-restroom
Check restroom is occupied/vacant using Raspberry Pi
fukayatsu
January 15, 2014
More Decks by fukayatsu
See All by fukayatsu
esaを支える技術と気持ち
fukayatsu
7
3.1k
esa.ioの育て方
fukayatsu
28
9.2k
[WIP] esa.io、その後の話
fukayatsu
19
6.7k
esaを支える睡眠を支える技術
fukayatsu
18
6.7k
esa.io - 趣味から育てたWebサービスで生きていく
fukayatsu
62
61k
esa-kai
fukayatsu
1
420
あなたの知らないesa
fukayatsu
0
390
楽しいesaの作り方
fukayatsu
0
330
tqrk07-fukayatsu.pdf
fukayatsu
3
510
Other Decks in Technology
See All in Technology
iOSDC Japan 2026 day1 TrackC 10:50
feedtailor
1
160
beyond jj: config & tools ecosystem
indirect
0
460
白金鉱業Meetup Vol.25 アウトカムが二値のデータに対するCausal Impact
brainpadpr
0
210
AI時代の「技術的負債」の変質ー概念の終焉と再解釈、エージェントと共に向かう先
nwiizo
0
2.7k
Genieを崇めよ
kameitomohiro
0
140
Minecraft JavaのMODをSwiftで作る
1mash0
0
170
積み重なった技術負債への挑戦 〜初手としての全社ゴト化〜
techtekt
PRO
0
1.2k
SREは、MCPとAutopilotをこう使え!
kazumax55
2
830
ADKで始める業務改善 - AIエージェント開発時の考えと設計
harappa80
2
150
[2026-09-11]SREは誰のもの?運用エンジニアが始める 「SRE領域への越境」とチームの進化の軌跡 〜Road to NEXT CRE
tosite
0
280
2026-09-11 【Snowflake World Tour Tokyo 2026】Snowflakeを起点に、AI Agentが自律稼働し続ける未来へ / Driving AI Agents with Snowflake
civitaspo
0
610
AI時代、データエンジニアが一番おもろい
genshun9
0
620
Featured
See All Featured
SEO Brein meetup: CTRL+C is not how to scale international SEO
lindahogenes
2
2.9k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
508
140k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
250
1.3M
GraphQLの誤解/rethinking-graphql
sonatard
75
12k
Building Applications with DynamoDB
mza
96
7.2k
Heart Work Chapter 1 - Part 1
lfama
PRO
10
36k
HU Berlin: Industrial-Strength Natural Language Processing with spaCy and Prodigy
inesmontani
PRO
0
700
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
670
Leo the Paperboy
mayatellez
10
2.3k
Pawsitive SEO: Lessons from My Dog (and Many Mistakes) on Thriving as a Consultant in the Age of AI
davidcarrasco
0
240
Taking LLMs out of the black box: A practical guide to human-in-the-loop distillation
inesmontani
PRO
3
2.4k
Paper Plane (Part 1)
katiecoart
PRO
2
11k
Transcript
PRi on Toilet @fukayatsu
ઌिʹΑ͏͘ RPiΛ࢝Ί·ͨ͠ RPi = Raspberry Pi
ͱ͜ΖͰɺ
ฐࣾΦϑΟεͷ
τΠϨ͕ࠞΜͰΔ • ϑϩΞͷஉੑ10ਓʹରͯ͠τΠϨ1͚ͭͩɻ • ͦΕҎ֎ͩͱ֎ͷίϯϏχͷτΠϨΛआΓΔ͙ Β͍͔͠ͳ͍ɻ • ԿճτΠϨΛ֬ೝ͠ʹߦ͘ͷ͕໘͍͘͞ɻ
ͦ͜Ͱɺ
None
None
͜ΕԿʁ • RPi + ֎ઢηϯα + Wifiυϯάϧ • τΠϨ͕༻த͔Ͳ͏͔Λఆظతʹαʔόૹ৴
None
ࡢ͔ΒՔಇத http://ucchusma.herokuapp.com/api/v1/rooms/1
γεςϜશମ૾
RPi্ͷεΫϦϓτ • cat /sys/class/gpio/gpio4/value • => 1 (͍Δ) or 0
(͍ͳ͍) • ্هͷ݁ՌΛఆظతʹAPIαʔόʹૹ৴(Ruby) • ࣮ࡍʹۙ30ඵؒͰ5ඵҎ্Ԡͨ͠߹ ʹ”༻த”ͱஅ
APIαʔό • on Heroku • Sinatra + Grape + Redis
• /api/v1/rooms/1ʹରͯ͠GETɾPUTΛڐՄ • PUT࣌token͕ඞཁ
Chrome ֦ு • ఆظతʹAPIΛνΣοΫͯ͠ΞΠίϯΛม͑Δ
before & after • ಋೖલ • ʮ͏ʔτΠϨτΠϨʯ=>ʮ͋ɺ༻த͔…ʯ => ʮ·ͨޙͰདྷΑ͏ʯ=> ޙ࠷ॳʹΔ
• ಋೖޙ • ʮ͓ɺτΠϨۭ͍ͨͳɻʯ=> ʮ;͎…ʯ
RPiΛ͍͡Δ࣌ͷTips • δϟϯύϫΠϠ(Φε-ϝε)͕͋Δͱศར • GPIOͷinput5VͰͳ͘3.3V • ৄ͘͠blogͰʂ • blog.fukayatsu.com/2014/01/12/rest-room-api/
࣍ճ࡞ • ΦϑΟεͷΠϯλʔϗϯతͳͭ • ϘλϯΛԡͨ͠Βࣸਅ͖Ͱhipchatʹ௨ • ͍ͭͰʹTweet͢ΔϘλϯ͕͍͍͋ͬͯ • ిݯͷऔΓճ͕͠ωοΫ
ײ • ϋϯμָ͚͍͠ • Rubyָ͍͠ • ࣗͷੜ׆Λศརʹ͢ΔͷΛ࡞Δͷ࠷ߴʹ ָ͍͠ = RPi͓͢͢Ί
ؔ࿈ϓϩδΣΫτ • ϔϒϯζŋυΞɹʙࢲ͕ߦͬͨΒۭ͍ͯΔτΠϨʢ by νʔ ϜϥϘMAKE෦ ʣ • http://heavens-door.info/ •
ͪ͜Βmbedɻηϯαʔಉͬ͡Ά͍ • Peeping Tom in the toilet with Raspberry Pi • http://www.raspberrypi.org/archives/4509 • RPi + webcamɻτΠϨʹwebcamͬͯ…