POV-Ray : Newsgroups : povray.off-topic : The joy of RS-232 Server Time
4 Sep 2024 19:20:37 EDT (-0400)
  The joy of RS-232 (Message 1 to 10 of 12)  
Goto Latest 10 Messages Next 2 Messages >>>
From: Invisible
Subject: The joy of RS-232
Date: 27 Nov 2009 10:42:58
Message: <4b0ff382$1@news.povray.org>
OK, so I've got a device with an RS-232 port, and it's expecting there 
to be a laser printer on the other end of it.

If I connect this thing to COM1: on my PC, is there some way to capture 
the data it's spewing out in a file? If I can do that, I should be able 
to actually send the file to a printer. (It looks like it's attempting 
to generate either PCL or PS, so this should work.)

I was hoping that just saying COPY COM1: File1 would work, but it doesn't.

According to the manual:

"Only hardware handshake (CTS/RTR) is supported. One start bit and one 
stop bit are always used (not selectable). Default settings are 
baud=9600, 8 data bits, no parity."

As best as I can tell, these are pretty much the default settings for a 
PC COM port.

Google is no help. (It seems loads of people want to *do* this, but 
nobody has a *solution*.)


Post a reply to this message

From: Invisible
Subject: Re: The joy of RS-232
Date: 27 Nov 2009 11:23:14
Message: <4b0ffcf2$1@news.povray.org>
Invisible wrote:

> If I connect this thing to COM1: on my PC, is there some way to capture 
> the data it's spewing out in a file?

Oh goodie. I just checked the manual, and it gives the following 
connection sequence for the cable:

Instrument <-> PC
   1 -> 1
   2 -> 3
   3 -> 2
   4 -> 6
   5 -> 5
   6 -> 4
   7 -> 8
   8 -> 7
   9 -> 9

Then I took the cable I'm using apart and deduced the following connections:

   1 -> 7
   2 -> 3
   3 -> 2
   4 -> 6, 8
   5 -> 5
   6 -> 9
   7 -> 4
   8 -> 1
   9 -> 4

Notice, especially, how multiple pins are connected to each other. Now 
I'm not completely sure my dad can count, so some of the pin numbers 
might be wrong. However, it is incontravertible that each plug contains 
a loop of wire commoning two pins together. The wiring diagram in the 
book contains no such link.

What is more puzzling is that this cable apparently works just fine when 
used with other equipment...

God damnit, I am literally *so glad* that RS-232 is obsolete now. It's a 
total PITA!! >_<


Post a reply to this message

From: Stephen
Subject: Re: The joy of RS-232
Date: 27 Nov 2009 11:32:08
Message: <4b0fff08$1@news.povray.org>
Invisible wrote:
> Invisible wrote:
> 

> What is more puzzling is that this cable apparently works just fine when 
> used with other equipment...
> 

Yes the RS232 was known to be the most non-standard, standard. Your 
cable pin assignment looks familiar but if you want it to work with your 
printer you will need to change it to the way specified in the manual. 
At least the connectors are solder-able.


> God damnit, I am literally *so glad* that RS-232 is obsolete now. It's a 
> total PITA!! >_<

:-)

-- 

Best Regards,
	Stephen


Post a reply to this message

From: Invisible
Subject: Re: The joy of RS-232
Date: 27 Nov 2009 11:41:51
Message: <4b10014f$1@news.povray.org>
>> What is more puzzling is that this cable apparently works just fine 
>> when used with other equipment...
> 
> Yes the RS232 was known to be the most non-standard, standard.

I just tried a different cable, which also supposedly works, and it has 
an entirely unrelated layout. Pin 6 is not connected at either and, and 
there's a 1-4 crossover. (Still, at least the connections are 
*symmetric* this time!)

So I tried a third lead. Didn't bother writing the connections down, but 
it has another arrangement again. Pin 1 connects to pin 8...

It seems that for any arbitrary cable, you will find a different random 
permutation of connections! >_<

And yet, these cables all "work", so maybe it's not even important? I 
notice that every single one of them has 5 straight and a 2-3 crossover, 
so maybe that's the only thing that actually matters?

> Your 
> cable pin assignment looks familiar but if you want it to work with your 
> printer you will need to change it to the way specified in the manual. 
> At least the connectors are solder-able.

Yeah, I think I'm going to have to make the cable my God-damned self if 
I want it to match the manual.

And hence apparently you can only WRITE TO, but not READ FROM the serial 
port from DOS, it won't solve my problem anyway.


Post a reply to this message

From: Fredrik Eriksson
Subject: Re: The joy of RS-232
Date: 27 Nov 2009 12:26:34
Message: <op.u32denpa7bxctx@bigfrog.bredbandsbolaget.se>
On Fri, 27 Nov 2009 17:41:50 +0100, Invisible <voi### [at] devnull> wrote:
>
> And hence apparently you can only WRITE TO, but not READ FROM the serial  
> port from DOS, it won't solve my problem anyway.

http://www.google.com/search?q=reading+from+serial+port+in+MS-DOS

