The color calculation does not appear to be right regarding the brightness. In particular, I do not think it factors in 0 not being off. From the Hue documentation:
"This is the brightness of a light from its minimum brightness 0 to its maximum brightness 255 (note minimum brightness is not off). This range has been calibrated so there a perceptually similar steps in brightness over the range."
The color calculation does not appear to be right regarding the brightness. In particular, I do not think it factors in 0 not being off. From the Hue documentation:
"This is the brightness of a light from its minimum brightness 0 to its maximum brightness 255 (note minimum brightness is not off). This range has been calibrated so there a perceptually similar steps in brightness over the range."