You can open your JS console on the Philips Hue page of Gladys, « Network » tab, refresh the page and copy and paste here (or in PM) the JSON response of the API GET call /api/v1/service/philips-hue/light!
Even better, you can create a GitHub issue with the JSON you get, a bit like this issue:
ouvert 01:28PM - 28 Nov 19 UTC
fermé 12:44PM - 03 Dec 19 UTC
```json
{"1":{"name":"Table à manger","service_id":"5bf6ff05-dd2f-4c0e-80b5-238⊠d160a1e6c","external_id":"philips-hue-light:00178825bff6:2","selector":"philips-hue-light:00178825bff6:2","should_poll":true,"model":"LWB006","poll_frequency":60000,"features":[],"not_handled":true,"raw_philips_hue_device":{"_rawData":{"state":{"on":false,"bri":254,"alert":"select","mode":"homeautomation","reachable":false},"swupdate":{"state":"noupdates","lastinstall":"2018-12-14T16:33:18"},"type":"Dimmable light","name":"Table à manger","modelid":"LWB006","manufacturername":"Philips","productname":"Hue white lamp","capabilities":{"certified":true,"control":{"mindimlevel":2000,"maxlumen":800},"streaming":{"renderer":false,"proxy":false}},"config":{"archetype":"pendantround","function":"functional","direction":"omnidirectional","startup":{"mode":"safety","configured":true}},"uniqueid":"00:17:88:01:10:40:cb:71-0b","swversion":"5.127.1.26420"},"_id":2}}}
```
Ok I have my console open in my Chrome browser but then I donât know how to find
Yes thank you it works well.
As you can see I even created a new issue and the merge request that goes with it, I hope I didnât mess up too much
You go to the network/réseau tab, you have a list of web requests made, you look for a GET request on /api/v1/service/philips-hue/light, you click on it, on the right your request will appear and you look for the responses tab.
Itâs good, I succeeded, but I had to use Firefox because on Chrome I didnât find how to do it.
Thanks @damalgos .
@pierre-gilles can you confirm that what I sent you is correct?
I found this site that references Philips Hue bulb models. Could this help to integrate the different models into Gladys?
https://homeautotechs.com/philips-hue-light-models-full-list/
Even better! Thanks, Iâll check it out!
Itâs perfect!
I prefer to handle it case by case with each userâs feedback, or even propose a « send unknown bulbs » button.
@pierre-gilles could you explain to me how you determine the method that the bulb should use (getPhilipsHueColorTemperatureLight, getPhilipsHueColorLight, getPhilipsHueWhiteLightâŠ)?
That way I could try to make a merge request for @Tlse-vins â issue
Well, itâs simple, if you look there are 5 types of models managed for now, in the « models » folder of the service:
color â when itâs a bulb/lamp that manages color, but not temperature (you can see this in the JSON if there is temperature management)
colorWithTemperature â when itâs a bulb/lamp that manages color + temperature (there is an attribute "ct":153 for example in the first lamp of @Tlse-vins , itâs therefore a bulb that manages temperature)
plugOnOff â itâs an on/off plug.
white â itâs a bulb without temperature and without color
whiteWithTemperature â itâs a bulb without color but with temperature. The attribute « ct » is usually present in the json!
I donât have an exact methodology, itâs mostly with a quick look at the JSON that I see what features the lamp has, and therefore what type of model it belongs to
If it manages another type of features, you need to create a new model of course
ok thanks for the info.
I made the merge request that works:
master â hotfix31:add-hue-device
ouvert 09:04AM - 04 Dec 19 UTC
### Pull Request check-list
To ensure your Pull Request can be accepted as fa⊠st as possible, make sure to review and check all of these items:
- [x] If your changes affects code, did your write the tests?
- [x] Are tests passing? (`npm test` on both front/server)
- [x] Is the linter passing? (`npm run eslint` on both front/server)
- [x] Did you run prettier? (`npm run prettier` on both front/server)
- [x] If your changes modify the API (REST or Node.js), did you modify the API documentation? (Documentation is based on comments in code)
- [x] If you are adding a new features/services which needs explanation, did you modify the user documentation? See [the GitHub repo](https://github.com/GladysAssistant/gladys-4-docs) and the [website](https://documentation.gladysassistant.com).
- [x] Did you add fake requests data for the demo mode (`front/src/config/demo.json`) so that the demo website is working without a backend? (if needed) See [https://demo.gladysassistant.com](https://demo.gladysassistant.com).
NOTE: these things are not required to open a PR and can be done afterwards / while the PR is open.
### Description of change
Just adding LCA001 Hue color lamp model on Hue service lamp mapping
As soon as the update is in place, Iâll let you know if itâs functional.
Iâm waiting for GU10 White ones, I guess weâll have to add them too.
I just received my GU10 White, I will try to install them this weekend.
@Hotfix31 If you merged what I sent you, is it operational in Gladys? Because for the moment, they are not recognized.
I just created an issue with the GU10 - LWG004.
Iâve made the merge request but @pierre-gilles still needs to do the validation.
You can follow the progress here:
master â hotfix31:add-hue-device
ouvert 09:04AM - 04 Dec 19 UTC
### Pull Request check-list
To ensure your Pull Request can be accepted as fa⊠st as possible, make sure to review and check all of these items:
- [x] If your changes affects code, did your write the tests?
- [x] Are tests passing? (`npm test` on both front/server)
- [x] Is the linter passing? (`npm run eslint` on both front/server)
- [x] Did you run prettier? (`npm run prettier` on both front/server)
- [x] If your changes modify the API (REST or Node.js), did you modify the API documentation? (Documentation is based on comments in code)
- [x] If you are adding a new features/services which needs explanation, did you modify the user documentation? See [the GitHub repo](https://github.com/GladysAssistant/gladys-4-docs) and the [website](https://documentation.gladysassistant.com).
- [x] Did you add fake requests data for the demo mode (`front/src/config/demo.json`) so that the demo website is working without a backend? (if needed) See [https://demo.gladysassistant.com](https://demo.gladysassistant.com).
NOTE: these things are not required to open a PR and can be done afterwards / while the PR is open.
### Description of change
Just adding LCA001 Hue color lamp model on Hue service lamp mapping
OK, it works. Iâll wait for his return and let you know if everything is fine.
Thatâs more or less it! Thatâs what Philips Hue returns.
Thanks for the PR! Itâs merged!
New PR for the latest model proposed by @Tlse-vins .
master â hotfix31:add-hue-device
ouvert 10:32PM - 10 Dec 19 UTC
### Pull Request check-list
To ensure your Pull Request can be accepted as fa⊠st as possible, make sure to review and check all of these items:
- [x] If your changes affects code, did your write the tests?
- [x] Are tests passing? (`npm test` on both front/server)
- [x] Is the linter passing? (`npm run eslint` on both front/server)
- [x] Did you run prettier? (`npm run prettier` on both front/server)
- [x] If your changes modify the API (REST or Node.js), did you modify the API documentation? (Documentation is based on comments in code)
- [x] If you are adding a new features/services which needs explanation, did you modify the user documentation? See [the GitHub repo](https://github.com/GladysAssistant/gladys-4-docs) and the [website](https://documentation.gladysassistant.com).
- [x] Did you add fake requests data for the demo mode (`front/src/config/demo.json`) so that the demo website is working without a backend? (if needed) See [https://demo.gladysassistant.com](https://demo.gladysassistant.com).
NOTE: these things are not required to open a PR and can be done afterwards / while the PR is open.
### Description of change
Just adding LWG004 Hue white spot model on Hue service ligth mapping
Nice, youâve got the hang of it it seems Thanks, more new material handled!
Hi @pierre-gilles , I just checked in Gladys, I still canât manage its bulbs. Is this normal or do I have to wait for the update?
I havenât merged the PR yet Iâm quite busy at the moment. I worked full-time on Gladys in October/November, but since I didnât do any freelancing for 2 months, to make it financially viable for me, I compensated by taking on a demanding freelance mission in December, hence my very reduced presence this month ^^ My mission ends at the end of the week, Iâll look into all that at Christmas!