EmbeddedRelated.com
Forums
The 2024 Embedded Online Conference

UART/PWM output with open drain?

Started by markvanelst January 18, 2006
Hello,

I want to use the PWM to dim a LED. This led is connected with a 470
Ohm resistor to 5VDC. The controller is running on 3VDC. I want to set
the output of the PWM (T0) in open drain mode (set P1M1 and P1M2 bit).
Somehow this doesn't work.
The same problem occurs with bi-directional async communication. I
have connected RxD and TxD with each other. There is a pull-up
resistor connected to 5V. I want to set the output of TxD in open
drain mode, so the output will only be driven low. This doesn't
function either.
Does the LPC900 controller set the output automatically to push-pull
or another predefined output mode when a special function on that pin
is used?
Thanks in advance for your help.

Kind regards,
Mark


Mark,

not 100% sure but I would think your assumption is correct that a pin
that is associated with a function (UART, PWM) becomes push/pull. The
open drain is only available for general purpose I/O and for the I2C
pads. So, depending which LPC900 you are using, may be the I2C could
be used.

Bob

--- In lpc900_users@lpc9..., "markvanelst" <markvanelst@y...>
wrote:
>
> Hello,
>
> I want to use the PWM to dim a LED. This led is connected with a 470
> Ohm resistor to 5VDC. The controller is running on 3VDC. I want to set
> the output of the PWM (T0) in open drain mode (set P1M1 and P1M2 bit).
> Somehow this doesn't work.
> The same problem occurs with bi-directional async communication. I
> have connected RxD and TxD with each other. There is a pull-up
> resistor connected to 5V. I want to set the output of TxD in open
> drain mode, so the output will only be driven low. This doesn't
> function either.
> Does the LPC900 controller set the output automatically to push-pull
> or another predefined output mode when a special function on that pin
> is used?
> Thanks in advance for your help.
>
> Kind regards,
> Mark
>




Should work fine with open drain outputs. Make shure you set the
output to the logical high state to enable it! --- In lpc900_users@lpc9..., "markvanelst" <markvanelst@y...>
wrote:
>
> Hello,
>
> I want to use the PWM to dim a LED. This led is connected with a
470
> Ohm resistor to 5VDC. The controller is running on 3VDC. I want to
set
> the output of the PWM (T0) in open drain mode (set P1M1 and P1M2
bit).
> Somehow this doesn't work.
> The same problem occurs with bi-directional async communication. I
> have connected RxD and TxD with each other. There is a pull-up
> resistor connected to 5V. I want to set the output of TxD in open
> drain mode, so the output will only be driven low. This doesn't
> function either.
> Does the LPC900 controller set the output automatically to push-
pull
> or another predefined output mode when a special function on that
pin
> is used?
> Thanks in advance for your help.
>
> Kind regards,
> Mark
>



The 2024 Embedded Online Conference