unable to display Value on LCD

.

20131223_153508.jpg

Hi heixin.

The only place in your sketch that seems to send data to the lcd is the setup function. When that is called, you have not calculated any figures yet.

Paul

      lcd.print(watt_buf[x]);What is the value of x when this line is executed ?
Why is x declared as a char ?
What is in the watt_buff array and how does it get there ?
Is the ‘-’ character on the second line of the LCD significant ? Where could it have come from I wonder ?

Why is there nothing in the loop() function ?
Why use do while(1) in setup() instead of the loop() function ?