from lcd_sa import *;
import time;
from machine import Pin;
textFill = 'Lorem ipsum dolor sit amet consectetur, adipisicing elit. Placeat, aliquam?';
buttonClear = Pin(15,Pin.IN,Pin.PULL_UP);
buttonChClear = Pin(1,Pin.IN,Pin.PULL_UP);
buttonSetText = Pin(28,Pin.IN,Pin.PULL_UP);
scrollTop = Pin(22,Pin.IN,Pin.PULL_UP);
scrollbottom = Pin(14,Pin.IN,Pin.PULL_UP);
startLengthCol = 4;
currentScrollPosition = 0;
countLine = 0;
countCh = 0;
setlcd();
lcdwrite(1,7,":)");
lcdwrite(2,startLengthCol,"Project 2");
while 1:
  if buttonClear.value() == 0:
    setlcd();
    #lcdwrite(1,0," "*16)
    #lcdwrite(2,0," "*16)
  if buttonChClear.value() == 0:
    lcdwrite(2,startLengthCol," ");
    startLengthCol +=1;
  if buttonSetText.value() == 0
    lcdwrite(1,0,"Lorem ipsum dolor sit amet consectetur, adipisicing elit. Placeat, aliquam?");
    for x in textFill:
      ++countCh
      if(countCh > 16):
        ++countLine
        lcdwrite(countLine,0,"Lorem ipsum dolor sit amet consectetur, adipisicing elit. Placeat, aliquam?");

  if scrollTop.value() == 0:  
    print('ok')

    # Scroll down  
  if scrollbottom.value() == 0:
    print('no')
$abcdeabcde151015202530fghijfghij
BOOTSELLED1239USBRaspberryPiPico©2020RP2-8020/21P64M15.00TTT