com port in use BS2
RoHerman00
Posts: 22
I am trying to connect my BS2 to the computer serial port and when I do not power the BS2 while it is connected and I select "identify" it says loopback and echo are both yes. When I turn on the power it says the BS2 is identified and connected, but after a short period of time when I try to load a simple code (debug "hello world") it says "cannot connect port in use". Any ideas would be helpful as I have already emailed support.parallax but maybe someone has a quick fix.
Thanks
Thanks
Comments
Do you have anything else connected to the computer that uses COM Port 1?
Is the BS2 on a Board of Education (BOE)?
And the general question, how is the BS2 being powered?
DJ
There is nothing connected to COM port 1. However I had the same problem but it was because I had two BS2's connected to one port so I removed one of the BS2's. It removed the "port in use" problem but it came back when I tried loading a program.
No it is not on a BOE. The BS2 was connected to a usb BOE but I had to remove it so it could go into a circuit board I made for a robot.
The BS2 is being powered from a 12V 1 amp power supply regulated to 5v with a 78L05 positive 100mA regulator.
If you have the USB BOE, use that as a test. Close all serial port connections and download a program. If that works then you have to start troubleshooting. If you have a problem, please ask but be specific. Reading your initial post, I would have never guessed that you rigged up a serial connection.
Are you absolutely certain you have the correct pins connected?
The PC is telling you that you do not !
The identify passes loopback and identifies (as you said) but the PC must be getting something else back from the Stamp during tha actual download. .I would suggest you look into "BASIC Stamp Programming Protocol v1.1.pdf " , part of Parallax PBASIC_Tokenizer documentation for answers to your problem.
I sure will
Cheers Vaclav
Thanks
Use the BOE/STAMP to verify that the STAMP is functioning properly. If the STAMP/BOE are working, then you have a problem with your rig.
'
DSR and RTS jumpered.
'
female DB9
BS2
PIN 1 N.C.
PIN 2 Rx
PIN 1(SEROUT)
PIN 3 Tx
PIN 2(SIN)
PIN 4 DTR
.01uF
PIN 3(ATN)
' ' ' ' .
' ' ' ' 0
' ' ' ' 1
' ' ' ' u
' ' ' ' F
'PIN 5 DSR
PIN 4(VSS)
'PIN 6
' ' ' |
PIN 7
PIN 8 N.C.
PIN 9 N.C.
'
N.C.= no connection
'
Take a look at page 28 of the BASIC Stamp Syntax Manual.
http://www.parallax.com/Store/Books/BASICStamp/tabid/168/CategoryID/42/List/0/SortField/0/Level/a/ProductID/143/Default.aspx
'
If this doesn't work, Will need more info.
Open the device manager
To Mike G I feel kind of dumb for not mentioning it but I have 1 desktop and 2 laptops. The desktop as I said is the one that detects the BS2 but because it shuts off randomly/frequently (maybe virus) I decided not to use it.
The laptop I used for the usb/BOE setup works for the usb board and is a 2010 year computer. The other laptop (the very old one) I want to use because that is the only one with a serial port besides the desktop but unlike the desktop it will not detect a connected BS2. That kind of answers the question of if the BS2 is connected correctly because the desktop "sees" it but something is up with the laptop (maybe some update not installed but the laptop is not connected to the internet) that is preventing communication. I apologize for dragging this on but this is the only problem keeping me from getting my robot finally working and functioning.
Have you looked in the device manager? Is there a little yellow icon on the COM port? What is your COM port number?
Well I went through device manager and there seems to be no yellow icon.
I clicked default and the port number is com1 but it has a pulldown bar and it allows me to select any com number up to 5 even though there is only 1 serial port.
The port settings are:
bits per second: 9600
data bits: 8
parity: none
stop bits: 1
flow control: none
advanced settings are
use fifo buffers: checked
receive buffer: set at 14
transmit buffer: set at 14
resources tab
input/output range: 02FB - 02FF
interrupt request: 03
http://zone.ni.com/devzone/cda/tut/p/id/3450
http://interface.centraltreasure.com/computer-hardware-article-diy-comport-test.html
Be careful
After briefly scanning this thread I see some good and some disturbing development.
From the first post - which stated that the identification process works but loading the program indicates “COM in use”I gathered that you have most of the cable connection correct. By "cable connection " I mean from PC (BIOS) to Tx and RX pins on BS.
By the way I would like to know who send this “COM in use “ message – Windows or Parallax editor.
I do not get why you started troubleshooting BIOS and looking for "yellow" mark in Device Manager. If this "cable connection” was anywhere incorrect you would not get this far.
Second – apparently you have three computers and they all behave differently, but all do not run your BS program, Am I correct? If so, I would suggest to work on the one who passed all the identification but had the “COM in use” message.
Did you look at the document I suggested? It has some good info in it.
For example it tells you that every data send to BS is echoed back to editor. That verifies that BS is getting data and the TX /RX connection is working.( No need to verify port setting.)
On the other hand – the Echo parameter in editor identification message indicates only that the PC port is set to echo back You said that you do not see data you are typing on you PC - that tells that the Echo parameter in that PC port is not set. But the port us working and there is no need to look for yellow mark.
I would suggest you try “Free serial port monitor” software
http://www.serial-port-monitor.com/index.html when you get back to “COM in use” error message.
Cheers Vaclav
My mistake, I was still thinking about the editor " loopback" (DTR-CTS). Unfortiunate choise of terminology on my part here..
Still like to know who send the "COM in use". In theory ( my guess from the documentation) after the editor identifies the stamp type it should be looking for echos of data coming back from the processor itself only - during the initial RUN ( load data) process.
.
But since we got into Device Manager - it will also identify port in use, not sure about the icon. It may be the same yellow dot.
Both messages are posted by the editor
Download Progress dialog identifies the port Basic Stamp is attempting to use and puts under ":device type" "can;t open port; port in use". I guess close enough for goverment work.
Then you get :"Communication errror" dialog telling that "No Basic Stamp found on port COM 1" which is less precise than the first message.
I need to correct myself - the Device Manager (Windows XP) does not show if the port is in use, in my case only unistalled port is identigied by "red cross" mark over the icon.
For anybody who wants to konw - I used Windows " Hyper " Terminal to busy out the port where my OEM module is connected. And I get no echo here ! I am still looking where port echo is programmed. I'll ask Mr Google!
Cheeers Vaclav
Tell us what happen when you try this
If you are using a USB to serial adapter plug the USB to serial adapter first to the computer with out the Baisc Stamp board and let your computer find the USB to serial adapter let the computer find all drivers and have install all drivers then hook up the Baisc Stamp board
I hope this helps