亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? lcdd.txt

?? LCD驅動顯示模塊實例源碼
?? TXT
?? 第 1 頁 / 共 3 頁
字號:
}

/**********************************************************************//**
 * @brief  Displays the string to the LCD starting at (x,y) location. 
 * 
 * Writes all the data to LCD_MEM first, then updates all corresponding 
 * LCD CGRAM locations at once, in a continuous fashion.
 * 
 * @param  String[]  String to be displayed on LCD
 * 
 * @param  x         x-coordinate of the write location on the LCD 
 * 
 * @param  y         y-coordinate of the write location on the LCD
 * 
 * @param  TextStyle Value that specifies whether the string is to be 
 *                   inverted or overwritten. 
 *                   - Invert    = 0x01 
 *                   - Overwrite = 0x04 
 *************************************************************************/
void halLcdPrintXY( char String[], int x, int y, unsigned char TextStyle)  
{
  //Each line increments by 0x20
  halLcdSetAddress( (y << 5) + (x >> 3)) ;  //Narrow down to 8 possible pixels    
  halLcdPrint(String,  TextStyle);
}

/**********************************************************************//**
 * @brief  Displays a string on the LCD on the specified line.  
 * 
 * @param  String[]  The string to be displayed on LCD.
 * 
 * @param  Line      The line on the LCD on which to print the string.
 * 
 * @param  TextStyle Value that specifies whether the string is to be 
 *                   inverted or overwritten. 
 *                   - Invert    = 0x01 
 *                   - Overwrite = 0x04 
 * 
 * @return none
 *************************************************************************/
void halLcdPrintLine(char String[], unsigned char Line, unsigned char TextStyle)  
{
  int temp; 
  temp = Line * FONT_HEIGHT ;
  halLcdSetAddress( temp << 5 ) ;           // 0x20 = 2^5  
  halLcdPrint(String, TextStyle);
}

/**********************************************************************//**
 * @brief  Prints a string beginning on a given line and column.  
 * 
 * @param  String[]  The string to be displayed on LCD.
 * 
 * @param  Line      The line on which to print the string of text
 * 
 * @param  Col       The column on which to print the string of text
 * 
 * @param  TextStyle Value that specifies whether the string is to be 
 *                   inverted or overwritten. 
 *                   - Invert    = 0x01 
 *                   - Overwrite = 0x04 
 * 
 * @return none
 *************************************************************************/
void halLcdPrintLineCol(char String[], unsigned char Line, unsigned char Col,
                        unsigned char TextStyle)  
{
  int temp; 
  
  temp = Line * FONT_HEIGHT;
  temp <<= 5;
  temp += Col;
  
  halLcdSetAddress( temp ) ;                // 0x20 = 2^5                     
  halLcdPrint(String, TextStyle);
}


/**********************************************************************//**
 * @brief  Draws a horizontral line from (x1,y) to (x2,y) of GrayScale level
 * 
 * @param  x1        x-coordinate of the first point 
 * 
 * @param  x2        x-coordinate of the second point
 * 
 * @param  y         y-coordinate of both points
 * 
 * @param  GrayScale Grayscale level of the horizontal line
 * 
 * @return none
 *************************************************************************/
void halLcdHLine( int x1, int x2, int y, unsigned char GrayScale)
{
  int x_dir, x;
  if ( x1 < x2 )
    x_dir = 1;
  else 
    x_dir = -1;
  x = x1;    
  while (x != x2)
  {
    halLcdPixel( x,y, GrayScale); 
    x += x_dir;
  }
}

/**********************************************************************//**
 * @brief  Draws a vertical line from (x,y1) to (x,y2) of GrayScale level
 * 
 * @param  x         x-coordinate of both points
 * 
 * @param  y1        y-coordinate of the first point 
 * 
 * @param  y2        y-coordinate of the second point
 * 
 * @param  GrayScale GrayScale level of the vertical line
 * 
 * @return none
 *************************************************************************/
void halLcdVLine( int x, int y1, int y2, unsigned char GrayScale)
{
  int y_dir, y;
  if ( y1 < y2 )
    y_dir = 1;
  else 
    y_dir = -1;
  y = y1;    
  while (y != y2)
  {
    halLcdPixel( x,y, GrayScale); 
    y += y_dir;
  }
}

