moes_motionsensor_switch.yaml 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138
  1. # Example DPS Status
  2. # {"dps": { "1": false, "14": "memory", "15": "relay", "43": false, "44": "on",
  3. # "45": "default", "46": true, "47": "on", "48": "high", "49": 3600, "101": 0,
  4. # "102": 0}
  5. # Additional DPS 44 "Illuminance State" and 47 "Motion State". I couldn't
  6. # figure out what those did, device debugger appears to indicate that these
  7. # were set exactly once (to "on") when the switch was powered on and does NOT
  8. # seem to trigger or respond when Illuminance or Motion trigger is met, but
  9. # maybe I just don't know how to check that well. A final DPS shows up only in
  10. # the Tuya Cloud API: 103 "Timer". There are "timers" in the Smart Life App for
  11. # this device but I couldn't figure out how they work.
  12. # Illuminance Switch: Enables/disables illuminance threshold for motion
  13. # activation
  14. # Motion Switch: Enables/disables motion-triggered switch
  15. # Motion Auto-Off Delay: Time in seconds after which to turn off light if
  16. # triggered by motion
  17. # Appointment Time: Time of day in minutes when motion switch stops activating,
  18. # 0 for always
  19. # Target Time: Time of day in minutes when motion switch can activate, 0 for
  20. # always
  21. name: Motion sensor switch
  22. products:
  23. - id: vd5jgg8vgdbaqerq
  24. name: Moes Smart PIR switch
  25. primary_entity:
  26. entity: switch
  27. dps:
  28. - id: 1
  29. name: switch
  30. type: boolean
  31. - id: 44
  32. type: string
  33. name: illuminance_state
  34. - id: 47
  35. type: string
  36. name: motion_state
  37. secondary_entities:
  38. - entity: select
  39. category: config
  40. translation_key: initial_state
  41. dps:
  42. - id: 14
  43. name: option
  44. type: string
  45. mapping:
  46. - dps_val: memory
  47. value: memory
  48. - dps_val: "on"
  49. value: "on"
  50. - dps_val: "off"
  51. value: "off"
  52. - entity: select
  53. name: Indicator light
  54. category: config
  55. dps:
  56. - id: 15
  57. name: option
  58. type: string
  59. mapping:
  60. - dps_val: none
  61. value: "Off"
  62. - dps_val: relay
  63. value: "Status"
  64. - entity: switch
  65. name: Illuminance enable
  66. dps:
  67. - id: 43
  68. name: switch
  69. type: boolean
  70. - entity: select
  71. name: Illuminance threshold
  72. category: config
  73. dps:
  74. - id: 45
  75. name: option
  76. type: string
  77. mapping:
  78. - dps_val: default
  79. value: Default
  80. - dps_val: now
  81. value: Set current
  82. - entity: switch
  83. name: Motion enable
  84. dps:
  85. - id: 46
  86. name: switch
  87. type: boolean
  88. - entity: select
  89. name: Motion sensitivity
  90. category: config
  91. dps:
  92. - id: 48
  93. name: option
  94. type: string
  95. mapping:
  96. - dps_val: "low"
  97. value: "Low"
  98. - dps_val: "middle"
  99. value: "Medium"
  100. - dps_val: "high"
  101. value: "High"
  102. - entity: number
  103. name: Motion auto-off delay
  104. category: config
  105. dps:
  106. - id: 49
  107. name: value
  108. type: integer
  109. unit: s
  110. range:
  111. min: 5
  112. max: 3600
  113. - entity: number
  114. name: Disable time
  115. category: config
  116. dps:
  117. - id: 101
  118. name: value
  119. type: integer
  120. unit: h
  121. range:
  122. min: 0
  123. max: 1440
  124. mapping:
  125. - scale: 60
  126. - entity: number
  127. name: Enable time
  128. category: config
  129. dps:
  130. - id: 102
  131. name: value
  132. type: integer
  133. unit: h
  134. range:
  135. min: 0
  136. max: 1440
  137. mapping:
  138. - scale: 60