Embedded / RTOS

Moderators: None (Apply to moderate this forum)
Number of threads: 373
Number of posts: 682

This Forum Only
Post New Thread
Single Post View       Linear View       Threaded View      f

Report
RS232 transmission problem Posted by Jia on 14 Mar 2005 at 11:52 AM
This message was edited by Jia at 2005-3-15 8:33:3

Our C program control a device (connecting to RS232 port). We have Serial Port Monitor echo everything sent by the program.

In program, string 'SSS100' is sent to device consistently, but after a period time, no more 'SSS100' shows but 'less and equal' (one character, HEX F3) appears repeatly afterward. We don't know where '<='(F3) comes from and what do they mean.

What the problem seems to be? HW? SW?

Jia




Report
Re: RS232 transmission problem Posted by Lundin on 15 Mar 2005 at 1:30 PM
: This message was edited by Jia at 2005-3-15 8:33:3

: Our C program control a device (connecting to RS232 port). We have Serial Port Monitor echo everything sent by the program.
:
: In program, string 'SSS100' is sent to device consistently, but after a period time, no more 'SSS100' shows but 'less and equal' (one character, HEX F3) appears repeatly afterward. We don't know where '<='(F3) comes from and what do they mean.
:
: What the problem seems to be? HW? SW?
:
: Jia
:
:

It could be anything, a bug, noicy hardware, R232 lacking GND, too inaccurate baudrate settings etc etc
Report
Re: RS232 transmission problem Posted by johnsonme on 18 Mar 2005 at 6:31 AM
Hi,
Thats correct. Most probably, it is a timing problem. Try reducing the baud rates.
Regards,
Johnson.

: : This message was edited by Jia at 2005-3-15 8:33:3

: : Our C program control a device (connecting to RS232 port). We have Serial Port Monitor echo everything sent by the program.
: :
: : In program, string 'SSS100' is sent to device consistently, but after a period time, no more 'SSS100' shows but 'less and equal' (one character, HEX F3) appears repeatly afterward. We don't know where '<='(F3) comes from and what do they mean.
: :
: : What the problem seems to be? HW? SW?
: :
: : Jia
: :
: :
:
: It could be anything, a bug, noicy hardware, R232 lacking GND, too inaccurate baudrate settings etc etc
:

Report
Re: RS232 transmission problem Posted by gcurwen on 6 Apr 2005 at 11:45 AM
:Are you sure you are not over writing your data in you code? It sort of sounds like an array is being filled and eventually corrupting your string. If you have a baud rate problem or a timing problem you should be having consistently inconstant data.

Best,
Greg
:
:Hi,
: Thats correct. Most probably, it is a timing problem. Try reducing the baud rates.
: Regards,
: Johnson.
:
: : : This message was edited by Jia at 2005-3-15 8:33:3

: : : Our C program control a device (connecting to RS232 port). We have Serial Port Monitor echo everything sent by the program.
: : :
: : : In program, string 'SSS100' is sent to device consistently, but after a period time, no more 'SSS100' shows but 'less and equal' (one character, HEX F3) appears repeatly afterward. We don't know where '<='(F3) comes from and what do they mean.
: : :
: : : What the problem seems to be? HW? SW?
: : :
: : : Jia
: : :
: : :
: :
: : It could be anything, a bug, noicy hardware, R232 lacking GND, too inaccurate baudrate settings etc etc
: :
:
:

Report
Re: RS232 transmission problem Posted by evilguy on 7 Apr 2005 at 7:56 PM
: :Are you sure you are not over writing your data in you code? It sort of sounds like an array is being filled and eventually corrupting your string. If you have a baud rate problem or a timing problem you should be having consistently inconstant data.
:
: Best,
: Greg
: :
: :Hi,
: : Thats correct. Most probably, it is a timing problem. Try reducing the baud rates.
: : Regards,
: : Johnson.
: :
: : : : This message was edited by Jia at 2005-3-15 8:33:3

