
Are you a QOTWer? Do you want to start a thread that isn't a direct answer to the current QOTW? Then this place, gentle poster, is your friend.
( , Sun 1 Apr 2001, 1:00)
« Go Back | See The Full Thread

( , Fri 6 Mar 2015, 8:54, 1 reply, 10 years ago)

( , Fri 6 Mar 2015, 8:57, Reply)

Oh, because I didn't clock it 'till the next day when I came across an interesting blog, I worked out the calculatings behind that HSL issue.
Hue is done in degrees, 360, but there are 184.2 values on the PH per degree, so I just timesed the degree by 184.2 then toFIxed(0) because it can only take an int.
Sat is normally a %, but there are 255 possible values, so the maths was easy there.
Bri is irrelevant to colour, but again, it's 255 possible values.
=-=-=-=-
RGB/HEX to HSL is worked out via a jsLib I found called tinyColour, which converts anything to anything.
( , Fri 6 Mar 2015, 9:13, Reply)

( , Fri 6 Mar 2015, 9:15, Reply)

the light switches behaved oddly and he could turn a light on and off and alter the brightness of it by plugging a hairdryer in a nearby socket. Surprised the place didn't burn down.
( , Fri 6 Mar 2015, 9:33, Reply)

... but naturally there was no Standards for it like they're building today (Zigbee/HomeKit/etc), and suddenly everything stopped working and going crazy.
In the end it turned out that a blown lightbulb was DoSing his whole house.
( , Fri 6 Mar 2015, 9:38, Reply)

They have a mobile-first website written AngularJS, so I Prettified it's JS which exposed all it's API calls.
( , Fri 6 Mar 2015, 9:50, Reply)

When I told their Twitter, I was supprised they didn't react a bit stronger, because one of the params is a numerical "ClientID". I don't think that's entirely secure, I didn't test it against the cookie, but if they're accepting that, then the odds are I can change other people's heating.
( , Fri 6 Mar 2015, 9:55, Reply)

By all means have stuff in your house talk to each other, but ffs air gap it from the Internet at all costs.
( , Fri 6 Mar 2015, 10:01, Reply)

On the Philips Hue system, every time you use a new app, you have to phsyically press a button on the base-station.
This year at WWDC we'll see HomeKit implimented properly, now that manufacturers have had a year to get certifications from Apple - I think that'll do the job properly.
NFC on iOS is locked down due to ApplePay, but it can 'unlock doors' in hotels, so I have no idea how actually locked down it is.
( , Fri 6 Mar 2015, 10:20, Reply)

Even smart TVs are phoning out unencrypted now, pisspoor security through cost-cutting doesn't make me want to touch any of it with a bargepole.
( , Fri 6 Mar 2015, 10:28, Reply)

( , Fri 6 Mar 2015, 9:51, Reply)

Plus I have the Stickers version of these: estimote.com/ , that I've managed to get interacting with properly.... so I can just put my phone on the table and it'll pre-set a seqence or whatever.
( , Fri 6 Mar 2015, 9:20, Reply)

Give me some tricky business logic any day of the week.
( , Fri 6 Mar 2015, 9:19, Reply)

But we're talking about interacting with the API behind these: www2.meethue.com/en-gb/
( , Fri 6 Mar 2015, 9:21, Reply)
« Go Back | See The Full Thread