QBasic Serial Com w/ Stamp
Archiver
Posts: 46,084
hey everyone,
I'm using qbasic to talk with my stamp via a serial connection.
One site which had example code for this type of application said
that one must put the following code in the qbasic code in order
to "clear the stamp's DTR bit":
tcmp = INP(&H3FC)
OUT &H3FC, tcmp AND 254
However, I have found that qbasic talks with the stamp just fine
without these two lines of code. In fact, when I use that code, the
stamp restarts everytime that code is executed. Without using the
code, I'm able to talk (using a qbasic program which acesses the
serial port) with the stamp without the stamp restarting all the
time. Does anybody know why clearing the dtr bit should be done, and
yet why it doesn't seem to be needed in my program? Thanks!
I'm using qbasic to talk with my stamp via a serial connection.
One site which had example code for this type of application said
that one must put the following code in the qbasic code in order
to "clear the stamp's DTR bit":
tcmp = INP(&H3FC)
OUT &H3FC, tcmp AND 254
However, I have found that qbasic talks with the stamp just fine
without these two lines of code. In fact, when I use that code, the
stamp restarts everytime that code is executed. Without using the
code, I'm able to talk (using a qbasic program which acesses the
serial port) with the stamp without the stamp restarting all the
time. Does anybody know why clearing the dtr bit should be done, and
yet why it doesn't seem to be needed in my program? Thanks!
Comments
used to reset the stamp prior to programming. It should be disconnected or
off when you're using the programming port as a serial port. I hope I'm not
misleading you...
Ryan
Original Message
From: Sam [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=WiLAO0TWetAC9a9n3_VK6HH-rKX5Lm7aBUGG8gedZVpviquDe-dIY3WHvVjRQVNxgCIpHaEb7Puz]hard-on@t...[/url
Sent: Friday, August 01, 2003 10:54 AM
To: basicstamps@yahoogroups.com
Subject: [noparse][[/noparse]basicstamps] QBasic Serial Com w/ Stamp
hey everyone,
I'm using qbasic to talk with my stamp via a serial connection.
One site which had example code for this type of application said
that one must put the following code in the qbasic code in order
to "clear the stamp's DTR bit":
tcmp = INP(&H3FC)
OUT &H3FC, tcmp AND 254
However, I have found that qbasic talks with the stamp just fine
without these two lines of code. In fact, when I use that code, the
stamp restarts everytime that code is executed. Without using the
code, I'm able to talk (using a qbasic program which acesses the
serial port) with the stamp without the stamp restarting all the
time. Does anybody know why clearing the dtr bit should be done, and
yet why it doesn't seem to be needed in my program? Thanks!
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/
[noparse][[/noparse]Non-text portions of this message have been removed]