-
不好说,哪里都可能有问题。
-
段分配有问题。
-
能给个提示么?或者给个截图什么的,好让我直接能找到,因为我现在很忙也很着急需要这个,谢谢!
-
Reference Input Range
REF IN(+) – REF IN(–) Voltage 1/1.75 V min/max VDD = 2.7 V to 3.3 V. VREF = 1.225 ± 1% for Specified Performance
REF IN(+) – REF IN(–) Voltage 1/3.5 V min/max VDD = 4.75 V to 5.25 V. VREF = 2.5 ± 1% for Specified Performance
你不要看别人怎么做,如果你自己设计,严格按照手册上去做。如果想看别人的接到5V时是什么样子,你也可以做一下实验
-
汇编人得习惯,老是喜欢跟编译器抢饭碗。
这点东西交给编译器去优化吧。
-
何为“旋转电子钟”?是360度旋转显示还是摆动显示?
-
//==============================================//
// Filename: C8051f320_SMC1602A_Display.c //
// //
// Prozessor: C8051f320 //
// Compiler: Keil C51 7.06 //
// //
// Author: Paul.Jia //
// QQ: 79974439 //
// Copyright: MKL PSC TSD //
//==============================================//
//================================================
//1. SYSCLK is unlimited here
//2. Display by SMC1602A
//
//Use 3 ports for control
//Use 8 ports for data communications
//And initialize them right in the Main
//
//Need ms delay function from the Main
// extern void delay_ms(unsigned short ms);
//
//Need initialize before use the diaplay function
// void LCMInit(void);
//
//Export these 2 function
// void DisplayOneChar(unsigned char X, unsigned char Y, unsigned char DData);
// void DisplayListChar(unsigned char X, unsigned char Y, unsigned char *DData);
//================================================
//----------------------------
// Include Files
//----------------------------
#include
#include
//----------------------------
// Global Constants
//----------------------------
// Define control ports and data ports
// P0.5 - digital push-pull (1602)RS
// P0.6 - digital push-pull (1602)RW
// P0.7 - digital push-pull (1602)E
// P1.x - digital push-pull (1602)DATA
// Have to initalize these ports in the Main
//
sbit RS1602 = P0 ^ 5; // Register select signal port
sbit RW1602 = P0 ^ 6; // Data read/write port
sbit E1602 = P0 ^ 7; // Enable signal port
#define DATA1602 P1 // Data port
// Define macro definition basic the selected ports
//
#define W_D_IN P1MDOUT &= 0x00 // Change Data port to open-drain
#define W_D_OUT P1MDOUT |= 0xFF // Change Data port to push-pull
// Define device busy flag
//
#define Busy 0x80
//----------------------------
// Function Prototypes
//----------------------------
// Write data to SMC1602A
//
void WriteDataLCM(unsigned char WDLCM);
// Write command to SMC1602A
//
void WriteCommandLCM(unsigned char WCLCM, unsigned char BusyC);
// Read data from SMC1602A
//
unsigned char ReadDataLCM(void);
// Read command from SMC602A
//
unsigned char ReadStatusLCM(void);
// Initalize SMC1602A
//
void LCMInit(void);
// Display a char at the specified position
//
void DisplayOneChar(unsigned char X, unsigned char Y, unsigned char DData);
// Display a string at the specified position
//
void DisplayListChar(unsigned char X, unsigned char Y, unsigned char *DData);
// Call a extern ms delay function
//
extern void delay_ms(unsigned short ms);
//----------------------------
// Subroutines
//----------------------------
//-----------------Write Data---------------------
void WriteDataLCM(unsigned char WDLCM)
//------------------------------------------------
{
ReadStatusLCM(); // Detect Busy
W_D_OUT; // Change Data port to push-pull
DATA1602 = WDLCM; // Write data
RS1602 = 1; // LCM_RS = 1;
RW1602 = 0; // LCM_RW = 0;
E1602 = 0; // LCM_E = 0; If SYSCLK is high, add a small delay into here
delay_ms(4);
E1602 = 1; // LCM_E = 1;
}
//----------------Write Command-------------------
void WriteCommandLCM(unsigned char WCLCM, unsigned char BusyC)
//------------------------------------------------
{
if(BusyC) // Decide if detect Busy from parameter
{
ReadStatusLCM(); // Detect Busy
}
W_D_OUT; // Change Data port to push-pull
DATA1602 = WCLCM; // Write command
RS1602 = 0; // LCM_RS = 0;
RW1602 = 0; // LCM_RW = 0;
E1602 = 0; // LCM_E = 0; If SYSCLK is high, add a small delay into here
delay_ms(4);
E1602 = 1; // LCM_E = 1;
}
/*
//------------------Read Data---------------------
unsigned char ReadDataLCM(void)
//------------------------------------------------
{
RS1602 = 1; // LCM_RS = 1;
RW1602 = 1; // LCM_RW = 1;
E1602 = 0; // LCM_E = 0; If SYSCLK is high, add a small delay into here
delay_ms(4);
E1602 = 1; // LCM_E = 1;
W_D_IN; // Change Data port to open-drain
return DATA1602; // Return data
}
*/
//-----------------Read Command-------------------
unsigned char ReadStatusLCM(void)
//------------------------------------------------
{
W_D_IN; // Change Data port to open-drain
RS1602 = 0; // LCM_RS = 0;
RW1602 = 1; // LCM_RW = 1;
E1602 = 0; // LCM_E = 0; If SYSCLK is high, add a small delay into here
delay_ms(4);
E1602 = 1; // LCM_E = 1;
while(DATA1602 & Busy); // Detect Busy
return DATA1602; // Return data
}
//------------------Initalize---------------------
void LCMInit(void)
//------------------------------------------------
{
DATA1602 = 0;
WriteCommandLCM(0x38, 0); // Set display mode 3 times, no detect Busy
delay_ms(5);
WriteCommandLCM(0x38, 0);
delay_ms(5);
WriteCommandLCM(0x38, 0);
delay_ms(5);
// Keep above code
WriteCommandLCM(0x38, 1); // Set display mode(8 bits, 2 rows, 5x7), begin detect Busy everytime
WriteCommandLCM(0x08, 1); // Close display
WriteCommandLCM(0x01, 1); // Clear screen
WriteCommandLCM(0x06, 1); // Show the position of cursor move
WriteCommandLCM(0x0C, 1); // Show boot-strap cursor setting
WriteCommandLCM(0x80, 1); // The first position is row 1 line 1
}
//----------------Display one char----------------
void DisplayOneChar(unsigned char X, unsigned char Y, unsigned char DData)
//------------------------------------------------
{
Y &= 0x1;
X &= 0xF; // Revise X
-
楼主的系统有什么特别的吗?一般来说,这个似乎不会改变的。
你的initdb.ini在哪个目录下?
-
又可以直接烧录的烧录器,便携(跟公交刷卡机的外观类似)式,可使用电池和外部电源,并且可以烧录多种芯片
-
版主贴主早上好!
版主贴主每天都有好心情!
SOT8tDb3Wxswacfq回帖是一种美德!HotkU6PSAA84s7hF
==========================
介+绍:
[/url]
BfS04Td1B1TrhFUf
1)可录制上网记录,截获Http信息。
2)利用截获的Http信息自动生成命令(Page,拖拽即可完成)
3)执行命令,模拟浏览器向Web服务器发生命令。
中文论坛:[url=http://spritebrowser.com/LunTan]
SOT8tDb3Wxswacfq
要看美女来这里:
[url=http://byhat.com][/url]
=======================
软件创业QQ 群:103815692
K8pyaLAHec2aJGL4
-
SetPowerRequirement.或者用DeviceIOControl
-
顶,
-
LED_On(LED2);
while(1){} 你的代码在这里死循环,调不到LED_Off,所以LED2常亮
LED_Off(LED2);
请问为何能从任务2的无限循环中仍然能进行任务调度?
OSTaskCreate( taskLED1, (void *)0, &GstkLED1[TASK_LED_STK_SIZE-1],1 );
OSTaskCreate(taskLED2, (void *)0,&GstkLED2[TASK_LED_STK_SIZE-1],2 );
那是因为你创建TASK时优先级优先及不同,TASK1的优先级高于TASK2的优先级
如果你把两个优先级换一下,LED1就不会闪了。
-
这个问题最好还是 当面说 找个精通的高手面授 这里说不清
-
那是内部传感器,一般情况是要用来在内部RTC修正用吧,因为芯片本身就发热,怎么能用来测室温呢=。=
-
可能是波特率设置不对。
-
其实百个一百左右的开发板也不是用来开发什么产品,只是为了更快入门,学会怎么用汇编语言、C语言控制单片机做一些事
-
如果用一片FPGA,
就用XILINX公司的XCS30XL-4PQG208C,封装为:PQFP208,也是贴片,
大体技术参数为:3.3V+1368LEs+169I/O
价格在80元人民币左右,看你和代理商或者厂家的关系。
-
实际使用PTC,NTC或RTD来测温,都使用电桥来实现。设置电桥参数可以达到热电阻的电流小于1mA。电阻取1%的就OK了。
-
2年前想软硬通吃,给碰的头破血流的人,飘过