Making a terminal program work
Archiver
Posts: 46,084
Hi ...
I've been having great fun writing and running programs on my BS2.
I have no problems running a debug window and getting DEBUG output.
But I want to capture serial data from the stamp in another program.
As a first step, I'd like to see data from the stamp in a terminal
program. I have a fine terminal emulator called SecureCRT
(www.vandyke.com).
I connect to the stamp at 9600 baud, 8 data bits, parity off, 1 stop
bit. I turn off all the flow control. It seems like the data should
come rolling in.
I see typed characters echoed back to the terminal program, so that
would seem to verify the physical connection, right? But no data from
my program that writes perfectly to the stampw debug window.
Any ideas?
Best regards,
Mojo
--
Morris Jones <*>
San Rafael, CA
mojo@w...
http://www.whiteoaks.com
I've been having great fun writing and running programs on my BS2.
I have no problems running a debug window and getting DEBUG output.
But I want to capture serial data from the stamp in another program.
As a first step, I'd like to see data from the stamp in a terminal
program. I have a fine terminal emulator called SecureCRT
(www.vandyke.com).
I connect to the stamp at 9600 baud, 8 data bits, parity off, 1 stop
bit. I turn off all the flow control. It seems like the data should
come rolling in.
I see typed characters echoed back to the terminal program, so that
would seem to verify the physical connection, right? But no data from
my program that writes perfectly to the stampw debug window.
Any ideas?
Best regards,
Mojo
--
Morris Jones <*>
San Rafael, CA
mojo@w...
http://www.whiteoaks.com
Comments
Are you sure your terminal program keeps
the DTR line low (better still, disconnect the DTR line).
greetings peter
Oorspronkelijk bericht
Van: Morris Jones [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=MmStxCEOu-I9fWWTYfNpPpVrwSNrLIaw4iOyKeuOj40et2CDJqfkRQQ0ilnSmlCJy_jnJf9QXtRjQQ]mojo@w...[/url
Verzonden: woensdag 19 september 2001 08:52
Aan: basicstamps@yahoogroups.com
Onderwerp: [noparse][[/noparse]basicstamps] Making a terminal program work
Hi ...
I've been having great fun writing and running programs on my BS2.
I have no problems running a debug window and getting DEBUG output.
But I want to capture serial data from the stamp in another program.
As a first step, I'd like to see data from the stamp in a terminal
program. I have a fine terminal emulator called SecureCRT
(www.vandyke.com).
I connect to the stamp at 9600 baud, 8 data bits, parity off, 1 stop
bit. I turn off all the flow control. It seems like the data should
come rolling in.
I see typed characters echoed back to the terminal program, so that
would seem to verify the physical connection, right? But no data from
my program that writes perfectly to the stampw debug window.
Any ideas?
Best regards,
Mojo
--
Morris Jones <*>
San Rafael, CA
mojo@w...
http://www.whiteoaks.com
To UNSUBSCRIBE, just send mail to:
basicstamps-unsubscribe@yahoogroups.com
from the same email address that you subscribed. Text in the Subject and
Body of the message will be ignored.
Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
that my problem is something fundamental and I'm not getting it, but not
a common problem. [noparse]:)[/noparse]
Meaning no one else has trouble making a stamp write data to a terminal
program.
Still, though it appears that the stamp is running a program that does
nothing but write to the serial port, and I can see the output fine in
a stampw debug window, all I can do from a terminal program or from my
own program is get echoes back of sent characters.
If I unplug the stamp from the serial port, the echoes quit.
I just don't quite understand why the BASIC Stamp Editor debug window
would work, but a terminal program wouldn't. Does anyone have any
insight to offer on this?
I'm on Windows 2000 with a generic PC, and I'm writing in Visual C++,
or using any number of serial comm programs for testing.
Best regards,
Mojo
On Wed, 19 Sep 2001, Morris Jones wrote:
> Hi ...
>
> I've been having great fun writing and running programs on my BS2.
> I have no problems running a debug window and getting DEBUG output.
>
> But I want to capture serial data from the stamp in another program.
>
> As a first step, I'd like to see data from the stamp in a terminal
> program. I have a fine terminal emulator called SecureCRT
> (www.vandyke.com).
>
> I connect to the stamp at 9600 baud, 8 data bits, parity off, 1 stop
> bit. I turn off all the flow control. It seems like the data should
> come rolling in.
>
> I see typed characters echoed back to the terminal program, so that
> would seem to verify the physical connection, right? But no data from
> my program that writes perfectly to the stampw debug window.
>
> Any ideas?
>
> Best regards,
> Mojo
>
--
Morris Jones <*>
San Rafael, CA
mojo@w...
http://www.whiteoaks.com
The Stamp programming connection echos back any character sent to it (it's a
hardware thing and can't be changed or disabled). Your software needs to
filter the echoed characters. The Stamp DEBUG window "knows" about this and
deals with it accordingly.
-- Jon Williams
-- Applications Engineer, Parallax
In a message dated 9/22/01 12:41:24 PM Central Daylight Time,
mojo@w... writes:
> I wrote this last Wednesday, and got no responses. So that tells me
> that my problem is something fundamental and I'm not getting it, but not
> a common problem. [noparse]:)[/noparse]
>
> Meaning no one else has trouble making a stamp write data to a terminal
> program.
>
> Still, though it appears that the stamp is running a program that does
> nothing but write to the serial port, and I can see the output fine in
> a stampw debug window, all I can do from a terminal program or from my
> own program is get echoes back of sent characters.
>
> If I unplug the stamp from the serial port, the echoes quit.
>
> I just don't quite understand why the BASIC Stamp Editor debug window
> would work, but a terminal program wouldn't. Does anyone have any
> insight to offer on this?
>
> I'm on Windows 2000 with a generic PC, and I'm writing in Visual C++,
>
[noparse][[/noparse]Non-text portions of this message have been removed]
But I only tried "sending" characters to see if the connection was live.
The problem is that I'm not getting any characters at all from the stamp
program whether I send any or not, except if I use the debug window.
I'm going to try tracking down a serial port monitor today and see if I
can tell if data is being sent out the port or not, or if the program
is running or not.
(There's no reason to believe that a program stops running when you close
the debug window, is there?)
Best regards,
Mojo
On Sat, 22 Sep 2001 jonwms@a... wrote:
> Mojo:
>
> The Stamp programming connection echos back any character sent to it (it's a
> hardware thing and can't be changed or disabled). Your software needs to
> filter the echoed characters. The Stamp DEBUG window "knows" about this and
> deals with it accordingly.
>
> -- Jon Williams
> -- Applications Engineer, Parallax
>
>
> In a message dated 9/22/01 12:41:24 PM Central Daylight Time,
> mojo@w... writes:
>
>
> > I wrote this last Wednesday, and got no responses. So that tells me
> > that my problem is something fundamental and I'm not getting it, but not
> > a common problem. [noparse]:)[/noparse]
> >
> > Meaning no one else has trouble making a stamp write data to a terminal
> > program.
> >
> > Still, though it appears that the stamp is running a program that does
> > nothing but write to the serial port, and I can see the output fine in
> > a stampw debug window, all I can do from a terminal program or from my
> > own program is get echoes back of sent characters.
> >
> > If I unplug the stamp from the serial port, the echoes quit.
> >
> > I just don't quite understand why the BASIC Stamp Editor debug window
> > would work, but a terminal program wouldn't. Does anyone have any
> > insight to offer on this?
> >
> > I'm on Windows 2000 with a generic PC, and I'm writing in Visual C++,
> >
>
>
>
>
> [noparse][[/noparse]Non-text portions of this message have been removed]
>
>
> To UNSUBSCRIBE, just send mail to:
> basicstamps-unsubscribe@yahoogroups.com
> from the same email address that you subscribed. Text in the Subject and Body
of the message will be ignored.
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
--
Morris Jones <*>
San Rafael, CA
mojo@w...
http://www.whiteoaks.com
>that my problem is something fundamental and I'm not getting it, but not
>a common problem. [noparse]:)[/noparse]
Hi Morris,
You did get a response from Peter, which pointed out the likely
problem. Your terminal program is probably holding the DTR line
high. That is the reset signal into the BASIC Stamp that goes into
pin 4 on the DB9 connector and into pin 3 on the BASIC Stamp IC. The
debug terminal leaves that line low, and that is why you see the data
coming onto your debug screen but not the terminal program. On the
upper right hand edge of the Debug screen you will see a checkbox for
DTR and it starts out unchecked. If you check it, the DTR line will
be forced high and your stamp will go into reset.
What you need to do to make it work with your terminal program is
1) disconnect the DTR signal line
or
2) insert a capacitor (~0.1uf) in series between the DTR line and
pin 3 on the Stamp. That will make the Stamp reset when DTR first
goes high, but then it can operate normally. I think that is the way
most BASIC Stamp systems are configured.
>Meaning no one else has trouble making a stamp write data to a terminal
>program.
DTR is usually the culprit.
>Still, though it appears that the stamp is running a program that does
>nothing but write to the serial port, and I can see the output fine in
>a stampw debug window, all I can do from a terminal program or from my
>own program is get echoes back of sent characters.
>
>If I unplug the stamp from the serial port, the echoes quit.
>
>I just don't quite understand why the BASIC Stamp Editor debug window
>would work, but a terminal program wouldn't. Does anyone have any
>insight to offer on this?
>
>I'm on Windows 2000 with a generic PC, and I'm writing in Visual C++,
>or using any number of serial comm programs for testing.
>
>Best regards,
>Mojo
>
>
>
>On Wed, 19 Sep 2001, Morris Jones wrote:
>
> > Hi ...
> >
> > I've been having great fun writing and running programs on my BS2.
> > I have no problems running a debug window and getting DEBUG output.
> >
> > But I want to capture serial data from the stamp in another program.
> >
> > As a first step, I'd like to see data from the stamp in a terminal
> > program. I have a fine terminal emulator called SecureCRT
> > (www.vandyke.com).
> >
> > I connect to the stamp at 9600 baud, 8 data bits, parity off, 1 stop
> > bit. I turn off all the flow control. It seems like the data should
> > come rolling in.
> >
> > I see typed characters echoed back to the terminal program, so that
> > would seem to verify the physical connection, right? But no data from
> > my program that writes perfectly to the stampw debug window.
> >
> > Any ideas?
> >
> > Best regards,
> > Mojo
> >
>
>--
>Morris Jones <*>
>San Rafael, CA
>mojo@w...
>http://www.whiteoaks.com
problem. Thank you!
Best regards,
Mojo
On Sat, 22 Sep 2001, Tracy Allen wrote:
> >I wrote this last Wednesday, and got no responses. So that tells me
> >that my problem is something fundamental and I'm not getting it, but not
> >a common problem. [noparse]:)[/noparse]
>
> Hi Morris,
> You did get a response from Peter, which pointed out the likely
> problem. Your terminal program is probably holding the DTR line
> high. That is the reset signal into the BASIC Stamp that goes into
> pin 4 on the DB9 connector and into pin 3 on the BASIC Stamp IC. The
> debug terminal leaves that line low, and that is why you see the data
> coming onto your debug screen but not the terminal program. On the
> upper right hand edge of the Debug screen you will see a checkbox for
> DTR and it starts out unchecked. If you check it, the DTR line will
> be forced high and your stamp will go into reset.
>
> What you need to do to make it work with your terminal program is
> 1) disconnect the DTR signal line
> or
> 2) insert a capacitor (~0.1uf) in series between the DTR line and
> pin 3 on the Stamp. That will make the Stamp reset when DTR first
> goes high, but then it can operate normally. I think that is the way
> most BASIC Stamp systems are configured.
>
> >Meaning no one else has trouble making a stamp write data to a terminal
> >program.
>
> DTR is usually the culprit.
>
> >Still, though it appears that the stamp is running a program that does
> >nothing but write to the serial port, and I can see the output fine in
> >a stampw debug window, all I can do from a terminal program or from my
> >own program is get echoes back of sent characters.
> >
> >If I unplug the stamp from the serial port, the echoes quit.
> >
> >I just don't quite understand why the BASIC Stamp Editor debug window
> >would work, but a terminal program wouldn't. Does anyone have any
> >insight to offer on this?
> >
> >I'm on Windows 2000 with a generic PC, and I'm writing in Visual C++,
> >or using any number of serial comm programs for testing.
> >
> >Best regards,
> >Mojo
> >
> >
> >
> >On Wed, 19 Sep 2001, Morris Jones wrote:
> >
> > > Hi ...
> > >
> > > I've been having great fun writing and running programs on my BS2.
> > > I have no problems running a debug window and getting DEBUG output.
> > >
> > > But I want to capture serial data from the stamp in another program.
> > >
> > > As a first step, I'd like to see data from the stamp in a terminal
> > > program. I have a fine terminal emulator called SecureCRT
> > > (www.vandyke.com).
> > >
> > > I connect to the stamp at 9600 baud, 8 data bits, parity off, 1 stop
> > > bit. I turn off all the flow control. It seems like the data should
> > > come rolling in.
> > >
> > > I see typed characters echoed back to the terminal program, so that
> > > would seem to verify the physical connection, right? But no data from
> > > my program that writes perfectly to the stampw debug window.
> > >
> > > Any ideas?
> > >
> > > Best regards,
> > > Mojo
> > >
> >
> >--
> >Morris Jones <*>
> >San Rafael, CA
> >mojo@w...
> >http://www.whiteoaks.com
>
>
> To UNSUBSCRIBE, just send mail to:
> basicstamps-unsubscribe@yahoogroups.com
> from the same email address that you subscribed. Text in the Subject and Body
of the message will be ignored.
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
--
Morris Jones <*>
San Rafael, CA
mojo@w...
http://www.whiteoaks.com
there any extra characters before the debug message? If so, I would suspect
that the Stamp Debug window is receiving some sort of code to tell it the
data being sent is a debug command. If your PC does not send the code, the
Debug window would ignore it. This is pure speculation since I use a
different method to talk to a PC.
As far as the echoing, this is a normal feature when using a serial
connection with PIN16 on a BS2
Original Message
> I wrote this last Wednesday, and got no responses. So that tells me
> that my problem is something fundamental and I'm not getting it, but not
> a common problem. [noparse]:)[/noparse]
>
> Meaning no one else has trouble making a stamp write data to a terminal
> program.
>
> Still, though it appears that the stamp is running a program that does
> nothing but write to the serial port, and I can see the output fine in
> a stampw debug window, all I can do from a terminal program or from my
> own program is get echoes back of sent characters.
>
> If I unplug the stamp from the serial port, the echoes quit.
>
> I just don't quite understand why the BASIC Stamp Editor debug window
> would work, but a terminal program wouldn't. Does anyone have any
> insight to offer on this?
>
> I'm on Windows 2000 with a generic PC, and I'm writing in Visual C++,
> or using any number of serial comm programs for testing.
program does stop.
Original Message
> But I only tried "sending" characters to see if the connection was live.
> The problem is that I'm not getting any characters at all from the stamp
> program whether I send any or not, except if I use the debug window.
>
> I'm going to try tracking down a serial port monitor today and see if I
> can tell if data is being sent out the port or not, or if the program
> is running or not.
>
> (There's no reason to believe that a program stops running when you close
> the debug window, is there?)