emonGLCD V1.2 bugs
A couple of bugs have been discovered in the PCB layout of the emonGLCD PCB version V1.2 (current release as of Oct/Nov 2011). The bugs with potential fixes are listed below. Please add any other bugs you find to this page.
LDR light sensor
The LDR is connected to ADC0. This port is also used by the GLCD. When the line glcd.begin() is called ADC0 is puled low thus making the LDR reading very low. The LDR can still be used by calling analogRead(0); but the voltage swing is limited. From my tests the ADC value goes from 0 (dark) to about 30 (very bright torch light). Normal room lighting is about 4.
On the next version of the emonGLCD PCB I will consider moving the LDR will be moved to ADC4.
Tri-color LED PWM
It was intended that PWM (pulse width modulation) could be used to make the tri-colour LED's glow bright, dim or pulsate.
The tri-color LED's are currently connected to ports Dig8 and Dig9. Only specific ports on the Atmega can be used for PWM. Dig 8 is NOT a PWM port. The tri-color LED connected to Dig8 will be moved to Dig6 on the next PCB version.
V1.2 users can get round this problem by either manually moving the port with a PCB hack or using bit-banging to obtain a virtual PWM output. See here for more Arduino PWM info.