i'm trying to get a sensor working.
i need to run `pinX.set_pull(pinX.PULL_UP)`
i want this to go faster so wanted to see the source to see if i can make it ,go
the problem is i cant remember the name and location of the source code for these micropython micobit objects and methods
source code for read_digital, and set_pull
-
- Posts: 168
- Joined: Tue Nov 07, 2017 11:45 pm
Re: source code for read_digital, and set_pull
micropython/ports/nrf/modules/machine/pin.c
nrf_gpio_cfg() is called in there to configure the GPIO pin
nrf_gpio_cfg() is called in there to configure the GPIO pin
-
- Posts: 168
- Joined: Tue Nov 07, 2017 11:45 pm
Re: source code for read_digital, and set_pull
i've found much of the source. main files are /source/microbit/microbitpin.cpp and source/microbit/microbitpinmode.c. how ever microbitpin.cpp reference 2 headers "MicroBitPin.h" and "nrf_gpio.h"
i've tried the find file button on both microbit/micropython and micropython/mcropython and can't locate the or the corresponding .c files if they exist
i've tried the find file button on both microbit/micropython and micropython/mcropython and can't locate the or the corresponding .c files if they exist