Can nRF51822 drive LED directly by GPIO?

Now I have a project to build the schematic.

a, 5 LED indicators(0603) were driven individually by GPIO port directly, serial with resistor, then pull down to GND. Is it enough power to drive the LED? or must pull up the LED to VDD connection?

b. The GPIO connect to NMOSFET Gate to control the vibrating motor. Must the GPIO port connect to Pull-Down resitor? What's the pull-down resistor value?


  • Hi,

    a) With field "DRIVE" set to H1H0 in NRF_GPIO->PIN_CNF[n] you can draw up to 15 mA (3 x 5mA, 1x15mA, or 5 x 3mA) in total on all GPIOs. If you exceed 15 mA in total, you will have to buffer the GPIOs using a transistor as a switch.

    b) This will depend on your MOSFETs and it's threshold voltage. If you have one that needs, lets say 1.5V, this will require a series-shunt resistor network in order to get this voltage going into the gate.

    You'll most likely need external components.

    The internal pull up/down varies from 11 - 16 k with 13k nominal resistance.

    Best regards Håkon

  • What is meant to happen if you try to exceed the 5ma? I ask because I have hooked up a simple LED with current limiting resistor (rated for 20ma) to a pin and it seemed to work fine (though wasn't especially bright). Is there some protection built into the chip?