I was just testing some simpler i2c code and looking at your module for the commands and noticed that visually I cannot see the difference between brightness values of 8 (0b1000) and 15 (0b1111) on a recently purchased bear badge. library/bearables/init.py converts the passed brightness of 0.0 to 1.0 into values to send to the badge with:
brightness = int(brightness * 15.0)
Should that really be 8.0? Note: this code also maps only 1.0 to maximum value due to the int().
https://lorrainbow.wordpress.com/2017/11/18/guest-blogger-phil-underwood-hacking-the-bareables-badge/ states (empirically) that maximum value is 7 so this supports my belief the upper limit is not as large as 15. I can see the difference between 7 and 8 from my testing therefore I think max is actually 8.
(I haven't put a 'scope on the leds to see if there's some pwm going on that's invisible to my eye at 9-15.)
I was just testing some simpler i2c code and looking at your module for the commands and noticed that visually I cannot see the difference between brightness values of 8 (0b1000) and 15 (0b1111) on a recently purchased bear badge. library/bearables/init.py converts the passed brightness of 0.0 to 1.0 into values to send to the badge with:
brightness = int(brightness * 15.0)Should that really be 8.0? Note: this code also maps only 1.0 to maximum value due to the int().
https://lorrainbow.wordpress.com/2017/11/18/guest-blogger-phil-underwood-hacking-the-bareables-badge/ states (empirically) that maximum value is 7 so this supports my belief the upper limit is not as large as 15. I can see the difference between 7 and 8 from my testing therefore I think max is actually 8.
(I haven't put a 'scope on the leds to see if there's some pwm going on that's invisible to my eye at 9-15.)