Temperature of Light and White Balancing

LED Temperature

I am sure most folks when they are picking out what LED bulbs, usually buy LEDs by colour and go via marketing jargons like Warm White, Cool Day, Warm Yellow etc. These terms usually represent the output colour of your LEDs. Some of you would know that there is a standard way to represent them in terms of colour temperature with units in Kelvin(These would be mentioned on your bulbs). Let’s explore what those are today.

LED Temperature White Balancing

The temperature of colour is a weird way to represent information. Colour has no “heat”. So why use temperature as a measurement unit for it? It all goes back to a concept known as a black body radiator. In simple terms, it’s a theoretical material which emits radiation(aka light) when heated to different high temperatures. For example, think of a metal(which is a somewhat close real-life black body), when it’s heated to say 1500K has a particular glow in the red/orange range. Now when you start increasing the temperature of this material, the colour slowly starts to change white(Bluish tinge). So hence temperature Kelvin is used in relation to the colour of light. The temperature range can go from 1500K – 10,000K+. 1700K range corresponds to candle-flame-orange light & 6500K is clear sunlight on a bright day. So you have a huge range of LEDs to choose from based on what you want.

Temperature and White Balancing

Now let’s come to photography of this light. Where it’s all relative to your settings. Open your mobile camera and go to the manual mode in your camera you will see there is something known as White Balance on the settings, This is also measured in Kelvin. This setting is telling your camera sensor what pure white light is. Let’s say you put the WB setting on the camera as 5000K and take a photo of an object. So any light source in your scene with a colour temp of 5000K will appear white on your image whereas any light source lesser than that will appear Yellow and anything above will appear bluish. It’s as simple as that. Now if slide up your white balance to say 6500K setting you will see more things looking yellow (if the scene lighting is at say 5000K). Knowing this concept will help you take killer pics and set the lighting mood for your camera. Take a look at the picture for seeing how an image will come out for the same lighting scene shot with different WB settings.

If you liked the post, Share it with your friends!

Back to Basics: Pullup Resistors for I2C

Pullup Resistor Calculation

Since there was a large interest from quite a few folks regarding the last post, thought of continuing that design series on how to select pull-up resistors for I2C. (Check images for the formulas)The lower limit of the resistor is defined by V_OL which is the maximum voltage that can be recognised as zero by your circuit. Eg. If 0.4V and below is taken as zero in the digital circuit, V_OL = 0.4V. The sink current is the current which can be taken by your gate. You can find this in your sensor’s/microcontrollers datasheet in the electrical specs section. These two values determine the minimum value needed for your I2C bus to function.

On the upper end, it’s decided by the rise time mentioned in the standard I2C spec and the bus capacitance. Rise time values(in ns) from the I2C spec sheet for different speed modes of I2C are as follows

– Standard-mode (Sm, 100Kbps) –> 1000ns

– Fast-mode (Fm, 400Kbps) –> 300ns

– Fast-mode Plus (Fm+, 1Mbps) –> 120ns

– High-speed mode (Hs-mode, 3.4Mbps) –> 80ns

So pick a value from the above list based on the speed of operation of your I2C system.

Bus capacitance is the effective capacitance shown by your I2C bus. This is specific to your PCB/breadboard implementation and will vary based on your design. The ideal goal is to have as small a capacitance as possible so that you can transfer data faster. Larger capacitance means that it takes more time for the signal to reach its logic high(larger rise times) and sometimes it might never get to logic high causing problems in the communication. The capacitance of your bus will always be higher if you have longer bus lengths, PCB-to-wire connections, and more devices connected on the bus.

There is no simple way that I know of to calculate bus capacitance in the design stage. The practical way is to build out your circuit by calculating the pullup resistor(above the lower limit) and sending I2C data on the bus. Now probe the SDA and SCL line with a scope and measure the rise time. Now using the RC time constant formula back-calculate the bus capacitance for your circuit. Now with this, you can modify your pullup resistance formula if needed. If capacitance/rise times are not problematic in your circuit always go with the highest value of resistance possible so as to minimize power loss. I2C is a power guzzler.

PS: Refer TI’s SLVA689 whitepaper to see derivation on how you got the formulas mentioned for pullup resistor designs

If you liked the post, Share it with your friends!
1 57 58 59 60 61 66