6. Get Temperature and
Humidity in Room
Post images from
Raspberry Pi
Schedule tasks
of Swift CLI
Auto draining
water to plant
Communicate
through GPIO
Firebase in Swift CLI
SwiftGarden
Take Photos using
Raspberry Pi
Swift Charts
Collaborate with
Home appliance
Run Bash from
Swift
Run Python from
Swift
Run Swift on
Raspberry Pi
48. 48
4.iOSアプリでデータを確認する
グラフに使用するstructを用意する(今回は温度/湿度は共通のモデル)
enum DataType: String {
case humidity
case temperature
}
struct DataModel: Identifiable {
var id: String { type.rawValue + xValue.description + yValue.description }
let type: DataType
let xValue: Date
let yValue: Int
}
LiveGraphView.swift
SwiftのChartsで折れ線グラフの実装する
63. 63
まとめ
Raspberry Pi Documentation - Camera softwar
Google Cloud Storage JSON API の概
Cloud Firestore REST API の使
ラズパイ - 水中ポンプを制御しよ
Creating a chart using Swift Chart
https://developer.apple.com/documentation/charts/creating-a-chart-using-
swift-chart
SwitchBot API v1.1
https://www.raspberrypi.com/documentation/computers/camera_software.htm
https://cloud.google.com/storage/docs/json_ap
https://firebase.google.com/docs/firestore/use-rest-ap
https://zenn.dev/kotaproj/articles/4903ba3b41626
https://github.com/OpenWonderLabs/SwitchBotAPI
主な参考資料・情報