public int DisplayLcd(string displayStr) { E7Lib.fw_lcd_dispclear(iDevice); int result = E7Lib.fw_lcd_dispstr(iDevice, displayStr); return(result); }
public void showStringLCD2Lines(string strLCDLine1, string strLCDLine2) { E7Lib.fw_lcd_dispclear(iDevice); if (iDevice <= 0) { return; } StringBuilder sb = new StringBuilder(strLCDLine1); while (sb.Length < 18) { sb.Append(" "); } sb.Append(strLCDLine2); while (sb.Length < 36) { sb.Append(" "); } E7Lib.fw_lcd_dispstr(iDevice, sb.ToString()); //E7Lib.fw_lcd_dispstr_ex(iDevice, strLCDLine1.PadRight(36,' '), 1, 0, strLCDLine1.Length, 1); //E7Lib.fw_lcd_dispstr_ex(iDevice, strLCDLine2.PadRight(36,' '), 2, 0, strLCDLine2.Length, 1); }
public string closeDevice() { if (iDevice <= 0) { return("无当前设备"); } try { //关闭LCD setLCDBright(false); //清空显示文本 E7Lib.fw_lcd_dispclear(iDevice); //关闭设备 E7Lib.fw_exit(iDevice); return("OK"); } catch (Exception ex) { return(ex.Message); } }
public void showString2LCD(string strLCD) { strLCD.PadLeft(36, ' ');//空格补齐,不然会有乱码 E7Lib.fw_lcd_dispclear(iDevice); E7Lib.fw_lcd_dispstr(iDevice, strLCD); }
public void clearLCDShow() { E7Lib.fw_lcd_dispclear(iDevice); }
public void initLCDShow() { E7Lib.fw_lcd_dispclear(iDevice); showString2LCD("天天100"); }