Shop OBEX P1 Docs P2 Docs Learn Events
Which of the RS232-to-Propeller circuits is best? — Parallax Forums

Which of the RS232-to-Propeller circuits is best?

achoox4achoox4 Posts: 4
edited 2010-01-19 20:05 in Propeller 1
I've finally taken the plunge and bought a few Propeller chips with the intention of building the 3-transistor·programming circuit shown on http://www.parallax.com/tabid/254/Default.aspx·. I've been unable to find my SX Key after a move, and·because I've got a few projects coming up where the Propeller should work at least as well as the SX (and the cost difference doesn't really matter, though I still have 20+ unused SX chips), I figured I could give it (and, more importantly, Spin) a try for little initial investment with·the RS232 circuit. (I've had an easier time with a C-programmed uC with on-chip flash easily written by my code, but there the fine-pitch packages make the price of entry for starting a new hobbyist project pretty steep.)

But now that I've got the parts here, looking for the minimal circuit digram I see that the most recent·datasheet shows a somewhat different programming circuit (only 2 transistors...), and I've found discussions regarding the capacitor and the size of some resistors.

Is there a known·best version of this circuit? Is the one linked above simply it?·I've·bought 3 Propellers for starters, so I can tell a faulty circuit from a faulty Propeller, but now I just don't know how to start at all.


Also, with this circuit (and otherwise), does RESn require an external pull-up or not?
·

Comments

  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2010-01-17 21:04
    To answer your last question: RESn does not require an external pullup if BOEn is tied to Vss. Otherwise, a pullup will be required. Almost all Prop circuits have brownout enabled (BOEn tied low), though.

    -Phil
  • Toby SeckshundToby Seckshund Posts: 2,027
    edited 2010-01-17 23:43
    I have always used the three transistor cct, apart from one MAX3232 one that needed rewring anyway. The USB one does give the external power option.

    I separate the res, open collector, from he Prop via a link via a jumper. This allows comms to-and-fro without the resets.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Style and grace : Nil point
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2010-01-17 23:44
    Bear in mind that as the Prop tool uses the communications port in a non-standard way the transistor circuit is only suitable for programming and not for general serial communications unless you:

    1) Have control of DTR and make it negative when a port is opened
    or
    2) Ground the 4K7 resistor instead of connecting it to DTR as the negative swing is not required for practically any RS-232 ports.

    I have also used logic gates in place of transistors in RS232 circuits without any problems as they will swing rail-to-rail. Otherwise uses a MAX3232.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    *Peter*
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2010-01-17 23:57
    I have to agree with Peter: the MAX3232 is, overall, a lot less trouble in the long run and provides you with solid full-duplex communication.

    -Phil
  • achoox4achoox4 Posts: 4
    edited 2010-01-18 22:35
    Toby Seckshund said...
    I have always used the three transistor cct, apart from one MAX3232 one that needed rewring anyway. The USB one does give the external power option.


    I separate the res, open collector, from he Prop via a link via a jumper. This allows comms to-and-fro without the resets.
    Just to make sure I'm not making incorrect assumptions:

    Is the 3-transistor circuit exactly the·one at http://www.parallax.com/tabid/254/Default.aspx·?

    Do you just put the jumper between that circuit's "RES" port and the actual Propeller RESn pin? (and pull the jumper after booting/programming?)
    ·
  • achoox4achoox4 Posts: 4
    edited 2010-01-18 22:51
    Phil Pilgrim (PhiPi) said...
    I have to agree with Peter: the MAX3232 is, overall, a lot less trouble in the long run and provides you with solid full-duplex communication.

    -Phil
    I think I've got a small pile of MAX3232s somewhere.

    Do I just run Rx to Rx, Tx to Tx, and·DTR to RESn·each straight through the MAX3232,
    and power the MAX3232 with 3.3V? Or do I need any inverters or other parts in addition?

    Edit: never mind the above, I just found this thread http://forums.parallax.com/showthread.php?p=778467
    which has as an attachment to the 4th post the PropStick schematic.
    Can I assume that's that (plus a weak pull-up on RESn) is the optimal circuit for the MAX3232?


    Post Edited (achoox4) : 1/18/2010 10:58:14 PM GMT
  • Phil Pilgrim (PhiPi)Phil Pilgrim (PhiPi) Posts: 23,514
    edited 2010-01-19 00:38
    Once again, you don't need a pullup on RESn if BOEn is grounded. See my first post above.

    -Phil
  • achoox4achoox4 Posts: 4
    edited 2010-01-19 16:39
    Right. What I really meant to ask is whether that circuit·from the PropStick manual (linked in the abovementioned thread) happens to be the optimal MAX-based circuit (ignoring for the moment the·RESn pull-up,·the need for which varies as you·said, and which is not included in that circuit).
  • Toby SeckshundToby Seckshund Posts: 2,027
    edited 2010-01-19 20:05
    "Just to make sure I'm not making incorrect assumptions:

    Is the 3-transistor circuit exactly the one at http://www.parallax.com/tabid/254/Default.aspx ?

    Do you just put the jumper between that circuit's "RES" port and the actual Propeller RESn pin? (and pull the jumper after booting/programming?)"

    Yes it is that cct,although I originally copied it from an Elektor artical. All I did was put a jumper link between the "reset" transistor's collector and the RES pin on the prop (the gray one ). This relies upon the internal pull up resistor, which happens when BOE is conected down to VSS ( otherwise you require a discrete pullup to the Res pin ). Virtually 100% of the time it is left conected, but occationally I disconect it if I get any unwanted resets during comms. The cct requires power from the Prop's 3.3 Volts, so 5 conections are needed.

    The other two jumpers are just to swap Rx and Tx around, I got it wrong once and so added that option too, and of course have never used it since.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Style and grace : Nil point
    640 x 480 - 52K
Sign In or Register to comment.