make-all / tuya-local

Local support for Tuya devices in Home Assistant
MIT License
1.4k stars 536 forks source link

Request support for new device: Wi-Fi Door Window Detector #538

Closed mchauhan1968 closed 1 year ago

mchauhan1968 commented 1 year ago

Log Message

Please paste logs here

Information about DPS mappings

{
  "result": {
    "category": "mcs",
    "functions": [],
    "status": [
      {
        "code": "doorcontact_state",
        "type": "Boolean",
        "values": "{}"
      },
      {
        "code": "battery_percentage",
        "type": "Integer",
        "values": "{\"unit\":\"%\",\"min\":0,\"max\":100,\"scale\":0,\"step\":1}"
      }
    ]
  },
  "success": true,
  "t": 1678845741921,
  "tid": "6c4260bbc2d511eda2c5dae7169ea2b8"
}
DPID        Description
1           Door Sensor
2           Battery Level

Product ID

{
  "result": {
    "active_time": 1633891123,
    "biz_type": 0,
    "category": "mcs",
    "create_time": 1633891123,
    "icon": "smart/icon/ay1562583874631k02Aw/1963307c4e8dfa573d9e4efe6e62f187.jpg",
    "id": "eb171a3285344aa82eyoqj",
    "ip": "72.137.74.****",
    "lat": "43.9160",
    "local_key": "**********************",
    "lon": "-79.4450",
    "model": "AW201_2",
    "name": "BasementSlidingDoor",
    "online": true,
    "owner_id": "***************",
    "product_id": "0mjj67aaztcfmc3i",
    "product_name": "WIFI Door ",
    "status": [
      {
        "code": "doorcontact_state",
        "value": false
      },
      {
        "code": "battery_percentage",
        "value": 60
      }
    ],
    "sub": false,
    "time_zone": "-04:00",
    "uid": "az16304437505510ZRmx",
    "update_time": 1640049967,
    "uuid": "87b57f17cce79cb5"
  },
  "success": true,
  "t": 1678844412548,
  "tid": "53e087cac2d211edb7680e743b151476"

Information about how the device functions

Manufacturer: ‎FENGCHUANG Specifications: 1.Operating Power: AAA 1.5V X2(Not including battery) 2.Wireless Type:2.4GHz(not support 5G ) 3.Compound multi-layer design 4.Built-in omnidirectional antenna 5.Superior circuit design 6.High-performance and low power consumption 7.Superior ABS material 8.Protocol:IEEE 802.11b/g/n 9.Shock resistence:4.7M,1.2M.3.5M,300k 10.Transmission distance:50-200m in open area

https://www.amazon.ca/FENGCHUANG-Window-Security-Monitoring-Compatible/dp/B0978PR1PM/ref=sr_1_3?keywords=FENGCHUANG+2PCS+Door+and+Window+Sensor&qid=1678846293&sr=8-3

make-all commented 1 year ago

In general battery powered devices cannot work with local connections, as the WiFi is offline most of the time to conserve battery, only coming on when it wants to report to the cloud. So I will not spend time on battery powered devices that do not come with log messages to demonstrate that working locally is at least feasible.