: : : : Our C program control a device (connecting to RS232 port). We have Serial Port Monitor echo everything sent by the program.
: : : :
: : : : In program, string 'SSS100' is sent to device consistently, but after a period time, no more 'SSS100' shows but 'less and equal' (one character, HEX F3) appears repeatly afterward. We don't know where '<='(F3) comes from and what do they mean.
: : : :
: : : : What the problem seems to be? HW? SW?
: : : :
: : : : Jia
: : : :
: : : :
: : :
: : : It could be anything, a bug, noicy hardware, R232 lacking GND, too inaccurate baudrate settings etc etc
: : :
: :
: :
:
:
sorry to ask here, can u write the code on how to passing string to serial port. and what library should i use. i'm developing my knowledge write program to control a hardware.
Report
Re: RS232 transmission problem Posted by Lundin on 8 Apr 2005 at 6:16 AM
: : :Are you sure you are not over writing your data in you code? It sort of sounds like an array is being filled and eventually corrupting your string. If you have a baud rate problem or a timing problem you should be having consistently inconstant data.
: :
: : Best,
: : Greg
: : :
: : :Hi,
: : : Thats correct. Most probably, it is a timing problem. Try reducing the baud rates.
: : : Regards,
: : : Johnson.
: : :
: : : : : This message was edited by Jia at 2005-3-15 8:33:3

: : : : : Our C program control a device (connecting to RS232 port). We have Serial Port Monitor echo everything sent by the program.
: : : : :
: : : : : In program, string 'SSS100' is sent to device consistently, but after a period time, no more 'SSS100' shows but 'less and equal' (one character, HEX F3) appears repeatly afterward. We don't know where '<='(F3) comes from and what do they mean.
: : : : :
: : : : : What the problem seems to be? HW? SW?
: : : : :
: : : : : Jia
: : : : :
: : : : :
: : : :
: : : : It could be anything, a bug, noicy hardware, R232 lacking GND, too inaccurate baudrate settings etc etc
: : : :
: : :
: : :
: :
: :
: sorry to ask here, can u write the code on how to passing string to serial port. and what library should i use. i'm developing my knowledge write program to control a hardware.
:

If you are using Windows there a several examples on these boards
(this is a very frequently asked question). Search the C/C++ boards for "RS-232" or "serial communication".

Report
Re: RS232 transmission problem Posted by Jia on 13 Apr 2005 at 7:31 AM
Thank you all.

We found there was noise in the hardware, causing the unexpected reset to a 'reset' pin. Haven't found what casues that noise. We can't change the baud rate because all devices' baud rate are fixed, defined by their manufactures.

Sorry Evilguy, I can't show you the source code, I am not that code developer. I believe you can find similar code from this web site and other sites.

Jia

: : : :Are you sure you are not over writing your data in you code? It sort of sounds like an array is being filled and eventually corrupting your string. If you have a baud rate problem or a timing problem you should be having consistently inconstant data.
: : :
: : : Best,
: : : Greg
: : : :
: : : :Hi,
: : : : Thats correct. Most probably, it is a timing problem. Try reducing the baud rates.
: : : : Regards,
: : : : Johnson.
: : : :
: : : : : : This message was edited by Jia at 2005-3-15 8:33:3

: : : : : : Our C program control a device (connecting to RS232 port). We have Serial Port Monitor echo everything sent by the program.
: : : : : :
: : : : : : In program, string 'SSS100' is sent to device consistently, but after a period time, no more 'SSS100' shows but 'less and equal' (one character, HEX F3) appears repeatly afterward. We don't know where '<='(F3) comes from and what do they mean.
: : : : : :
: : : : : : What the problem seems to be? HW? SW?
: : : : : :
: : : : : : Jia
: : : : : :
: : : : : :
: : : : :
: : : : : It could be anything, a bug, noicy hardware, R232 lacking GND, too inaccurate baudrate settings etc etc
: : : : :
: : : :
: : : :
: : :
: : :
: : sorry to ask here, can u write the code on how to passing string to serial port. and what library should i use. i'm developing my knowledge write program to control a hardware.
: :
:
: If you are using Windows there a several examples on these boards
: (this is a very frequently asked question). Search the C/C++ boards for "RS-232" or "serial communication".
:
:



 

Recent Jobs

Official Programmer's Heaven Blogs
Web Hosting | Browser and Social Games | Gadgets

Popular resources on Programmersheaven.com
Assembly | Basic | C | C# | C++ | Delphi | Flash | Java | JavaScript | Pascal | Perl | PHP | Python | Ruby | Visual Basic
© Copyright 2011 Programmersheaven.com - All rights reserved.
Reproduction in whole or in part, in any form or medium without express written permission is prohibited.
Violators of this policy may be subject to legal action. Please read our Terms Of Use and Privacy Statement for more information.
Operated by CommunityHeaven, a BootstrapLabs company.