Implement BLE FS

This commit is contained in:
2021-11-22 22:04:09 -08:00
parent 3a877c41a4
commit 7b870950d1
4 changed files with 135 additions and 3 deletions

View File

@@ -15,6 +15,7 @@ const (
ReqTypeStepCount
ReqTypeWatchStepCount
ReqTypeCancel
ReqTypeFS
)
const (
@@ -22,6 +23,21 @@ const (
UpgradeTypeFiles
)
const (
FSTypeWrite = iota
FSTypeRead
FSTypeMove
FSTypeDelete
FSTypeList
FSTypeMkdir
)
type ReqDataFS struct {
Type int `json:"type"`
Files []string `json:"files"`
Data string `json:"data,omitempty"`
}
type ReqDataFwUpgrade struct {
Type int
Files []string
@@ -56,3 +72,10 @@ type MotionValues struct {
Y int16
Z int16
}
type FileInfo struct {
Name string `json:"name"`
Size int64 `json:"size"`
IsDir bool `json:"isDir"`
}