Shop OBEX P1 Docs P2 Docs Learn Events
Using P30 & P31 as Outputs after bootup — Parallax Forums

Using P30 & P31 as Outputs after bootup

TomSTomS Posts: 128
edited 2007-03-11 23:19 in Propeller 1
Is there any special precautions I need to take when using P30 & P31 as outputs after bootup? What happens when the pins are configured as outputs and a PropPlug or propchip is connected? Would series resistors be advisable?

Thanks
Tom

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2007-03-11 20:05
    The PropPlug or PropClip output (connected to pin 31) is always active (an output). There's no series resistor on most existing boards between pin 31 and the PropPlug/Clip and, as a result, that pin cannot be used as an output by the Propeller. Even if you put in series resistors, you still can't use that pin as long as the Plug/Clip is still connected since the Plug/Clip is driving it.
  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2007-03-11 22:28
    Tom, a series resistor to the PropPlug will not harm anything on P31 which is normally an input. However only you know what you will be driving with those pins so you would have to take into account the effect that the load might have. Of course turning the loading on and off on P30 (normally txd from pchip) will generate garbage to the PropPlug.

    What happens when you are reprogramming the chip, will the coms chatter cause a problem with your loads? (robot motor enages forward and reverse together!) Unless the load is fairly dumb like an indicator or perhaps even a data line that requires other lines to be asserted anyway (SPI) it is usually better to leave those lines for programming and debugging. But that being said, I have used those pins for other things too, I just made supersure that there was no conflict. If I had to ask someone else then I shouldn't do it.

    *Peter*
  • TomSTomS Posts: 128
    edited 2007-03-11 23:19
    The Propplug and the other device which reads pins P30 & P31 won't be connected at the same time. It will be on a custom pcb so adding a resistor isn't a problem. The Propeller output and the PropPlug/Clip outputs would both be active only until the Propeller was reset by the propPlug/Clip. The DTR signal that triggers reset is independent of the state of P30 & P31 isn't it. Which brings up another question. Is DTR on the FT232 activated for each download from my computer? If that's the case, the Propeller output and the PropPlug/Clip output would be connected though the resistor until reset, when the Propeller pin would be first set to a high impedance state and then configured as an input. Wouldn't the resistor prevent damage until reset occurred? The whole point of this desire to reuse P30 & P31 is a lack of interface pins to the outside world. Its a remake of an existing app and I/O pins are at a premium. Adding another connector is not an option.

    Tom
Sign In or Register to comment.