Shop OBEX P1 Docs P2 Docs Learn Events
Simple RS232 programming-connector and resets ... — Parallax Forums

Simple RS232 programming-connector and resets ...

Nick MuellerNick Mueller Posts: 815
edited 2009-08-16 13:09 in Propeller 1
Hi!

If you look through the documentation of Parallax for a simple -not to say primitive- interface for programming the Prop, you'll find 3 variants. One in the Prop-Manual, one in the Prop-datasheet and one somewhere in their datasheets on the web (really too bored to search for that one).

I frequently had resets out of nothing. One in an ignition-module for combustion engines (and again, the drivers went up in smoke ...) and one on a ModBus-interface I'm currently working on. I never intended to use that RS232-interface for real, but only for debugging. There's a stable opto-isolated one on-board, but not for programming.

To make the story short:
Don't use that interface. Just scope what's happening at the cap going to the base of the transistor that drives the RES-pin on the Propeller. smhair.gif I changed that cap to 1µF, tied DTR to GND with 1k and inserted 100nF between DTR and GND. Now I can even switch on the flourescent light right above work without getting a reset. smile.gif

Might not be the most elegant solution, but at least it works.

I suggest that Parallax finds a more stable circuit and corrects all three occurences ... They also should make some simple EMV-tests with that interface.


Nick

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Never use force, just go for a bigger hammer!

The DIY Digital-Readout for mills, lathes etc.:
YADRO

Comments

  • he1957he1957 Posts: 58
    edited 2009-08-15 17:27
    Somewhat related (perhaps a problem with serial/USB stuff?),

    This afternoon I tried the ICC C compiler on a DEMO board; It may be me but I'm less that impressed that the in-built terminal/debug interface won't let me download a (re-compiled) image without _manually_ disconnecting the "terminal" - hummm. I sure can't type nor mouse-click faster than about 10 baud or so while I'm thinking about other things as well...

    ...what have I done badly?


    Cheers,

    HarryE.
  • Toby SeckshundToby Seckshund Posts: 2,027
    edited 2009-08-15 21:22
    The brownout is enabled a default on the demoboard, which I copy, possible ?

    I have a constant problem with the resets when I switch on/off my 'scope, but only when the '232 is connected to the PC. I tried extra pullups on the RST ccts but often went for a pullup and a disconect jumper.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Style and grace : Nil point
  • Nick MuellerNick Mueller Posts: 815
    edited 2009-08-15 22:57
    > It may be me but I'm less that impressed that the in-built terminal/debug interface won't let me download a (re-compiled) image without _manually_ disconnecting the "terminal" - hummm.

    This is not a problem with ICC, I had the same problem with Prop tool. It took some voodoo and then it worked for some time, only to come back the next day.
    I do have the impression, that these problems are gone with the mods. No long-time experience! Maybe you try them and give some feedback.

    I *rarely* had the resets when switching on/off the scope, but that is gone too. OTOH, I don't switch it on/off too frequently.
    If you scope at the basis of the transistor that goes to the RES and touch the isolated cable that goes to it, you'll notice glitches.The circuit is much too sensible.



    Nick

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Never use force, just go for a bigger hammer!

    The DIY Digital-Readout for mills, lathes etc.:
    YADRO
  • Beau SchwabeBeau Schwabe Posts: 6,568
    edited 2009-08-16 03:53
    Nick Mueller,

    Perhaps if you could post a link the exact circuit that you are referring to we could take a look at it. If it's the 3-transistor version, this was borrowed directly from the front end of the BS2 module that we have been using for years. It has withstood the test of time and proved to be a robust solution to many RS232 environments.

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

    IC Layout Engineer
    Parallax, Inc.
  • Nick MuellerNick Mueller Posts: 815
    edited 2009-08-16 09:10
    Hi Beau!

    Variant #1: Propeller-Datasheet v1.2 page 5; 2 transistors
    Variant #2: <http://www.parallax.com/tabid/254/Default.aspx&gt; (SerialTpPropeller.pdf); 3 transistors
    Variant #3: (see attachment) If I only could find the original source! Quite sure that it is not my invention. Only changed the transistors to European types.

    I used Variant 3. It isn't that much different to v2. Any ripple on DTR will easily pass through to /RES.


    Nick

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Never use force, just go for a bigger hammer!

    The DIY Digital-Readout for mills, lathes etc.:
    YADRO

    Post Edited (Nick Mueller) : 8/16/2009 9:17:37 AM GMT
    451 x 407 - 8K
  • Toby SeckshundToby Seckshund Posts: 2,027
    edited 2009-08-16 10:49
    I use the three transistor version that was published in the summer 2007 Elektor. Much the same as the attachment but it uses two 10K resistors from the 232 side to the bases. One in seiries and one from the base down to deck.

    One varient that I tried was Praxis's Max3232 cct, worked ok. The only reason I wanted this, was it gave true 232 levels out rather than relying on the PC's volts.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Style and grace : Nil point
  • Nick MuellerNick Mueller Posts: 815
    edited 2009-08-16 11:25
    I found the 3rd source again (looking in the bin-folder of my PC on wich I draw the schematics cool.gif ):

    Its in the Propeller Data Sheet V 0.2


    Nick

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Never use force, just go for a bigger hammer!

    The DIY Digital-Readout for mills, lathes etc.:
    YADRO
    842 x 417 - 13K
    v3p.png 12.8K
  • localrogerlocalroger Posts: 3,452
    edited 2009-08-16 12:47
    I'm using a couple of PropRPM's in a heavily industrial environment and have no trouble with them. They use a single dual-channel max3232e chip with is only a few dollars and super easy to use; I've got one breadboarded onto a demoboard along with an SD interface. Here's the schematic: http://www.parallax.com/Portals/0/Downloads/docs/prod/prop/proprpmv10_schema.pdf

    The problem with the transistor designs is that they're all single-ended and don't drive (or respond to) the negative-going swing of a proper RS232 signal; some receivers don't like this and that's one thing allows noise to get injected onto the line. The max3232e uses a charge pump to generate both positive and negative 5V so that it can adhere to the RS232 standard, which says that 0V is not a valid signal (and +3.3 is barely logic 1).
  • Nick MuellerNick Mueller Posts: 815
    edited 2009-08-16 13:09
    No doubt, that any design with a MAX232 or similar is by magnitudes more stable. Especially when using an opto-coupler.
    And that's what I use in the ModBus-module.

    The point is, that the simple design (V3) is much too sensitive to any ripple. It resets on the touch to the *isolated* cable to DTR.
    Variant #2 has only 10nF and 10k, variant #3 has 100nF and 4k7. So V3 should be more stable than V2. V1 should be the least stable one.


    Nick

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Never use force, just go for a bigger hammer!

    The DIY Digital-Readout for mills, lathes etc.:
    YADRO
Sign In or Register to comment.