Shop OBEX P1 Docs P2 Docs Learn Events
Does RF effect BS2? — Parallax Forums

Does RF effect BS2?

TobiasTobias Posts: 95
edited 2009-10-30 16:16 in BASIC Stamp
· I am having a problem with a bs2, I have 3 5v inputs that go through a 1k resistor into the bs2 and a 10k pull down resistor. I have ten of these controllers in different trucks but with these two trucks I am having a problem that when I key the mic on my CB radio the bs2 sees a high on one of the inputs sometimes #1 or
#2 but only on these two trucks I have done some troubleshooting like changing the channel, checking the swr which is good, and turning down the output power on the CB.· The cable that supplies the power to the plastic enclosure where the bs2 is enclosed is shielded. I have experienced it on both the BS2 and the BS2e. What is going on? Your responds is greatly appreciated.
Thanks Toby

Comments

  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2008-03-17 10:42
    You might further check the antenna cable and configuration before you look at modifying the BS2 setup.

    Most of these antennas use the vehicle as a ground plane [noparse][[/noparse]part of the magnetic field that generates the transmission signal]. Since some of your CBs do not interfere with use, try to see what is different about their output from the CB and the antenna configuration. That is likely to lead you to a good solution.

    Simply put, the CB doesn't load the antenna until you hit the mic button. Then a surge of electromagnetic waves surrounds the vehicle. My guess is the surge creates a transient that is being picked up by the inputs. With FETs it doesn't require much - microamps.

    Also, check out if the power output of all the CB units are the same. More power output, more hassle. You appear to be already looking at that. Getting complete RFI shielding can be nearly impossible as all the wires going into the BasicStamp can pick up a signal.

    Some primative low pass filtering on the inputs might help. I guess that would be bypass capacitors to trap fast spikes. Opto isolators work as low pass too. Beau recommends them to clean up such automotive spikes.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    PLEASE CONSIDER the following:

    Do you want a quickly operational black box solution or the knowledge included therein?······
    ···················· Tropically,····· G. Herzog [noparse][[/noparse]·黃鶴 ]·in Taiwan

    Post Edited (Kramer) : 3/17/2008 11:25:43 AM GMT
  • TobiasTobias Posts: 95
    edited 2008-03-18 06:31
    should I put capacitors on my inputs ? A CB creates AC power output does that help you any?
    thanks Toby
  • Beau SchwabeBeau Schwabe Posts: 6,560
    edited 2008-03-19 04:38
    Tobias,

    A capacitor probably isn't necessary. Are these inputs floating, or do you have a pull-up or pull-down resistor on them? ... If there is a resistor, then perhaps a lower value might be needed. If there is no resistor I would maybe suggest one depending on how they are used and what they are connected to ... what do these inputs go to, and what does the schematic look like for them?

    "Opto isolators work as low pass too. Beau recommends them to clean up such automotive spikes." ....hmm. I try to avoid Opto-isolators unless they are absolutely necessary.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • TobiasTobias Posts: 95
    edited 2008-03-22 06:08
    This Is really interesting, I don't know if this is a subject that really fits this forum. But anyway, what I did to fix the problem is gonna make yo think. I figured I was going to troubleshoot the cb/antenna system before I start on the BS2 controller, I put a swr meter on my CB and it was OK or well under 2.5, I then put a dummy load on the CB and that solved the problem, I had about 12 ft of coax I check my ends, seemed to be good, even replaced them but still didn't work, went to a different antenna same thing. I finally replaced the coax with a 15 ft piece with new ends, after that I could transmit and not have an effect on the BS2 controller, that was my answer. After that I cut 12 ft off because I figured whats the use of having all that excessive coax if I could get away with a three foot piece because it would be long enough, I was back to square one when I transmitted my BS2 controller would go to setting1 or setting3 etc. So I ended up using the 12 ft piece and now its working like it should. Up till now I though the shorter the coax the better, what is the proper length? The truck had the same amount of coax, what could have happened? I sure didn't see any pinch points or anything that would've caused that.
  • LoopyBytelooseLoopyByteloose Posts: 12,537
    edited 2008-03-22 07:20
    Yea, I am happy you got it fixed. Sure, a BasicStamp problem with RFI should be in the Stamp forum. It may seem a bit advanced in electronics, but BasicStamps are up to advanced solutions - not just begineer's toys. I believe the term, rapid deployment device is a better description.

    Transmission antennas and the coax lines going to them can be quite involved to study.

    A lot of power is output and has to get to exactly the right place or it is reflected back into somewhere. It is just as much an art as it is a science. CBers generally don't concern themselves with it as much at HAMs because the distances and the power outputs are not as huge. If you have an 100 watt transmission station, the antenna really has to be right, or you are just ruining your neighbor' TV shows due to sloppy work. I gets hard to tell you one solution as different kinds and configurations of antennas require different solutions. Just maybe the SWR meter reads okay, but on physical inspection you see the cable or connections are deteriorated. Weather gets in everywhere unless you bury things in silicon caulk. The coax can be creating the problem either from the shielding being improper or because it is not balanced with the antenna and the transmitter properly. And many CBs buy an antenna that they think will just 'self adjust' to whatever they want to do.

    It seems that the 15ft coax is needed due to the wave length of the tranmission frequency. And the 12ft coax causes a line imbalance that sets up interference. This web site has the Navy's training manuals for electronic technicials. You can review the basics there and get a solid answer to why. http://www.zianet.com/NMAMARS/downloads/neets.htm

    I guess you see why I suggested to stay focused on the antenna system. Having the majority of your Basic Stamps working seemed to indicate redesign of the BasicStamp setup alone wasn't going to make the problem go away.

    Forgive me, but I may have made the whole idea of resolving input spikes more complicated. Beau really provided a much better answer at a 5k, 2.5k, or 1k pull down is a far better place to start with fixing the spike on the Stamps input. I didn't think I could be resolved so easily because it was RF.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    PLEASE CONSIDER the following:

    Do you want a quickly operational black box solution or the knowledge included therein?······
    ···················· Tropically,····· G. Herzog [noparse][[/noparse]·黃鶴 ]·in Taiwan
  • TobiasTobias Posts: 95
    edited 2009-03-02 01:39
    Well a few months later I am back in the same boat, I discovered that when I ground that shielded cable at one end It helps, for when my bs2e is in a certain stage in the program it will not be disturbed, by the cb output what other solutions could help thanks Toby
  • Carl HayesCarl Hayes Posts: 841
    edited 2009-03-02 06:18
    Some comments:

    (1) with a 10K pulldown and a 1K pullup, your 3.5v input is only 3.18 volts at the Stamp pin.· This gives very little noise immunity.

    (2) 2.5 is a fairly high SWR, and your CB radios may be reducing their output in self-protection.· Perhaps you got a better match with short coax and the transmitter went to full power, thus imcreasing the interference seen by the Stamp.· The shorter coax wouldn't reduce the SWR, but it might result in a better match because it would change the phase of the reflected power.

    (3)·you may have grounding problems, which are a·frequent problem·in vehicles.· Have you made sure your negative power connections, as well as the positive ones for the radio and the Stamp, go straight to the battery through reasonably fat wires, say #10, or #12 at the thinnest?· Also the radio feed, especially, should be separate from all other wiring in the vehicle.· It's amazing how voltages can jump around when you don't do that.· The stuff feeding the 3.5v may have its ground a volt or two lower, or higher,·than the stuff (the Stamp) that is being fed.· That could reduce your 3.5 volts by a lot, or conversely place an unintended voltage on the Stamp pins, making them see a 1 when it should be a 0, or vice versa.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    · -- Carl, nn5i@arrl.net
  • jmalaysiajmalaysia Posts: 97
    edited 2009-03-05 06:10
    The EMF from the CB is being received by the stamp inputs, causing false highs. There is often even enough EMF received through a relay coil to switch a relay. The correct way to eliminate the rf problem is to make the stamp inputs active LOW. As long as they are active HIGH rf problems will persist. Think of every wire in your circuit as an antenna. When the CB transmits, the input wire to the stamp recieves it and generates a corresponding voltage. If the voltage exceeds logic 1, even for a microsecond, the stamp acknowledges it.
  • TobiasTobias Posts: 95
    edited 2009-03-05 20:27
    So if I would make all the inputs high and when I toggle my switch it would go low and redo the code so it reads low instead of high, do you think that could work with the rf problem. Thanks Toby
  • Geo JrGeo Jr Posts: 1
    edited 2009-03-06 02:28
    Get a handfull of ferrite cores and use them as chokes on your input output leads. you will be amazed how much it will help. Make sure each radio is matched to it's antenna 2:1 or less SWR. Ground any shielded io lines at the stamp end and make good use of rf bypass capacitors wherever possible. Check for problems on various channels as different freqs will affect different circuts. You can reduce the RFI dramaticly but may still find some freqs hard to tame.

    My experience is primaraly with SSB 2-30 Mhz and plastic boats. 3-5 watts is low power compared to the 150-1kw units i see but the theory should hold up.
  • jmalaysiajmalaysia Posts: 97
    edited 2009-03-06 04:48
    Yes Tobias, I think that will probably work. I went through the same thing and once I switched everything to active low my mysterious phantom problems disappeared. My stamp was reading phantom inputs, which I discovered after extensive debugging while it was in operation. Once I changed to active low I had no problems. That was over a year ago. I have built nearly 100 units since then and have never had another problem. It was a REAL pain to change the logic levels of everything in mine, but it was time well spent. My stamp resides in a very high noise environment, with a 315 and a 418Mhz radio, 1/2hp dc motor and drive, 5hp 220 drive, and 8 relays, all enclosed in Nema housing.
  • TobiasTobias Posts: 95
    edited 2009-03-10 04:12
    Today I experienced something, This·truck with this problem has been sitting in our yard and I have not done any modification, it was about 30 degrees fahrenheit, I got in and powered everything up and keyed the mic and I could not make the bs2e do what it did as I mentioned earlier, that makes me to wander does temperature have an effect? But I'll get it parked in our warm room temperature shop and then we'll see what happens. Interesting...
    Thanks, Toby
  • NR1XNR1X Posts: 111
    edited 2009-03-13 19:33
    I would check the length of all of the cables like coax and any cable that shares ground with the circuit in question... 3 ft is a bad length for rf signals between 26 and·30 mhz. i have a homework board mounted in side a 10m radio right now acting as a propagation beacon.. no ill affects from the rf @ 28.2515Mhz... stay away from 1/4 wave length and odd multiples of 1/4 wavelength... to get wavelenght in feet: 1/2 wave = 486/Mhz... chokes chokes and more chokes good man....
  • KHARNHKHARNH Posts: 2
    edited 2009-03-14 14:15
    If the BS2 is powered by the vehicle's electrical system I might temporarily disconnect it and try running it from a seperate battery pack with the shortest possible leads to the BS2, particularly if the problem is reproducable at some point so you can verify the effect. Permanantly running it from a battery pack may not be desirable but at least that isolation may give you some clue if the glitch is coupled directly through the vehicle electrical system or through the air and give you a starting point to begin isolating the problem.
  • TobiasTobias Posts: 95
    edited 2009-10-30 05:20
    I have a different truck with the same problem, I have already modyfid the chip so that it is normally high on the inputs and low when it should switch. But only on one input I have three inputs and it only does it on the one. I don't have to do anything in the truck like key the CB mic or turn up the radio etc.
    What is the proper valued resistor to use for the pullup and pulldown circuit?

    Thanks, Toby
  • Beau SchwabeBeau Schwabe Posts: 6,560
    edited 2009-10-30 16:16
    Tobias,

    Can you provide a schematic of your current setup and possibly approximate wire lengths to your inputs as well as power supply wire lengths ?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
Sign In or Register to comment.