Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <main.h>
- #define LCD_ENABLE_PIN PIN_B4
- #define LCD_RS_PIN PIN_B5
- #define LCD_RW_PIN PIN_B6
- #define LCD_DATA4 PIN_B0
- #define LCD_DATA5 PIN_B1
- #define LCD_DATA6 PIN_B2
- #define LCD_DATA7 PIN_B3
- #include <lcd.c>
- char h = 23;
- void main()
- {
- lcd_init();
- lcd_putc('\f'); //Clear Display
- while(TRUE)
- {
- lcd_gotoxy(1,1); // Vá para linha 1 posição 1
- lcd_putc(h); // Imprima valor de h
- output_high(PIN_B0); // LED ON
- Delay_ms(1000); // 1 Second Delay
- output_low(PIN_B0); // LED OFF
- delay_ms(1000); // 1 Second Delay
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement