Discussion in "8051 Discussion Forum" started by    kmag1953    Apr 29, 2018.
Sun Apr 29 2018, 07:26 PM
#1
I need help on how to write a serial input timeout – the sample code in C that I need with 8051 microcontrollers. The input serial timeout is that if there is no key pressed from the PC for more than 60 seconds, then the program should display a timeout.

Mon Apr 30 2018, 06:59 PM
#2
This sounds like a homework question, so we don't supply code.
One way would be to use the timer to generate interrupts every 50mS.
In the interrupt handler add one to a count.

When a character arrives clear the count.
If the count ever reaches 60*20, display the timeout message.


[ Edited Tue May 01 2018, 06:21 AM ]

Get Social

Information

Powered by e107 Forum System

Conversation

Sun May 20 2018, 06:01 PM
justinb
how to write and execute a program that read the keypad button and display the number on 7 segment on intel8051 at89s52 in assembly language?
Sun May 20 2018, 05:56 PM
justinb
how to write and execute a program that read the keypad button and diplay the number on 7 segment ?
Sun May 20 2018, 01:44 PM
StephenTitly
https://coindump.biz/?ref=0110ce0e15d11860f5c787dd7668239a
Thu May 17 2018, 02:36 PM
HAMZA TAJ
sir iwant to ask about controller of three phase supply by using back to back thyristor instead of triac....will u give me some guideline?
Sat Apr 28 2018, 08:54 PM
ashutosh jain
IR Remote Switch using TV remote (RC5 Protocol) is not working properly. opp1 & opp2 is in problem.plz help
ExperimenterUK
Sat Apr 28 2018, 04:09 AM
@kaiserslautern Post in forum
Wed Apr 25 2018, 03:09 PM
kaiserslautern
Hello everyone, using software uart is a very good idea for a second serial port. Thank you so much. I would kindly like to know how to connect this port to the PC?
ExperimenterUK
Sun Apr 22 2018, 03:50 AM
This is a community site. Feel free to help anyone needing advice
hareeshchamiyar
Thu Mar 29 2018, 06:47 PM
please help me for the configuration bits for dspic30f2010
hareeshchamiyar
Thu Mar 29 2018, 06:45 PM
can any one using dspic30f2010.

Downloads

Comments

bdmehta
Tue May 22 2018, 02:30 AM
kmag1953
Sun Apr 29 2018, 07:09 PM
udiwonder
Sat Apr 28 2018, 12:41 PM
pirpiri
Sat Apr 21 2018, 03:35 PM
Pater
Fri Apr 20 2018, 02:38 PM
jamiel
Sat Apr 14 2018, 12:47 AM
akrepkral76
Wed Apr 04 2018, 07:51 PM
samanthaeaves
Mon Apr 02 2018, 06:27 AM

Online

Guests: 42, Members: 0 ...

most ever online: 182184
(Members: , Guests: 182184) on 06 Aug 2010: 05:37 AM

Members: 37998
Newest member: bdmehta
Forum Activity
ExperimenterUK Avatar
Posted By ExperimenterUK
Mon May 14 2018, 10:17 PM
So the main problem is that I am not getting Analo...
ExperimenterUK Avatar
Posted By ExperimenterUK
Mon May 14 2018, 09:40 PM
Hi sir after checking all the connection i...
Pater Avatar
Posted By Pater
Mon May 14 2018, 05:36 PM
Basically my project is based on Data Acquisition ...
LAMBO Avatar
Posted By LAMBO
Sun May 13 2018, 02:13 PM
Hi sir after checking all the connection i...
ExperimenterUK Avatar
Posted By ExperimenterUK
Mon May 07 2018, 07:27 PM
This design should be fine.Choose a frequency betw...
Pater Avatar
Posted By Pater
Mon May 07 2018, 01:28 PM
Sorry for late reply as exams were on,Based on my ...
ExperimenterUK Avatar
Posted By ExperimenterUK
Thu May 03 2018, 03:32 PM
If the circuit works with a light bulb, the probl...
LAMBO Avatar
Posted By LAMBO
Thu May 03 2018, 08:04 AM
Hi sir as u mentioned above everthing is working...
ExperimenterUK Avatar
Posted By ExperimenterUK
Wed May 02 2018, 08:28 PM
Thanks for the video clip, it's a good idea.Electr...
LAMBO Avatar
Posted By LAMBO
Wed May 02 2018, 10:53 AM
Hi sir did the changes as per instructions. ...