I'm using most popular LCD library for beaglebone.
https://github.com/estef150892/Beaglebone-lcd-c/blob/master/beagle_hd44780.c

I want to know if anybody repair using of function:
void goto_ScreenLocation(int line, int position,struct gpioID 
enabled_gpio[])

Couse as the author wrote: "but * it is not doing so for the second line'
I was trying to change the value of position but it doesn't work.

void goto_ScreenLocation(int line, int position,struct gpioID enabled_gpio
[])
{
    int nbr_selectedPins=6;
    const char *pinDescription[] = {"","","","","",""};
    unsigned int data_to_write;

    //printf("position: %d\n",position);
    //printf("line: %d\n\n",line);
    //if (line==1) position=position+124;
    if (line==1) position=position+40;
    if (line==2) position=position+20;
    if (line==3) position=position+84;
    data_to_write=return_address_in_bitform(position,0);
    //printf("data_to_write: %d\n",data_to_write);
    data_to_write=bitWrite(data_to_write,1,0);
    //printf("<%d>\n",data_to_write);
    turn_ON_OFF_pins(enabled_gpio,data_to_write,nbr_selectedPins,MAX_DELAY,
pinDescription);
    pulsePin(enabled_gpio,data_to_write,nbr_selectedPins,
DISPLAY_DATA_ON_SCREEN, pinDescription, 5, MAX_DELAY);
      sleep(MAX_DELAY);

    data_to_write=return_address_in_bitform(position,1); 
    //printf("data_to_write: %d\n",data_to_write);
    turn_ON_OFF_pins(enabled_gpio,data_to_write,nbr_selectedPins,MAX_DELAY,
pinDescription);
    pulsePin(enabled_gpio,data_to_write,nbr_selectedPins,
DISPLAY_DATA_ON_SCREEN, pinDescription, 5, MAX_DELAY);
      sleep(MAX_DELAY);
}


-- 
For more options, visit http://beagleboard.org/discuss
--- 
You received this message because you are subscribed to the Google Groups 
"BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/beagleboard/ea5e1f6a-645b-4345-af41-2ff0026110f0%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to