0

So I found this a github library for connecting the philips hue lightbulbs to the arduino, except I don't think I've mastered how the libraries work with it.

Whenever I include a library or add the files then it gives me errors, and following the usage on the github page also leaves me confused. It keeps telling me that it requires a constructor or destructor. Isn't that what the library is for?

Here is a link to the github page: https://github.com/bsalinas/ArduinoHue

I am basically doing everything to the letter, and am lost. Any helpful suggestions?

kkaul
  • 147
  • 1
  • 2
  • 13
  • What is *it* that requires a constructor/destructor? Can we see a small bit of code that exhibits the problem (even if it is only an empty main with some includes)? – Suedocode Jul 16 '13 at 22:08
  • void loop(){ Serial.begin(9600); hue.connect("YOUR_DEVICE_ID", "YOUR_USERNAME"); hue.turnOn(1);//1 is the Light ID. hue.seHueSat(1,45000,255); } I don't use a main, just a void loop that runs the whole time.@Aggieboy – kkaul Jul 17 '13 at 16:12

1 Answers1

2

I'm not sure if that library will actually work. For example in this file: https://github.com/bsalinas/ArduinoHue/blob/master/SerialHue/SerialHue.cpp#L20 there is a hardcoded username (the 22a82 thing). You might be better off asking the owner of that library directly on his github page how to use it or use another library. Here is a list of them:

https://github.com/q42/hue-libs

Christiaan
  • 2,637
  • 21
  • 26