SERIN auto-looping?
Archiver
Posts: 46,084
This one's got me really baffled. I'm using a BS2p24. I'm reading
output from a VB script. The data comes as one continuous stream of
30 numbers, but I wanted to separate the data into 6 sets of 5. I
had problems and began debugging the original code. The long and
short of it is, I got the code down to the following:
Data VAR BYTE
SERIN 16,16624,[noparse][[/noparse]DEC DATA]
SEROUT 14,16624,[noparse][[/noparse]DEC DATA,","]
END
Pin 14 is connected to a terminal prog on another PC to monitor
the data. I expected to see one number and comma come through and
nothing else, i.e.:
49,
However, it still receives and echoes all the data, and the output
looks like:
49,12,10,12,11,61,12,12,12,13,40,12,14,12,15,6,12,16,12,17,29,12,18,12
,19,16,12,20,12,21
Is SERIN and SEROUT causing some kind of auto-loop? Any ideas
what's going on? This is totally bizarre!
output from a VB script. The data comes as one continuous stream of
30 numbers, but I wanted to separate the data into 6 sets of 5. I
had problems and began debugging the original code. The long and
short of it is, I got the code down to the following:
Data VAR BYTE
SERIN 16,16624,[noparse][[/noparse]DEC DATA]
SEROUT 14,16624,[noparse][[/noparse]DEC DATA,","]
END
Pin 14 is connected to a terminal prog on another PC to monitor
the data. I expected to see one number and comma come through and
nothing else, i.e.:
49,
However, it still receives and echoes all the data, and the output
looks like:
49,12,10,12,11,61,12,12,12,13,40,12,14,12,15,6,12,16,12,17,29,12,18,12
,19,16,12,20,12,21
Is SERIN and SEROUT causing some kind of auto-loop? Any ideas
what's going on? This is totally bizarre!
Comments
-12V from the PC. If you are trying to "watch" both lines with port 16
or if your code on the other end is echoing that could cause a loop. You
can read more about the auto echo "feature" at the Stamp FAQ at
http://www.wd5gnr.com/faqs
Good luck!
Al Williams
AWC
* Floating point A/D
http://www.al-williams.com/awce/pak9.htm
>
Original Message
> From: mtlhead7 [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=mE7yyOfZGCk73rq7ABDvP_BoE24s5i2p9_P1XaVylt-ZsF8l1UG6T3_kcExednd3AeN8pv5Ikko2qZKeEWCTx5rOL0pmJQ]renegade.engineer@v...[/url
> Sent: Tuesday, May 28, 2002 7:02 PM
> To: basicstamps@yahoogroups.com
> Subject: [noparse][[/noparse]basicstamps] SERIN auto-looping?
>
>
> This one's got me really baffled. I'm using a BS2p24. I'm reading
> output from a VB script. The data comes as one continuous stream of
> 30 numbers, but I wanted to separate the data into 6 sets of 5. I
> had problems and began debugging the original code. The long and
> short of it is, I got the code down to the following:
>
> Data VAR BYTE
>
> SERIN 16,16624,[noparse][[/noparse]DEC DATA]
> SEROUT 14,16624,[noparse][[/noparse]DEC DATA,","]
>
> END
>
> Pin 14 is connected to a terminal prog on another PC to monitor
> the data. I expected to see one number and comma come through and
> nothing else, i.e.:
>
> 49,
>
> However, it still receives and echoes all the data, and the output
> looks like:
>
>
> 49,12,10,12,11,61,12,12,12,13,40,12,14,12,15,6,12,16,12,17,29,12,18,12
> ,19,16,12,20,12,21
>
> Is SERIN and SEROUT causing some kind of auto-loop? Any ideas
> what's going on? This is totally bizarre!
>
>
>
> 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/
>
I'm not sure I understand your answer. I tried the FAQ, but got no
results when I searched on 'auto' or 'echo' or both.
More info might help here. I'm transmitting from a simple output-only
VB script on one PC in through port 16 and then the stamp is forwarding what
it receives out port 14 to a receive-only terminal on another PC. This is
what I intended to happen. Where I'm confused is why the stamp is receiving
more than one piece of data. The code I spelled out below is supposed to
only get one number, relay that number and a comma, and stop. But it
doesn't. It continues to receive all the incoming numbers. That's the part
that I can't figure out. It should only get one number. The fact that it
continues to echo what it receives is unimportant.
Any ideas?
Don
Original Message
From: "Al Williams" <alw@a...>
To: <basicstamps@yahoogroups.com>
Sent: Tuesday, May 28, 2002 6:27 PM
Subject: RE: [noparse][[/noparse]basicstamps] SERIN auto-looping?
> Don't forget that port 16 always echos what you send it since it steals
> -12V from the PC. If you are trying to "watch" both lines with port 16
> or if your code on the other end is echoing that could cause a loop. You
> can read more about the auto echo "feature" at the Stamp FAQ at
> http://www.wd5gnr.com/faqs
>
> Good luck!
>
> Al Williams
> AWC
> * Floating point A/D
> http://www.al-williams.com/awce/pak9.htm
>
>
>
> >
Original Message
> > From: mtlhead7 [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=JGX_-OJau_uN289I7EUUGn4zrNpfWAL08SqHfU_Yd3Bm0ILP-cW2IRoAnhi_Ww8zN9lCfpmU4LN7yHZYthOFrJgroA]renegade.engineer@v...[/url
> > Sent: Tuesday, May 28, 2002 7:02 PM
> > To: basicstamps@yahoogroups.com
> > Subject: [noparse][[/noparse]basicstamps] SERIN auto-looping?
> >
> >
> > This one's got me really baffled. I'm using a BS2p24. I'm reading
> > output from a VB script. The data comes as one continuous stream of
> > 30 numbers, but I wanted to separate the data into 6 sets of 5. I
> > had problems and began debugging the original code. The long and
> > short of it is, I got the code down to the following:
> >
> > Data VAR BYTE
> >
> > SERIN 16,16624,[noparse][[/noparse]DEC DATA]
> > SEROUT 14,16624,[noparse][[/noparse]DEC DATA,","]
> >
> > END
> >
> > Pin 14 is connected to a terminal prog on another PC to monitor
> > the data. I expected to see one number and comma come through and
> > nothing else, i.e.:
> >
> > 49,
> >
> > However, it still receives and echoes all the data, and the output
> > looks like:
> >
> >
> > 49,12,10,12,11,61,12,12,12,13,40,12,14,12,15,6,12,16,12,17,29,12,18,12
> > ,19,16,12,20,12,21
> >
> > Is SERIN and SEROUT causing some kind of auto-loop? Any ideas
> > what's going on? This is totally bizarre!
> >
> >
> >
> > 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/
> >
>
>
> 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/
>
>
>
http://www.wd5gnr.com/faqs/index.php?qframe=1&faq=1&article=35
Not sure if that is your problem or not, but I'd wager that if you got
off port 16 your problem would mysteriously clear up.
Al Williams
AWC
* Easy RS-232 Prototyping
http://www.al-williams.com/awce/rs1.htm
>
Original Message
> From: Don [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=fIBz3NAVRCYihBw_9i1P7uvHkoLZA7Cs42o34DzmtdkHRvlXn1xYRXNs5jguTMSIRSn03GzYUmUQAdRMIWtbY-cWRwRO8J8]renegade.engineer@v...[/url
> Sent: Tuesday, May 28, 2002 9:47 PM
> To: basicstamps@yahoogroups.com
> Subject: Re: [noparse][[/noparse]basicstamps] SERIN auto-looping?
>
>
> Al
> I'm not sure I understand your answer. I tried the FAQ,
> but got no results when I searched on 'auto' or 'echo' or both.
> More info might help here. I'm transmitting from a
> simple output-only VB script on one PC in through port 16 and
> then the stamp is forwarding what it receives out port 14 to
> a receive-only terminal on another PC. This is what I
> intended to happen. Where I'm confused is why the stamp is
> receiving more than one piece of data. The code I spelled
> out below is supposed to only get one number, relay that
> number and a comma, and stop. But it doesn't. It continues
> to receive all the incoming numbers. That's the part that I
> can't figure out. It should only get one number. The fact
> that it continues to echo what it receives is unimportant.
> Any ideas?
> Don
>
Original Message
> From: "Al Williams" <alw@a...>
> To: <basicstamps@yahoogroups.com>
> Sent: Tuesday, May 28, 2002 6:27 PM
> Subject: RE: [noparse][[/noparse]basicstamps] SERIN auto-looping?
>
>
> > Don't forget that port 16 always echos what you send it since it
> > steals -12V from the PC. If you are trying to "watch" both
> lines with
> > port 16 or if your code on the other end is echoing that
> could cause a
> > loop. You can read more about the auto echo "feature" at
> the Stamp FAQ
> > at http://www.wd5gnr.com/faqs
> >
> > Good luck!
> >
> > Al Williams
> > AWC
> > * Floating point A/D http://www.al-williams.com/awce/pak9.htm
> >
> >
> >
> > >
Original Message
> > > From: mtlhead7 [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=fIBz3NAVRCYihBw_9i1P7uvHkoLZA7Cs42o34DzmtdkHRvlXn1xYRXNs5jguTMSIRSn03GzYUmUQAdRMIWtbY-cWRwRO8J8]renegade.engineer@v...[/url
> > > Sent: Tuesday, May 28, 2002 7:02 PM
> > > To: basicstamps@yahoogroups.com
> > > Subject: [noparse][[/noparse]basicstamps] SERIN auto-looping?
> > >
> > >
> > > This one's got me really baffled. I'm using a BS2p24. I'm
> > > reading output from a VB script. The data comes as one
> continuous
> > > stream of 30 numbers, but I wanted to separate the data
> into 6 sets
> > > of 5. I had problems and began debugging the original code. The
> > > long and short of it is, I got the code down to the following:
> > >
> > > Data VAR BYTE
> > >
> > > SERIN 16,16624,[noparse][[/noparse]DEC DATA]
> > > SEROUT 14,16624,[noparse][[/noparse]DEC DATA,","]
> > >
> > > END
> > >
> > > Pin 14 is connected to a terminal prog on another PC
> to monitor
> > > the data. I expected to see one number and comma come
> through and
> > > nothing else, i.e.:
> > >
> > > 49,
> > >
> > > However, it still receives and echoes all the data, and the
> > > output looks like:
> > >
> > >
> > >
> 49,12,10,12,11,61,12,12,12,13,40,12,14,12,15,6,12,16,12,17,29,12,18,
> > > 12
> > > ,19,16,12,20,12,21
> > >
> > > Is SERIN and SEROUT causing some kind of auto-loop? Any ideas
> > > what's going on? This is totally bizarre!
> > >
> > >
> > >
> > > 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/
> > >
> >
> >
> > 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/
> >
> >
> >
>
>
>
> 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/
help!!
Don
Original Message
From: "Al Williams" <alw@a...>
To: <basicstamps@yahoogroups.com>
Sent: Tuesday, May 28, 2002 8:01 PM
Subject: RE: [noparse][[/noparse]basicstamps] SERIN auto-looping?
> The article in question is
> http://www.wd5gnr.com/faqs/index.php?qframe=1&faq=1&article=35
>
> Not sure if that is your problem or not, but I'd wager that if you got
> off port 16 your problem would mysteriously clear up.
>
> Al Williams
> AWC
> * Easy RS-232 Prototyping
> http://www.al-williams.com/awce/rs1.htm
>
>
>
> >
Original Message
> > From: Don [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=N160dJapl1w49AGEjsrFvXxUjDyPjaPcz0-42QhDNhlUXTiyfnK0W8N-RTRhCDLCIlObvUgrv26B8FcTTGRDzMQQRP_SwA]renegade.engineer@v...[/url
> > Sent: Tuesday, May 28, 2002 9:47 PM
> > To: basicstamps@yahoogroups.com
> > Subject: Re: [noparse][[/noparse]basicstamps] SERIN auto-looping?
> >
> >
> > Al
> > I'm not sure I understand your answer. I tried the FAQ,
> > but got no results when I searched on 'auto' or 'echo' or both.
> > More info might help here. I'm transmitting from a
> > simple output-only VB script on one PC in through port 16 and
> > then the stamp is forwarding what it receives out port 14 to
> > a receive-only terminal on another PC. This is what I
> > intended to happen. Where I'm confused is why the stamp is
> > receiving more than one piece of data. The code I spelled
> > out below is supposed to only get one number, relay that
> > number and a comma, and stop. But it doesn't. It continues
> > to receive all the incoming numbers. That's the part that I
> > can't figure out. It should only get one number. The fact
> > that it continues to echo what it receives is unimportant.
> > Any ideas?
> > Don
> >
Original Message
> > From: "Al Williams" <alw@a...>
> > To: <basicstamps@yahoogroups.com>
> > Sent: Tuesday, May 28, 2002 6:27 PM
> > Subject: RE: [noparse][[/noparse]basicstamps] SERIN auto-looping?
> >
> >
> > > Don't forget that port 16 always echos what you send it since it
> > > steals -12V from the PC. If you are trying to "watch" both
> > lines with
> > > port 16 or if your code on the other end is echoing that
> > could cause a
> > > loop. You can read more about the auto echo "feature" at
> > the Stamp FAQ
> > > at http://www.wd5gnr.com/faqs
> > >
> > > Good luck!
> > >
> > > Al Williams
> > > AWC
> > > * Floating point A/D http://www.al-williams.com/awce/pak9.htm
> > >
> > >
> > >
> > > >
Original Message
> > > > From: mtlhead7 [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=N160dJapl1w49AGEjsrFvXxUjDyPjaPcz0-42QhDNhlUXTiyfnK0W8N-RTRhCDLCIlObvUgrv26B8FcTTGRDzMQQRP_SwA]renegade.engineer@v...[/url
> > > > Sent: Tuesday, May 28, 2002 7:02 PM
> > > > To: basicstamps@yahoogroups.com
> > > > Subject: [noparse][[/noparse]basicstamps] SERIN auto-looping?
> > > >
> > > >
> > > > This one's got me really baffled. I'm using a BS2p24. I'm
> > > > reading output from a VB script. The data comes as one
> > continuous
> > > > stream of 30 numbers, but I wanted to separate the data
> > into 6 sets
> > > > of 5. I had problems and began debugging the original code. The
> > > > long and short of it is, I got the code down to the following:
> > > >
> > > > Data VAR BYTE
> > > >
> > > > SERIN 16,16624,[noparse][[/noparse]DEC DATA]
> > > > SEROUT 14,16624,[noparse][[/noparse]DEC DATA,","]
> > > >
> > > > END
> > > >
> > > > Pin 14 is connected to a terminal prog on another PC
> > to monitor
> > > > the data. I expected to see one number and comma come
> > through and
> > > > nothing else, i.e.:
> > > >
> > > > 49,
> > > >
> > > > However, it still receives and echoes all the data, and the
> > > > output looks like:
> > > >
> > > >
> > > >
> > 49,12,10,12,11,61,12,12,12,13,40,12,14,12,15,6,12,16,12,17,29,12,18,
> > > > 12
> > > > ,19,16,12,20,12,21
> > > >
> > > > Is SERIN and SEROUT causing some kind of auto-loop? Any ideas
> > > > what's going on? This is totally bizarre!
> > > >
> > > >
> > > >
> > > > 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/
> > > >
> > >
> > >
> > > 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/
> > >
> > >
> > >
> >
> >
> >
> > 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/
>
>
> 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/
>
>
>
repeat the program over and over. This happens often if the PC
terminal program manipulates DTR. To determine if this is the case:
Data VAR BYTE
SEROUT 14,16624,[noparse][[/noparse]"Begin"]
SERIN 16,16624,[noparse][[/noparse]DEC DATA]
SEROUT 14,16624,[noparse][[/noparse]DEC DATA,","]
END
The "Begin" message will only be transmitted at the start of the
program, so if you see it more than once your program is restarting.
See the SERIN/SEROUT instructions in the manual to see how to get
past this problem if appropriate.
Regards,
Steve
using a different input pin will fix the problem, but now I know what was
going on as well.
Thanks again to everyone!
Don
Original Message
From: "S Parkis" <parkiss@e...>
To: <basicstamps@yahoogroups.com>
Sent: Tuesday, May 28, 2002 10:44 PM
Subject: Re: [noparse][[/noparse]basicstamps] SERIN auto-looping?
> My guess: your transmitting PC is causing your Stamp to reset and
> repeat the program over and over. This happens often if the PC
> terminal program manipulates DTR. To determine if this is the case:
>
> Data VAR BYTE
>
> SEROUT 14,16624,[noparse][[/noparse]"Begin"]
> SERIN 16,16624,[noparse][[/noparse]DEC DATA]
> SEROUT 14,16624,[noparse][[/noparse]DEC DATA,","]
> END
>
> The "Begin" message will only be transmitted at the start of the
> program, so if you see it more than once your program is restarting.
> See the SERIN/SEROUT instructions in the manual to see how to get
> past this problem if appropriate.
>
>
> Regards,
>
> Steve
>
> 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/
>
>
>
Our ASP-II has a jumper to disconnect DTR for just this reason. You
might consider something similar -- you could isolate DTR when operating
and resume it while programming. You can also sometimes set your PC
software to leave DTR alone (for example, handshaking=none).
Al Williams
AWC
* Easy RS-232 Prototyping
http://www.al-williams.com/awce/rs1.htm
>
Original Message
> From: Don [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=ZzOI6tSN6yJMXerRz7GKbj8iLqn7WBCbU8-7iN3u5sF-iTaJRYRrBH7i4tbRMNlFVSo7NWnmYH-o9xBSe7ozIy4GfQ]renegade.engineer@v...[/url
> Sent: Wednesday, May 29, 2002 8:42 AM
> To: basicstamps@yahoogroups.com
> Subject: Re: [noparse][[/noparse]basicstamps] SERIN auto-looping?
>
>
> YES! That's the problem. Thanks Steve! Looks like Al's
> suggestion of using a different input pin will fix the
> problem, but now I know what was going on as well.
> Thanks again to everyone!
> Don
>
Original Message
> From: "S Parkis" <parkiss@e...>
> To: <basicstamps@yahoogroups.com>
> Sent: Tuesday, May 28, 2002 10:44 PM
> Subject: Re: [noparse][[/noparse]basicstamps] SERIN auto-looping?
>
>
> > My guess: your transmitting PC is causing your Stamp to reset and
> > repeat the program over and over. This happens often if the PC
> > terminal program manipulates DTR. To determine if this is the case:
> >
> > Data VAR BYTE
> >
> > SEROUT 14,16624,[noparse][[/noparse]"Begin"]
> > SERIN 16,16624,[noparse][[/noparse]DEC DATA]
> > SEROUT 14,16624,[noparse][[/noparse]DEC DATA,","]
> > END
> >
> > The "Begin" message will only be transmitted at the start of the
> > program, so if you see it more than once your program is
> restarting.
> > See the SERIN/SEROUT instructions in the manual to see how
> to get past
> > this problem if appropriate.
> >
> >
> > Regards,
> >
> > Steve
> >
> > 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/
> >
> >
> >
>
>
>
> 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/