access.go 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. package rpcs
  2. import (
  3. "sparrow/pkg/protocol"
  4. )
  5. type ArgsSetStatus struct {
  6. DeviceId string
  7. Status []protocol.SubData
  8. }
  9. type ReplySetStatus ReplyEmptyResult
  10. type ArgsGetStatus struct {
  11. Id string
  12. ProductId string
  13. VendorId string
  14. SubDeviceId string
  15. }
  16. type ReplyGetStatus struct {
  17. Status []protocol.SubData
  18. }
  19. type ArgsSendCommand struct {
  20. DeviceId string
  21. SubDevice string
  22. Cmd string
  23. WaitTime uint32
  24. Params map[string]interface{}
  25. }
  26. type ReplySendCommand ReplyEmptyResult
  27. type ArgsDeviceUpgrade struct {
  28. DeviceId string
  29. SudDeviceId string
  30. Url string
  31. Md5 string
  32. Version string
  33. FileSize int64
  34. }
  35. type ArgsSendByteData struct {
  36. DeviceId string
  37. SubDevice string
  38. Cmd string
  39. WaitTime uint32
  40. Data []byte
  41. Params map[string]interface{}
  42. }
  43. type ArgsUpgrade4G struct {
  44. DeviceId string
  45. FileId string
  46. FileSize int64
  47. }
  48. type ChunkUpgrade struct {
  49. DeviceId string
  50. FileId int
  51. FileSize int64
  52. Size int64
  53. Offset int
  54. }
  55. type ReplyStatus struct {
  56. Status string
  57. }
  58. type ReplayInfo struct {
  59. Info string
  60. }