prefixkit Ask an engineerAsk Support RU

Zigbee devices Lights and bulbs

Sunricher SR-ZG9030A-MW

Zigbee compatible ceiling mount occupancy sensor. Works with Zigbee2MQTT with no vendor hub or cloud: it pairs with a Zigbee stick and shows up in Home Assistant.

Vendor
Sunricher
Model
SR-ZG9030A-MW
Type
Lights and bulbs
Power
mains: usually a router that extends the mesh
Firmware updates (OTA)
no

Find it in shops: AliExpress

Links open a search in the shop; some are affiliate links: buying through them costs you nothing extra and supports this site. We do not sell devices or get them from manufacturers.

What it exposes

FeaturePropertyValuesControl
ModelmodelHK-DIM, ZG9030A-MWsettable
Light pwm frequencylight_pwm_frequency0…65535settable
Brightness curvebrightness_curvelinear, gamma_logistics_1_5, gamma_logistics_1_8settable
Start up on offstart_up_on_offlast_state, on, offsettable
Motion sensor light durationmotion_sensor_light_durations · 0…65535settable
Motion sensor light sensitivitymotion_sensor_light_sensitivity0…255settable
Motion sensor working modemotion_sensor_working_modeautomatic, manualsettable
Motion sensor sensing distancemotion_sensor_sensing_distance0…15settable
Motion sensor microwave switchmotion_sensor_microwave_switchon, offsettable
Motion sensor onoff broadcastmotion_sensor_onoff_broadcaston, offsettable
Motion sensor light statemotion_sensor_light_stateon, offsettable
Motion sensor in pwm brightnessmotion_sensor_in_pwm_brightnesslux · 0…1000settable
Motion sensor in pwm outputmotion_sensor_in_pwm_output0…254settable
Motion sensor leave pwm outputmotion_sensor_leave_pwm_output% · 0…100settable
Motion sensor leave delaymotion_sensor_leave_delays · 0…65535settable
Motion sensor pwm output after delaymotion_sensor_pwm_output_after_delay% · 0…100settable
Linearity error ratio luxlinearity_error_ratio_lux100…10000settable
Fixed deviation luxfixed_deviation_lux-100…100settable
Lightstate, brightnesson / off, brightnesssettable
Light effecteffectblink, breathe, okay, channel_change, finish_effect, stop_effectsettable
After power losspower_on_behavioroff, on, toggle, previoussettable
Motion (2)occupancy_2—read only
Illuminance (3)illuminance_3lxread only
Action (button press)actionon, off, toggle, brightness_move_to_level, brightness_move_up, brightness_move_down, brightness_step_up, brightness_step_down …read only

MQTT: state and commands

Zigbee2MQTT publishes the device state to zigbee2mqtt/my_device (my_device is the name you give the device). An example message:

{
  "model": "HK-DIM",
  "light_pwm_frequency": 32768,
  "brightness_curve": "linear",
  "start_up_on_off": "last_state",
  "motion_sensor_light_duration": 32768,
  "motion_sensor_light_sensitivity": 128,
  "motion_sensor_working_mode": "automatic",
  "motion_sensor_sensing_distance": 8,
  "motion_sensor_microwave_switch": "on",
  "motion_sensor_onoff_broadcast": "on",
  "motion_sensor_light_state": "on",
  "motion_sensor_in_pwm_brightness": 500,
  "motion_sensor_in_pwm_output": 127,
  "motion_sensor_leave_pwm_output": 50,
  "state": "ON",
  "brightness": 180,
  "linkquality": 120
}

Send commands to zigbee2mqtt/my_device/set:

mosquitto_pub -t zigbee2mqtt/my_device/set -m '{"state":"ON","brightness":180}'
mosquitto_pub -t zigbee2mqtt/my_device/set -m '{"state":"OFF","transition":2}'
mosquitto_pub -t zigbee2mqtt/my_device/set -m '{"model":"ZG9030A-MW"}'
mosquitto_pub -t zigbee2mqtt/my_device/set -m '{"brightness_curve":"gamma_logistics_1_5"}'
mosquitto_pub -t zigbee2mqtt/my_device/set -m '{"start_up_on_off":"on"}'

Watch the topics live from the browser: MQTT client.

Home Assistant automation example

Zigbee2MQTT creates Home Assistant entities from the device name. If it is called my_device, an automation in automations.yaml can look like this:

- alias: "Light at sunset"
  mode: single
  triggers:
    - trigger: sun
      event: sunset
      offset: "-00:15:00"
  actions:
    - action: light.turn_on
      target:
        entity_id: light.my_device
      data:
        brightness_pct: 70

Check the YAML: YAML checker.

How to pair it

  1. In Zigbee2MQTT click Permit join.
  2. Put the device in pairing mode: usually a long press of the reset button (5–10 s) until the LED blinks; bulbs: switch the power off and on 5–6 times.
  3. Keep the device close to the coordinator or a router while pairing.
  4. Give it a clear name: MQTT topics and Home Assistant entities are built from it.

Exact procedure and model notes: the device page in the Zigbee2MQTT docs. No coordinator yet: coordinator picker.

Similar devices

Idea?