Rules | Recent posts | topic RSS | Search | Register  | Log in

how to send enter key

 
Post new topic  Reply to topic    EDAboard.com Forum Index -> PC Programming and Interfacing
Author Message
chardbiggie



Joined: 19 Dec 2004
Posts: 15
Helped: 1


Post06 Jan 2005 18:55   how to send enter key

i am using a ds89c420 microcontroller to answer a cal via modem, the at command for answering a call is ATA, so i burn the command print "ATA" to my microcontroller( i am using Basic language) , the problem is that for the modem to execute the command an enter key or carriage return must be executed how will i burn this to a microcontroller...

in short the enter key what is its equivalent string or how would i burn it on a microcontroller

hope u guys could help
Back to top
checkmate



Joined: 25 Feb 2004
Posts: 489
Helped: 35
Location: Toilet Seat


Post06 Jan 2005 19:06   Re: how to send enter key

In most cases, the <Enter> key is normally associated with the carriage return, which is denoted by ASCII character 13.
Back to top
pisoiu



Joined: 31 Dec 2002
Posts: 889
Helped: 24
Location: Romania


Post06 Jan 2005 19:07   how to send enter key

The equivalent hexadecimal sequence of <cr><lf> is 0x0D 0x0A, or if you want in decimal, 13,10. Just send this using SBUF and it will work.
Back to top
chardbiggie



Joined: 19 Dec 2004
Posts: 15
Helped: 1


Post06 Jan 2005 19:38   how to send enter key

yeah i already read that how would i execute it using BASIC language?
would
print "ATA"
print "13"

do the trick?

how????
please help thanks!!!!
Back to top
checkmate



Joined: 25 Feb 2004
Posts: 489
Helped: 35
Location: Toilet Seat


Post06 Jan 2005 20:09   Re: how to send enter key

The last time I coded in BASIC is at least a decade ago. Anyway, I remember BASIC uses the chr$(13) function. Not too sure about PICBASIC. According to here, they did mention a chr() function. Probably it's the same.
Back to top
Post new topic  Reply to topic    EDAboard.com Forum Index -> PC Programming and Interfacing
Page 1 of 1 All times are GMT + 1 Hour


Abuse
Administrator
Moderators
topic RSS 
sitemap