Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: BSP_DISCO_L476VG LCD_DISCO_L476VG mbed
Fork of DISCO_L476VG_GlassLCD by
main.cpp
- Committer:
- bcostm
- Date:
- 2015-09-19
- Revision:
- 2:16502e83726a
- Parent:
- 0:0ecb0cbf4c30
- Child:
- 5:a581e9699510
File content as of revision 2:16502e83726a:
#include "mbed.h"
#include "LCD_DISCO_L476VG.h"
LCD_DISCO_L476VG lcd;
DigitalOut led_green(LED1);
int main()
{
uint32_t temp = 0;
uint8_t stemp[7] = {0};
uint8_t title[] = " DISCOVERY STM32L476";
printf("Hello\n");
led_green = 1;
lcd.Clear();
lcd.DisplayString((uint8_t *)"HELLO");
wait(1);
printf("Scroll sequence\n");
led_green = 0;
lcd.Clear();
lcd.ScrollSentence(title, 2, 200);
lcd.Clear();
while(1) {
printf("BAR = %d\n", temp);
sprintf((char *)stemp, "BAR %d", temp);
lcd.DisplayString(stemp);
lcd.BarLevelConfig((uint8_t)temp);
temp++;
if (temp > 4) temp = 0;
led_green = !led_green;
wait(1);
}
}