/**********************************************************************//**
 * @brief  Draws a line from (x1,y1) to (x2,y2) of GrayScale level.
 *         
 * Uses Bresenham's line algorithm.
 * 
 * @param  x1         x-coordinate of the first point        
 *  
 * @param  y1         y-coordinate of the first point
 * 
 * @param  x2         x-coordinate of the second point
 * 
 * @param  y2         y-coordinate of the second point
 * 
 * @param  GrayScale  Grayscale level of the line 
 * 
 * @return none
 *************************************************************************/
void halLcdLine( int x1, int y1, int x2, int y2, unsigned char GrayScale) 
{
  int x, y, deltay, deltax, d;  
  int x_dir, y_dir;

  if ( x1 == x2 )
    halLcdVLine( x1, y1, y2, GrayScale );
  else
  {
    if ( y1 == y2 )
      halLcdHLine( x1, x2, y1, GrayScale );
    else                                    // a diagonal line
    {
      if (x1 > x2)
        x_dir = -1;
      else x_dir = 1;
      if (y1 > y2)
        y_dir = -1;
      else y_dir = 1;
      
      x = x1;
      y = y1;
      deltay = ABS(y2 - y1);
      deltax = ABS(x2 - x1);

      if (deltax >= deltay)
      {
        d = (deltay << 1) - deltax;
        while (x != x2)
        {
          halLcdPixel(x, y,  GrayScale);
          if ( d < 0 )
            d += (deltay << 1);
          else
          {
            d += ((deltay - deltax) << 1);
            y += y_dir;
          }
          x += x_dir;
        }                
      }
      else
      {
        d = (deltax << 1) - deltay;
        while (y != y2)
        {
          halLcdPixel(x, y, GrayScale);
          if ( d < 0 )
            d += (deltax << 1);
          else
          {
            d += ((deltax - deltay) << 1);
            x += x_dir;
          }
          y += y_dir;
        }        
      }
    }  
  }
}


/**********************************************************************//**
 * @brief  Draw a circle of Radius with center at (x,y) of GrayScale level.
 *         
 * Uses Bresenham's circle algorithm
 * 
 * @param  x         x-coordinate of the circle's center point
 * 
 * @param  y         y-coordinate of the circle's center point
 * 
 * @param  Radius    Radius of the circle
 * 
 * @param  GrayScale Grayscale level of the circle 
 *************************************************************************/
void halLcdCircle(int x, int y, int Radius, int GrayScale)
{
  int xx, yy, ddF_x, ddF_y, f;
  
  ddF_x = 0;
  ddF_y = -(2 * Radius);
  f = 1 - Radius;

  xx = 0;
  yy = Radius;
  halLcdPixel(x + xx, y + yy, GrayScale);
  halLcdPixel(x + xx, y - yy, GrayScale);
  halLcdPixel(x - xx, y + yy, GrayScale);
  halLcdPixel(x - xx, y - yy, GrayScale);
  halLcdPixel(x + yy, y + xx, GrayScale);
  halLcdPixel(x + yy, y - xx, GrayScale);
  halLcdPixel(x - yy, y + xx, GrayScale);
  halLcdPixel(x - yy, y - xx, GrayScale);
  while (xx < yy)
  {
    if (f >= 0)
    {
      yy--;
      ddF_y += 2;
      f += ddF_y;
    }
    xx++;
    ddF_x += 2;
    f += ddF_x + 1;
    halLcdPixel(x + xx, y + yy, GrayScale);
    halLcdPixel(x + xx, y - yy, GrayScale);
    halLcdPixel(x - xx, y + yy, GrayScale);
    halLcdPixel(x - xx, y - yy, GrayScale);
    halLcdPixel(x + yy, y + xx, GrayScale);
    halLcdPixel(x + yy, y - xx, GrayScale);
    halLcdPixel(x - yy, y + xx, GrayScale);
    halLcdPixel(x - yy, y - xx, GrayScale);
  }
}

/**********************************************************************//**
 * @brief  Scrolls a single row of pixels one column to the left. 
 * 
 * The column that is scrolled out of the left side of the LCD will be 
 * displayed the right side of the LCD. 
 * 
 * @param  y    The row of pixels to scroll. y = 0 is at the top-left
 *              corner of the LCD. 
 * 
 * @return none
 *************************************************************************/
