hey guys i need help with this i know how write to the LCD display, i just don know how to get my variables to display if you check my code you will see what i mean.
IMG_0900[1].jpg
Code:
#include "altera_up_avalon_character_lcd.h"
#include "altera_up_avalon_character_lcd_regs.h"
int main(){
/* other part of program
*
*
*here
*
*
*/
static int percent;
percent = (rddata * 100)/511; // rddatta is from other part of code
alt_up_character_lcd_dev * char_lcd_dev;
char_lcd_dev = alt_up_character_lcd_open_dev ("/dev/LCD");
alt_up_character_lcd_init(char_lcd_dev);
alt_up_character_lcd_string(char_lcd_dev,"% reflection "); //first line of text to display
alt_up_character_lcd_set_cursor_pos(char_lcd_dev,13,0);// move cursor to where i want to place variable percent
/* this is where i need help, hw do i display my variable??
*is the format i need something like this
*
*alt_up_character_lcd_write(char_lcd_dev, percent);
*
*/