MS Hyperterminal UART Communication

Hi All,

I am trying to communicate with a black box reciever with its onchip uar tuned to 115200 bps, 8 data bits, and 1 stop bit. I am sending a text fil of size 105KB to the reciever from my PC through the Hyperterminal but wit a character delay of 1 ms. If i dont keep that character delay, i dont ge the required acks back from the reciever. And sending with a 1ms dela takes about 28 minutes to get into the reciever and give me vali acknowledgement.

Please help me configure out a way for this problem and also why at 11520 bps, this much time should be taken...

Thanx in Advance for those who care to reply...

Reply to
sundar_1984
Loading thread data ...

You're not saying anything about the receiver. Is it your own product/design, or did you purchase it ?

Perhaps it doesn't have a Rx FIFO, and it takes some time to process each character.

Reply to
Arlet

This is a problem crying out for an oscilloscope. You need to take a look at the time delay between the transmission of your character and the receipt of the ACK character. If that time is less than about

1 millisecond, and the time between transmitted character the problem is with Windows and Hyperterm.

Windows is notoriously bad with programmmed delays---they often end up being some multiple of the old DOS time tick---which is about 55 milliseconds, IIRC. It may be that Hyperterm is really extending your desired 1Msec delay to 18msec.

You could also figure that out by examining the output from Hyperterm with an oscilloscope. Since you may not have one handy, I did this test for you---and voila! The time between characters with a specified

1mSec character delay is somewhere between 10 and 20 milliseconds--- and varies greatly. This seems to support the hypothesis that Hyperterm is using a delay routine with a clock that ticks at somewhere between 50 and 60Hz.

I think you need to figure out how to do this transfer without the character delays. If you really need an ack for each character, your transmission time should depend on the speed with which the receiver can fetch the input character and send the ACK.

Mark Borgerson

Reply to
Mark Borgerson

Maybe your device uses hardware handshaking signals to indicate to the host (e.g. hyperterm) that it is ready to receive data. Check if your box' manual says anything about the type of handshaking and cable that should be used.

--
:wq
^X^Cy^K^X^C^C^C^C
Reply to
Ico

After dealing with Hyperterminal for many years, I find that a good working hypothesis is:

"It's Hyperterminal's fault."

Start by getting a decent terminal emulator. Teraterm is free and way, way better than HT. There are other free terminal emulators as well. All are vastly better than Hyperterminal.

HT is a waste of bits.

--
Grant Edwards                   grante             Yow!  I'm thinking about
                                  at               DIGITAL READ-OUT systems
                               visi.com            and computer-generated
                                                   IMAGE FORMATIONS...
Reply to
Grant Edwards

Seconded, also this sounds suspiciously like a (cheap) USB-Serial adapter is being used - is it the case?

Chris.

Reply to
chris

That could be -- I didn't think to ask about that.

Unfortunately paying more doesn't always mean it's going to work better. Some of the cheap ones work fine, some of the expensive ones don't.

They all seem to work better under Linux than Windows (at least for me).

Even with the ones that work fine, trying to do anything with them that requires precise timing is futile. With a USB adapter, you can't expect to something like a 1ms delay between characters.

Even with an directly connected UART getting reliable 1ms delays between bytes just isn't going to happen unless you're using an RTOS.

--
Grant Edwards                   grante             Yow!  Yes, but will I
                                  at               see the EASTER BUNNY in
                               visi.com            skintight leather at an
                                                   IRON MAIDEN concert?
Reply to
Grant Edwards

Thirded! ;)

Regards,

-- Mark McDougall, Engineer Virtual Logic Pty Ltd,

21-25 King St, Rockdale, 2216 Ph: +612-9599-3255 Fax: +612-9599-3266
Reply to
Mark McDougall

On single processor NT/2000 systems the Sleep(1) nominally 1 ms delay would be about 0-10 ms, on multiprocessor systems 0-16 ms. However, if the multimedia timers are enabled, Sleep(1) would at least try to sleep for about 1 ms, of course there can be large variations depending of load, even when the program executes in the realtime priority class.

Paul

Reply to
Paul Keinanen

I use a cheap USB-Serial adapter and it works a whole lot better than hyperterminal.

I like Com7.6 as a com program, but it won't run faster than 115,200 even though the USB/Serial will run at 921,600.

Scott

Reply to
Not Really Me

I have a usb-serial adapter that I was suprised to find that total transfer time was halved compared to a conventional serial port in one particular application (both under Linux). The application sends out a character and then waits for it to be echoed back before sending the next character. I have used the adapter on several different flavours of Linux and it behaved the same. Suprised.

Regards,

Paul.

Reply to
Paul Taylor

You probably could have sped up the conventional serial port drastically by setting the low latency flag and setting the RX FIFO size to 1 on the device using the setserial program. By default, the Linux serial drivers are set up to be optimal for things like PPP that transfer largish blocks of data (more than

10ms worth).

The default configuration is it's pretty sub-optimal for things like sending a single byte and waiting for a single byte to come back.

--
Grant Edwards                   grante             Yow!  .. does your DRESSING
                                  at               ROOM have enough ASPARAGUS?
                               visi.com
Reply to
Grant Edwards

Thanks for info. Next time I use the software I'll investigate further.

Regards,

Paul.

Reply to
Paul Taylor

Like everything else from that place. Teraterm works nicely for me (during unfortunate periods of running Windows).

Reply to
toby

Setting aside that pretty much anything that can drive a serial port on Windows works a whole lot better than Hypoterminal, that statement doesn't make any sense at all. You just stated an analogon of: "I use a cheap car and it works a whole lot better than a pair of trousers".

Reply to
Hans-Bernhard Bröker

Hi i m sorry for i could not reply to this post at the earliest. Frankly i wasnt aware that posts can also be on the usenet and not only b mail.

Well the recievr is not mine. it has reciver FIFO enabled but its 1 byte.

Reply to
sundar_1984

Sorry Guys for the delay. Ws out of college on a vactiona ndnow i m back. Well, after reading all the posts to this query the following points ar cleared further.:

  1. No i dont use a usb-serial adapter.
  2. I use only the RS232 Cable to connect to my receever and my PC>
  3. I have tried this thing out with TeraTerm also and i find that i nee to have that 1ms delay there too to get the valid ack messages.
  4. the reciver is not mine. I dont hve the source code for the reciever else there wouldnt hve been any problem at all in debugin the transfer.
  5. As far as i recall enabling/disabling the FIFO does not have any efec on slwoing the transfer bcoz everything is controlled by the LSR only i this case of No flow control applications.

Awaiting further replies...

Thanx

Reply to
sundar_1984

Lacking any quotations, your reply is totally meaningless. Every article should stand by itself. Previous traffic may, in fact probably, is not available to your readers.

--
Chuck F (cbfalconer at maineline dot net)
   Available for consulting/temporary embedded and systems.
Reply to
CBFalconer

by

byte.

Sorry Guys for the delay. Ws out of college on a vactiona ndnow i m back. Well, after reading all the posts to this query the following points are cleared further.:

  1. No i dont use a usb-serial adapter.
  2. I use only the RS232 Cable to connect to my receever and my PC>
  3. I have tried this thing out with TeraTerm also and i find that i need to have that 1ms delay there too to get the valid ack messages.
  4. the reciver is not mine. I dont hve the source code for the reciever, else there wouldnt hve been any problem at all in debugin the transfer.
  5. As far as i recall enabling/disabling the FIFO does not have any efect on slwoing the transfer bcoz everything is controlled by the LSR only in this case of No flow control applications.

Awaiting further replies...

Thanx

Reply to
sundar_1984

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.