model.go 614 B

1234567891011121314151617181920212223242526272829
  1. package service
  2. type EnvData struct {
  3. Sn string `json:"sn"`
  4. Temperature float64 `json:"temperature"`
  5. Humidity float64 `json:"humidity"`
  6. Illuminance int64 `json:"illuminance"`
  7. }
  8. type OpticalData struct {
  9. Sn string `json:"sn"`
  10. Illuminance int64 `json:"illuminance"`
  11. }
  12. type InductanceData struct {
  13. Sn string `json:"sn"`
  14. TotalPower int64 `json:"totalPower"`
  15. }
  16. type RelayState struct {
  17. Sn string `json:"sn"`
  18. Way int `json:"way"`
  19. TurnOf int `json:"turnOf"`
  20. }
  21. type LampBrightNess struct {
  22. Way int8 `json:"way"`
  23. BrightNess int `json:"brightNess"`
  24. }