C Language Development Kit/Functions/Backlight
From OptiWiki
< C Language Development Kit | Functions(Redirected from C Language Development Kit/Functions/backlight)
| Description | This function controls the backlight on the LCD-display. | ||||||
| Syntax | int backlight(int state, short time); | ||||||
| Arguments | One of the following values:
int state
The time before the backlight is automatically turned off.
short time | ||||||
| Returns | None | ||||||
| Example | #include "lib.h" #include <stdio.h> void main( void ) { int c; while( 1 ) { gotoxy(0,0); c = getchar(); if( c == F1_KEY ) backlight( TOGGLE ); if( c == F2_KEY ) backlight(ON); if( c == F3_KEY ) backlight( OFF ); c = backlight( -1 ); if( c == ON ) printf("backlight is on "); if( c == OFF ) printf("backlight is off"); idle(); } } |
