API Compatible with MIJIA smart LED desk lamp?

Is the published API compatible with the MIJIA smart LED desk lamp? If so, are there new properties for the different modes of the desk lamp?

Thanks,
Sam

Hi Sam,

MIJIA smart LED desk lamp doesn’t support the published API and we have no plan to support it in future due to some policy issue.

sorry for that.

-weiwei

On the website is said clearly that it supports Open API?

It’s an error, will remove this icon for Mijia desk lamp

Okey. Is there anyway to talk to it other then the yeelight app?

IFTTT or Echo in future.

It seems that a new firmare allows now to control this lamp using the API.

Yes, the latest firmware support open API.

Hi,

can you please clarify (from) which firmware version ?

I can confirm i succeeded to update to 1.3.0_49 today, by switching to China mainland and developer mode is enabled;
Sample python code seems is not compatible;

python YeelightWifiBulbLanCtrl.py
Welcome to Yeelight WifiBulb Lan controller
Enter a command: h
Usage:
  q|quit: quit bulb manager
  h|help: print this message
  t|toggle <idx>: toggle bulb indicated by idx
  b|bright <idx> <bright>: set brightness of bulb with label <idx>
  r|refresh: refresh bulb list
  l|list: lsit all managed bulbs
Enter a command: l
1 managed bulbs
1: ip=192.168.X.Y,model=desklamp,power=on,bright=100,rgb=0
Enter a command: t 1
connect  192.168.X.Y 55443 ...
Enter a command: b 1 20
idx 1
bright 20
connect  192.168.X.Y 55443 ...

what do you mean by incompatible?

for example

python YeelightWifiBulbLanCtrl.py
Welcome to Yeelight WifiBulb Lan controller
bulbs_detection_loop running
send search request
invalid data received: M-SEARCH * HTTP/1.1
HOST: 239.255.255.250:1982
MAN: "ssdp:discover"
ST: wifi_bulb
Enter a command: l
command_line=l
1 managed bulbs
1: ip=192.168.X.Y,model=desklamp,power=on,bright=100,rgb=0
Enter a command: t 1
command_line=t 1
connect  192.168.X.Y 55443 ...

has no effect (lamp doesn’t switch on/or/off)

it’s not a communication issue; i have tested https://gitlab.com/stavros/yeecli/ for example, there are lots of errors, probably need to debug a lot but turn off / on; toggle; brightness (sometimes) works

@weiwei, are sure 100% sure about this? I can definetely control my desk lamp with JSON api (in Developer Mode)! :confused:

Are going to remove API (Developer Mode) support in future? (I will get very disappoint) :confused:

@lightmaster it was in Sep 2016.
I just got one yesterday and stock firmware didn’t had developer-mode. I’ve updated to 1.3.0_49 and i have it.
No-one is going to remove it :slight_smile:

What library do you use for controlling it ?
What functions work ?

I wrote my own library for HomeAssistant. All documented features work: on/off, brightness, colour temperature, etc… :slight_smile:

Yeah sorry, didn’t notice date for the post. :slightly_smiling_face: It’s OK now.

do you have it somewhere on github ?
looking to do exactly the same thing.

I have uploaded it here: http://git.s-ko.net/muchweb/yeelight-lan