Serial connection with 20ft cable?
rwgast_logicdesign
Posts: 1,464
So i really didnt want to use another USB port for my bs2 I already have way to many USB/rs232 converter and usb hubs everywhere! My bs2 is working fine ive uploaded programs to it via USB and the serial cable that came with it. Now I have a what I believe is a 20ft cable plugged into com1 so I can have a serial port sitting on desk. 20ft is unnecessarily long but the 5fter that came with the stamp isnt long enough. Anyways the stamp editor cant find my HW board when plugged into this cable, I tested the voltages on the pins with a meter and they are all right, producing +11.4 and -11.4. Im assuming the cable is probably fine does a cable this long just have to much ringing or something to work? I know when designing serial/parallel based cables to program AVRs they can only be a few inches becuase of the ringing problem, but I would suspects a commercially produced shielded cable should at least work....
Comments
pin 1 DCD is a few mv
pin2 RxD is -11.4v
pin3 TxD -11.4v
im not sure what Tx and Rx are supposed to be at be default. I tried a continuity tester and it said Tx are pin 3 on both sides, pins 1 and 2 tested bad yet pin 2 is spitting out -11.4....... I stuck a pin header in the female end to so id would know the meter was making contact on that side for the continuity test...
@Chris yes my post above explains, i ran a continuity test but got super flaky results, its telling me pins 2 to pin 2 isnt continous but then pin 2 is carrying 11.4 volts..
Im just gonna chalk this up to bad cable, weird this thing is hardly used.
Suffice to say it was a very slow process....
Check for 'kinks' in the cable. Also start at one end and move along it wigging two spots a couple of inches apart - you might find an intermittent core - been know to happen (especially on much flexed cable). Using this method you might be able to get a goodly long enough length to still work with..
Other things to check for.. A nick in the outer insulation, a cable crush (it's not under one of the table legs is it?), water ingress. These are all thing I have seen and had to deal with....
In your case length is non issue.
Instead of fooling around with measuring voltage ( can be +_3V to 25 V) , start with editor “Run / Identify”.
With no power applied to the BS2 you should at least read Loopback Yes ( hardware conected), than with power on the BS2 you should get Echo Yes and proper identification of your chip ( communication OK).
If that fails than just check the cable continuity.
I do not want to get picky here, but most failures of this kind are due to mismatch of serial ( COM) ports and wrong kind of serial cable.
You mentioned that you have more serial / USB connections – so I would suspect improper COM port
selection.
Another time honored method of troubleshooting – use known components.
Do you have another working serial cable?
As a note I believe even with a crossover cable it is possible to get echo. Loopback, while great for troubleshooting is not required for the editor to identidy and program a BASIC Stamp Module. Echo is required, but if the RX/TX are backward it won't work.
Hi Chris,
I mentioned loopback because it does identify /check some RS232 signals( hardware) thru the BS2 true serial port. Unplug the cable and you get Loopback No.
As far as echo goes I have never satisfactory answered that to myself. I believe there was an opinion that it is strictly used for COM echoing the send data to the editor. Sort of "local loopback".
To my knowledge the chip identification is the only sure way to know that the serial link is working,
You are right , this may be as simple as low battery because that shuts down the CPU. My BS2e ( OEM) has the low voltage detector, but some schematics do not show that. Actually when I build my own BS2e OEM module I added "idiot LED" to make sure that the CPU is actually running.
Maybe that is the "voltage" ( I don't recall the signal name ) the OP should check.
That will be there even when no actual software is running, just CPU.