void halLcdScrollRow(int y)
{
  int i, Address, LcdTableAddressTemp;
  unsigned int temp;
  
  Address = y << 5;
  
  halLcdSetAddress( Address );
  
  //Multiplied by (1+16) and added by the offset
  LcdTableAddressTemp = y + (y << 4);       
  temp = ((LCD_MEM[LcdTableAddressTemp] & 0x0003) <<14);
  
  for (i = 0; i < 0x10; i++)      
    halLcdDrawCurrentBlock( ( (LCD_MEM[LcdTableAddressTemp+i] & 0xFFFC ) >> 2 ) \
    + ((LCD_MEM[LcdTableAddressTemp+i+1] & 0x0003) << 14 ));
    
  halLcdDrawCurrentBlock( (( LCD_MEM[LcdTableAddressTemp + 0x10] & 0xFFFC ) >> 2) + temp);    
}

/**********************************************************************//**
 * @brief  Scrolls multiple rows of pixels, yStart to yEnd, 
 *         one column to the left. 
 * 
 * The column that is scrolled out of the left side of the LCD will be 
 * displayed the right side of the LCD. y = 0 is at the top-left of the 
 * LCD screen.
 * 
 * @param  yStart The beginning row to be scrolled
 * 
 * @param  yEnd   The last row to be scrolled 
 * 
 * @return none
 *************************************************************************/
void halLcdHScroll(int yStart, int yEnd)
{
  int i ;  
  
  for (i = yStart; i < yEnd+1; i++)
    halLcdScrollRow(i);
}

/**********************************************************************//**
 * @brief  Scrolls a line of text one column to the left. 
 * 
 * @param  Line The line of text to be scrolled.  
 * 
 * @return none
 *************************************************************************/
