3047 views|1 replies

6

Posts

0

Resources
The OP
 

51 single chip microcomputer [Copy link]

How can I modify this program of 51 single chip microcomputer so that the function ends when the switch is pressed again? I am new to 51 single chip microcomputer and would like to ask for your advice. Thank you very much

7716e74917fd41ad.png (0 Bytes, downloads: 0)

7716e74917fd41ad.png
This post is from 51mcu

Latest reply

This post was last edited by damiaa on 2021-12-17 12:51 Check that the key is pressed and the timer is turned off. However, after the end, it is best to scan the digital tube again to give a fixed display value. Or turn it off (that is, give p0 a value you want). You can also not turn off the timer, just set a flag, the flag is initially 0, the timer will display it when the flag is 0, otherwise it will not be displayed. Then your main program will change this flag according to the key press situation.   Details Published on 2021-12-17 12:47
 

6069

Posts

4

Resources
2
 
This post was last edited by damiaa on 2021-12-17 12:51

Check that the key is pressed and the timer is turned off. However, after the end, it is best to scan the digital tube again to give a fixed display value. Or turn it off (that is, give p0 a value you want).

You can also not turn off the timer, just set a flag, the flag is initially 0, the timer will display it when the flag is 0, otherwise it will not be displayed. Then your main program will change this flag according to the key press situation.

This post is from 51mcu
 
 
 

Guess Your Favourite
Just looking around
Find a datasheet?

EEWorld Datasheet Technical Support

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews

Room 1530, Zhongguancun MOOC Times Building, Block B, 18 Zhongguancun Street, Haidian District, Beijing 100190, China Tel:(010)82350740 Postcode:100190

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京B2-20211791 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号
快速回复 返回顶部 Return list