Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

hyperterminal communication w/ 8051

Status
Not open for further replies.

spyghost

Junior Member level 2
Joined
Apr 10, 2004
Messages
24
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
293
hyperterminal hex commands

hi,

i wanted to control something through 8051 by interfacing it to my pc through hyperterminal. a simple diagram is shown:

PC(hyperterminal) <----> 8051 <----> [something to be controlled]

actually what i am after is the interface between PC & 8051. the interface to the something to be controlled is not a problem since it would vary on the application

here are some of my thoughts:
- i will use 8051 serial port since it is interfaced w/ pc serial
- i will only use 2 lines, tx & rx

from these thoughts, these questions rose:
- is it possible not to use AT commands?
- as a support to the previous question, can i develop my own commands such that what i can see in the hyperterminal window is a prompt that waits for a command?
- are the tx/rx lines from the serial port enough for the operation previously described? or do i still need to use the other control lines of the pc serial port?
 

hoangthanhtung

Full Member level 3
Joined
Apr 23, 2004
Messages
151
Helped
5
Reputation
10
Reaction score
4
Trophy points
1,298
Activity points
1,362
8051 hyperterminal

Hi

I think you can see 8051 monitor program in Intel website or read 8051 Microcontroller . This program support interface between PC and 8051 to control other device as : DC motor, step motor, LED board and more ...

I think this program is similar small operation system in 8051. It can receive the user's intruction from PC and do it and control peripheral.
 

spyghost

Junior Member level 2
Joined
Apr 10, 2004
Messages
24
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
293
hyperterminal ascii

hoangthanhtung said:
Hi
I think you can see 8051 monitor program in Intel website or read 8051 Microcontroller . This program support interface between PC and 8051 to control other device as : DC motor, step motor, LED board and more ...
do you still have the link available? i can't find the 8051 monitor program in intel website
hoangthanhtung said:
Hi
I think this program is similar small operation system in 8051. It can receive the user's intruction from PC and do it and control peripheral.
would it make any difference if i would use hyperterminal? as much as possible i would rather not go about doing another application to drive the uC operation since i am targeting a multi-platform approach (linux's, unix's have termnial programs like ms's hyperterm)
 

M!k

Advanced Member level 2
Joined
Apr 22, 2002
Messages
682
Helped
109
Reputation
218
Reaction score
35
Trophy points
1,308
Activity points
4,819
send hex over hyperterminal

Everything, including your own command set, depends on your 8051 firmware. You only have to configure hyperterminal to establish the connection without using the handshakesignals. That's all. If a "A" is pressed in hyterterminal the 8051 UART receives the character 0x65 ("A"). If a 0x66 is sent from the 8051 you'll see a "B" in hyperterminal. Wrapping the commands in a protocol (z-modem etc.) isn't necessary, but could be done.
The only reason to use another terminalprogram is that hyperterminal's behavior is sometimes a little bit strange and uncomfortable ...


Mik
 

spyghost

Junior Member level 2
Joined
Apr 10, 2004
Messages
24
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
293
hyperterminal hex

M!k said:
If a "A" is pressed in hyterterminal the 8051 UART receives the character 0x65 ("A"). If a 0x66 is sent from the 8051 you'll see a "B" in hyperterminal.
that's strange... (or is it just me) the equivalent of "A" in ascii is 0x41 right? 65 is decimal. does that mean hyperterm sends decimal values and not hex?
M!k said:
Wrapping the commands in a protocol (z-modem etc.) isn't necessary, but could be done.
i don't need to wrap it up, since it would cost additional instructions. all i am after right now is the direct link/communication between hyperterm and uC.
M!k said:
The only reason to use another terminalprogram is that hyperterminal's behavior is sometimes a little bit strange and uncomfortable ...
what terminal programs can you suggest for windows?
 

cdcll

Full Member level 3
Joined
Feb 15, 2002
Messages
163
Helped
8
Reputation
16
Reaction score
1
Trophy points
1,298
Activity points
1,199
8051 hyper terminal

windows has already had terminal programs in communication tools.
 

Antharax

Full Member level 4
Joined
Dec 31, 1999
Messages
208
Helped
14
Reputation
28
Reaction score
1
Trophy points
1,298
Activity points
2,865
hyperterminal communication

@ spyghost:
Hyperterminal is fine. As long as you don't use it from a laptop in WinXP at 115200 baud since it has problems then (don't ask me why, when i read the serial port it works)

and hyperterminal sends plain ascii. This means 'A' is send as 0x41 and 'a' is send as 0x61 (thats probably the mistake). There isn't something strange about it! But be carefull with selecting the options in Hyperterminal! Hardware Flow Control is on by default. It might be better to set it to none!!! Also check whether the parity and stop bits are equal to the ones used in the uC.

Antharax
 

gam

Advanced Member level 4
Joined
Mar 25, 2004
Messages
115
Helped
8
Reputation
16
Reaction score
4
Trophy points
1,298
Activity points
1,158
send hex hyperterminal

Hyperterminal sends only ASCII, however some of the Hex values can be typed with combinations of Ctrl + key or Alt + keys .

Check any ASCII table in a programming book or google for an ASCII table.

A very nice Terminal program where you can send Hex and Dec values at:\https://bray.velenje.cx/avr/terminal/

Regards,
Gam
 

M!k

Advanced Member level 2
Joined
Apr 22, 2002
Messages
682
Helped
109
Reputation
218
Reaction score
35
Trophy points
1,308
Activity points
4,819
hyperterminal communication with microcontroller

spyghost said:
M!k said:
If a "A" is pressed in hyterterminal the 8051 UART receives the character 0x65 ("A"). If a 0x66 is sent from the 8051 you'll see a "B" in hyperterminal.
that's strange... (or is it just me) the equivalent of "A" in ascii is 0x41 right? 65 is decimal. does that mean hyperterm sends decimal values and not hex?

ooops, of course my mistake. I mixed up the columns for hex and dec values in my ASCII table. "A" = 0x41 (hex) = 65 (dec)


Mik
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top