This seems promising (scroll down to respone #6):
http://www.computing.net/answers/dos/read-serial-port-from-dos/14336.html


If you can hook the device to a computer running Windows 9x or XP, you  
could probably use HyperTerminal.



-- 
FE


Post a reply to this message

From: Le Forgeron
Subject: Re: The joy of RS-232
Date: 27 Nov 2009 12:32:12
Message: <4b100d1c$1@news.povray.org>
Le 27/11/2009 17:23, Invisible nous fit lire :
> Invisible wrote:
> 
>> If I connect this thing to COM1: on my PC, is there some way to
>> capture the data it's spewing out in a file?
> 
> Oh goodie. I just checked the manual, and it gives the following
> connection sequence for the cable:
> 
> Instrument <-> PC
>   1 -> 1
>   2 -> 3
>   3 -> 2
>   4 -> 6
>   5 -> 5
>   6 -> 4
>   7 -> 8
>   8 -> 7
>   9 -> 9
> 

DB-9 RS-232 is the worst kind of connector.
A DB-25 was clearer.

First question would be to know if the device expected to be a DTE or
DCE. As the remote end was a printer (probably more a basic printer, not
laser, at least not in PCL/PS/graphic mode), the instrument is probably
a DTE (like PC). DTE to DTE required that kind of crossing cable.
(DTE to DCE is flat, IIRC)


> Then I took the cable I'm using apart and deduced the following
> connections:
> 
>   1 -> 7
>   2 -> 3
>   3 -> 2
>   4 -> 6, 8

Classical ack shortcut... that's what happen when you use DTE - DTE...

>   5 -> 5
>   6 -> 9
>   7 -> 4
>   8 -> 1
>   9 -> 4
> 
> Notice, especially, how multiple pins are connected to each other. Now
> I'm not completely sure my dad can count, so some of the pin numbers
> might be wrong. However, it is incontravertible that each plug contains
> a loop of wire commoning two pins together. The wiring diagram in the
> book contains no such link.
> 
> What is more puzzling is that this cable apparently works just fine when
> used with other equipment...
> 
> God damnit, I am literally *so glad* that RS-232 is obsolete now. It's a
> total PITA!! >_<

You'd better try the com port either on windows (ultra terminal, IIRC,
wonder if still available in vista/7... look in communication package)
or linux (tip, or minicom (easier to setup))

You got the most important data: speed, number of start/stop bit (parity ??)

RS-232C is great... long lines, no problem.
You cannot do that with USB!


Post a reply to this message

From: Sabrina Kilian
Subject: Re: The joy of RS-232
Date: 27 Nov 2009 14:09:37
Message: <4b1023f1$1@news.povray.org>
Invisible wrote:
> Invisible wrote:
> 
>> If I connect this thing to COM1: on my PC, is there some way to
>> capture the data it's spewing out in a file?

Hyperterminal if you are on Win XP or 2k or anything before Vista. Not
sure about Windows 7, but I can not find hyperterminal in Vista. Can
always use PuTTY, or if you have them installed both the Arduino or PIC
IDEs should suffice.

> Oh goodie. I just checked the manual, and it gives the following
> connection sequence for the cable:

That isn't a particularly bad cable set up. Looping the ground pin to
other pins is one I have seen in a random cable. You get used to seeing
hacks like that.

> God damnit, I am literally *so glad* that RS-232 is obsolete now. It's a
> total PITA!! >_<

I finally got a computer that doesn't have a serial port, and am pissed
about it. Sure, I could keep lots of RS-232 to USB chips around for what
every circuit I am working with, but just dropping a serial cable into a
breadboard and throwing the data onto the line for debugging is much easier.


Post a reply to this message

From: Darren New
Subject: Re: The joy of RS-232
Date: 29 Nov 2009 13:13:34
Message: <4b12b9ce$1@news.povray.org>
Invisible wrote:
> Yeah, I think I'm going to have to make the cable my God-damned self if 
> I want it to match the manual.

Google for "rs232 jumper box".

> And hence apparently you can only WRITE TO, but not READ FROM the serial 
> port from DOS, it won't solve my problem anyway.

Why would you say such a thing?

-- 
Darren New, San Diego CA, USA (PST)
   Human nature dictates that toothpaste tubes spend
   much longer being almost empty than almost full.


Post a reply to this message

From: Invisible
Subject: Re: The joy of RS-232
Date: 30 Nov 2009 03:53:23
Message: <4b138803@news.povray.org>
>> And hence apparently you can only WRITE TO, but not READ FROM the 
>> serial port from DOS, it won't solve my problem anyway.
> 
> Why would you say such a thing?

Because of all the replies claiming that you can copy to but not from 
the COM port?


Post a reply to this message

From: Invisible
Subject: Re: The joy of RS-232
Date: 30 Nov 2009 03:54:30
Message: <4b138846$1@news.povray.org>
>>> If I connect this thing to COM1: on my PC, is there some way to
>>> capture the data it's spewing out in a file?
> 
> Hyperterminal if you are on Win XP or 2k or anything before Vista. Not
> sure about Windows 7, but I can not find hyperterminal in Vista. Can
> always use PuTTY, or if you have them installed both the Arduino or PIC
> IDEs should suffice.

How do you work Hyperterminal? It seems to be expecting a modem and 
demands to know dialing codes, etc.


Post a reply to this message

Goto Latest 10 Messages Next 2 Messages >>>

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.