• 大小: 2.37MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-08-10
  • 语言: 其他
  • 标签: stm32  

资源简介

改写的stm32嵌入式停车场赛题程序,2011年 年 “ 国信长天杯 ” ” 第三届

资源截图

代码片段和文件信息

/*
  程序说明: CT117E嵌入式竞赛板LCD驱动程序
  软件环境: Keil uVision 4.10 
  硬件环境: CT117E嵌入式竞赛板
  日    期: 2011-8-9
*/
#include “lcd.h“
#include “fonts.h“

static  vu16 TextColor = 0x0000 BackColor = 0xFFFF;
vu16 dummy;

/*******************************************************************************
* Function Name  : Delay_LCD
* Description    : Inserts a delay time.
* Input          : nCount: specifies the delay time length.
* Output         : None
* Return         : None
*******************************************************************************/
void Delay_LCD(u16 n)
{
u16 ij;
for (i = 0;i for(j=0;j<3000;++j);
}

/*
uC8230型液晶控制器寄存器配置
*/
void REG_8230_Init(void)
{
LCD_WriteReg(0x00000x0001);
Delay_LCD(1000); 
LCD_WriteReg(0x00010x0000);
LCD_WriteReg(0x00100x1790);
LCD_WriteReg(0x00600x2700);
LCD_WriteReg(0x00610x0001);
LCD_WriteReg(0x00460x0002);
LCD_WriteReg(0x00130x8010);
LCD_WriteReg(0x00120x80fe);
LCD_WriteReg(0x00020x0500);
LCD_WriteReg(0x00030x1030);

LCD_WriteReg(0x00300x0303);
LCD_WriteReg(0x00310x0303);
LCD_WriteReg(0x00320x0303);
LCD_WriteReg(0x00330x0300);
LCD_WriteReg(0x00340x0003);
LCD_WriteReg(0x00350x0303);
LCD_WriteReg(0x00360x0014);
LCD_WriteReg(0x00370x0303);
LCD_WriteReg(0x00380x0303);
LCD_WriteReg(0x00390x0303);
LCD_WriteReg(0x003a0x0300);
LCD_WriteReg(0x003b0x0003);
LCD_WriteReg(0x003c0x0303);
LCD_WriteReg(0x003d0x1400);
  
LCD_WriteReg(0x00920x0200);
LCD_WriteReg(0x00930x0303);
LCD_WriteReg(0x00900x080d); 
LCD_WriteReg(0x00030x1018); 
LCD_WriteReg(0x00070x0173);
}

void REG_932X_Init(void)
{
LCD_WriteReg(R227 0x3008);   // Set internal timing
LCD_WriteReg(R231 0x0012); // Set internal timing
LCD_WriteReg(R239 0x1231);   // Set internal timing
LCD_WriteReg(R1   0x0000); // set SS and SM bit   //0x0100
LCD_WriteReg(R2   0x0700); // set 1 line inversion
LCD_WriteReg(R3   0x1030);   // set GRAM write direction and BGR=1.
LCD_WriteReg(R4   0x0000);   // Resize register
LCD_WriteReg(R8   0x0207);   // set the back porch and front porch
LCD_WriteReg(R9   0x0000);   // set non-display area refresh cycle ISC[3:0]
LCD_WriteReg(R10  0x0000);   // FMARK function
LCD_WriteReg(R12  0x0000); // RGB interface setting
LCD_WriteReg(R13  0x0000);   // frame marker Position
LCD_WriteReg(R15  0x0000); // RGB interface polarity
/**************Power On sequence ****************/
LCD_WriteReg(R16  0x0000);   // SAP BT[3:0] AP DSTB SLP STB
LCD_WriteReg(R17  0x0007);   // DC1[2:0] DC0[2:0] VC[2:0]
LCD_WriteReg(R18  0x0000); // VREG1OUT voltage
LCD_WriteReg(R19  0x0000);   // VDV[4:0] for VCOM amplitude
Delay_LCD(1000);                    // Delay 200 MS  Dis-charge capacitor power voltage
LCD_WriteReg(R16  0x1690);   // SAP BT[3:0] AP DSTB SLP STB
LCD_WriteReg(R17  0x0227); // R11H=0x0221 at VCI=3.3V DC1[2:0] DC0[2:0] VC[2:0]
Delay_LCD(50);   

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Inc\
     文件       24057  2019-01-17 14:21  停车场\CT117E-LCD\Inc\fonts.H
     文件        6166  2019-01-17 14:21  停车场\CT117E-LCD\Inc\lcd.h
     文件        3288  2019-01-17 14:21  停车场\CT117E-LCD\Inc\stm32f10x_conf.h
     文件        1989  2019-01-17 14:21  停车场\CT117E-LCD\Inc\stm32f10x_it.h
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Libraries\
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Libraries\CMSIS\
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Libraries\CMSIS\CM3\
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Libraries\CMSIS\CM3\CoreSupport\
     文件       17273  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\CoreSupport\core_cm3.c
     文件       85714  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\CoreSupport\core_cm3.h
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\
     文件       26297  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\Release_Notes.html
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\arm\
     文件       15766  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\arm\startup_stm32f10x_cl.s
     文件       15503  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\arm\startup_stm32f10x_hd.s
     文件       15692  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\arm\startup_stm32f10x_hd_vl.s
     文件       12376  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\arm\startup_stm32f10x_ld.s
     文件       13656  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\arm\startup_stm32f10x_ld_vl.s
     文件       12765  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\arm\startup_stm32f10x_md.s
     文件       14073  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\arm\startup_stm32f10x_md_vl.s
     文件       15955  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\arm\startup_stm32f10x_xl.s
     文件       11307  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\arm\STM32F10x.s
     目录           0  2019-02-24 21:42  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\gcc_ride7\
     文件       13072  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\gcc_ride7\startup_stm32f10x_cl.s
     文件       13160  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\gcc_ride7\startup_stm32f10x_hd.s
     文件       12482  2019-01-17 14:21  停车场\CT117E-LCD\Libraries\CMSIS\CM3\DeviceSupport\ST\STM32F10x\startup\gcc_ride7\startup_stm32f10x_hd_vl.s
............此处省略148个文件信息

评论

共有 条评论