问答

汇集网友智慧,解决技术难题

kbkbk

TA的家园币:10  

  • 我这个程序用单片机数码管显示相关内容 反映很慢

    #include"reg52.h"#include"HX711.h"#include"uart.h"#include"LCD1602.h"#include"temp.h"typedefunsignedcharu8;typedefunsignedintu16;u16KEY_NUM=0;unsignedlongHX711_Buffer=0;unsignedlongWeight_Maopi=0;Weight_Shiwu=0;bitFlag_OK=0;sbitkey_stop=P3^0;sbitkey_star=P3^1;sbitkey_fen=P3^2;sbitkey_shi=P3^3;sbitLSA=P2^2;sbitLSB=P2^3;sbitLSC=P2^4;u8DisplayDataTemp[8];u8DisplayWeight[8];u8DisplayData[8];u8codesmgduan[11]={0x3f,0x06,0x5b,0x4f,0x66,0x6d,0x7d,0x07,0x7f,0x67,0x6f};u8miao=0;u8fen=0;u8shi=0;u8miao_L,miao_H,fen_L,fen_H,shi_L,shi_H;u8State=1;u16counter=0;voiddelay(u16x){//ÑÓʱº¯Êýwhile(x--);}//delayvoidDelay_ms(u16n){u16i,j;for(i=0;i

    单片机

    2022-03-06 3