void halLcdScrollLine(int Line)
{
  int i, Row ;
  
  Row = Line * FONT_HEIGHT;
  
  for (i = Row; i < Row + FONT_HEIGHT ; i++)
    halLcdScrollRow(i);
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日本sm残虐另类| 亚洲综合免费观看高清完整版| 在线免费观看日本一区| 国产成人午夜高潮毛片| 精品一区二区三区免费视频| 视频精品一区二区| 亚洲精品日韩一| 亚洲精品亚洲人成人网在线播放| 中文字幕日韩精品一区| 国产精品美女久久久久久| 久久蜜臀精品av| 久久久www成人免费无遮挡大片| 日韩精品最新网址| 久久女同性恋中文字幕| 国产欧美一区二区三区网站| 久久精品人人做人人爽97| 亚洲国产精品99久久久久久久久| 中文字幕不卡一区| 亚洲欧美在线观看| 一区二区免费在线播放| 亚洲国产精品尤物yw在线观看| 亚洲一区二区不卡免费| 日韩精品色哟哟| 久久成人免费电影| 成人性生交大片免费看中文| 99re亚洲国产精品| 欧美日韩一区不卡| 精品国产一区久久| 国产精品青草综合久久久久99| 国产精品不卡在线| 首页欧美精品中文字幕| 久久99久久99| 99久久99久久精品免费观看| 欧美日韩大陆在线| 国产三级欧美三级日产三级99| 国产精品美女久久久久久久久久久| 亚洲精品大片www| 看电影不卡的网站| 91丨porny丨中文| 日韩午夜av一区| 综合欧美亚洲日本| 久久精品国产精品亚洲红杏| yourporn久久国产精品| 欧美日韩精品欧美日韩精品一 | 亚洲欧美日韩中文播放| 亚洲国产精品一区二区www在线| 日本欧美肥老太交大片| 成人免费的视频| 日韩欧美在线影院| 有码一区二区三区| 成人一区二区三区在线观看| 91精品国产综合久久久蜜臀粉嫩 | 18成人在线视频| 天天影视涩香欲综合网| 成人美女视频在线看| 日韩视频123| 亚洲电影你懂得| 色综合久久综合网欧美综合网| 亚洲精品一区二区三区福利| 一区二区不卡在线播放| 国产91对白在线观看九色| 日韩亚洲欧美中文三级| 亚洲国产成人av网| 色婷婷久久久综合中文字幕| 国产亚洲欧美日韩在线一区| 蜜臀精品久久久久久蜜臀| 欧美三级韩国三级日本一级| 综合欧美亚洲日本| 白白色 亚洲乱淫| 中文字幕av一区二区三区| 激情综合色综合久久综合| 在线播放中文字幕一区| 亚洲第一久久影院| 欧美三级视频在线| 偷拍与自拍一区| 欧美美女直播网站| 亚洲3atv精品一区二区三区| 色国产综合视频| 一区二区三区欧美亚洲| 日本韩国欧美在线| 一区二区三区毛片| 欧美日韩一区二区电影| 偷窥国产亚洲免费视频| 欧美色倩网站大全免费| 亚洲二区在线观看| 4438成人网| 奇米888四色在线精品| 日韩欧美国产一区二区三区| 美女一区二区三区| 久久久国际精品| 成人av资源在线| 亚洲人成人一区二区在线观看| 99国产精品国产精品久久| 亚洲免费毛片网站| 欧美情侣在线播放| 国产自产2019最新不卡| 日本一区二区综合亚洲| 91影院在线观看| 婷婷久久综合九色综合绿巨人 | 国产一区二区导航在线播放| 精品国产123| 99热国产精品| 亚洲国产精品久久人人爱蜜臀| 欧美色精品天天在线观看视频| 日韩av成人高清| 久久久www免费人成精品| 94-欧美-setu| 男人的天堂亚洲一区| 国产调教视频一区| 欧洲精品一区二区| 国内精品久久久久影院色 | 一本久久a久久免费精品不卡| 亚洲在线视频网站| 久久夜色精品国产噜噜av| 91免费视频大全| 精品一区二区在线视频| 亚洲同性gay激情无套| 欧美一级高清片在线观看| 成人爽a毛片一区二区免费| 亚洲国产日韩一区二区| 国产欧美精品区一区二区三区 | 欧美一区二区国产| 成人18精品视频| 久久疯狂做爰流白浆xx| 中文字幕佐山爱一区二区免费| 欧美一区二区不卡视频| 91免费视频网址| 国产成人午夜高潮毛片| 日韩成人精品在线观看| 亚洲婷婷国产精品电影人久久| 精品免费一区二区三区| 欧美午夜电影在线播放| 岛国精品在线播放| 黄色日韩三级电影| 三级在线观看一区二区| 亚洲精品日日夜夜| 国产精品久久久久久久久免费相片| 欧美一区二区三区爱爱| 91福利在线观看| 99在线精品观看| 成人丝袜高跟foot| 国产成人综合在线播放| 奇米777欧美一区二区| 天天色综合天天| 香蕉久久夜色精品国产使用方法| 中文字幕一区二区三区蜜月| 精品国产免费人成电影在线观看四季| 欧美视频日韩视频在线观看| 91在线porny国产在线看| 成+人+亚洲+综合天堂| 国产制服丝袜一区| 国产麻豆午夜三级精品| 国产一区在线不卡| 国产在线精品一区二区| 激情伊人五月天久久综合| 美国十次综合导航| 狂野欧美性猛交blacked| 男女男精品视频| 精品影视av免费| 国产一区二区三区久久悠悠色av| 麻豆国产一区二区| 国产中文一区二区三区| 高潮精品一区videoshd| 成人免费毛片嘿嘿连载视频| 懂色av中文字幕一区二区三区| 丁香亚洲综合激情啪啪综合| 国产aⅴ精品一区二区三区色成熟| 国产不卡视频在线播放| eeuss鲁片一区二区三区在线看| 99视频热这里只有精品免费| 99久久精品国产一区二区三区 | 777午夜精品视频在线播放| 欧美日韩国产免费| 日韩欧美在线观看一区二区三区| 欧美一区二区三区的| 久久综合久久鬼色| 国产精品国产三级国产普通话蜜臀| 国产精品国产三级国产普通话99 | 欧美成人一级视频| 久久九九全国免费| 亚洲色图清纯唯美| 秋霞午夜av一区二区三区| 极品少妇一区二区三区精品视频| 风间由美一区二区三区在线观看 | 国产精品小仙女| 99久久久无码国产精品| 欧美日韩午夜精品| 久久久三级国产网站| 亚洲精选一二三| 激情深爱一区二区| 色久综合一二码| 精品日韩av一区二区| |精品福利一区二区三区| 日韩av不卡在线观看| 成a人片国产精品| 日韩欧美国产不卡| 亚洲欧美日韩人成在线播放| 美国欧美日韩国产在线播放| 成人动漫在线一区| 精品入口麻豆88视频|