Hello. I’m trying to get a GPS module to work with Le Potato.
I’m running Raspbian 6.0.11.
I was able to get uarta connected to the GPS module using the ldto tool.
sudo ./ldto enable uarta
sudo ./ldto merge uarta
The serial ports on GPIO pins 8/10 show up as /dev/ttyAML6
This is now referenced in the /etc/default/gpsd.
DEVICES="/dev/ttyAML6 /dev/pps0"
Using the gpsmon tool, the NMEA sentences are displayed correctly.
I am trying to connect a GPIO pin for the PPS input.
In the Raspberry Pi version, this connection is added in the /boot/config.txt
dtoverlay=pps-gpio,gpiopin=12
I would like to use pin 12 of the 7J1 connector for the PPS input.
How can I connect this GPIO pin to the gpsd daemon?
thanks
You have to clone the wiring tool repo, write an device tree overlay for that specific pin, and then enable/merge it. Then it should work. PPS GPIO is already enabled in the kernel.
hi I’m a little lost trying to get used to using the s905x-cc. i have several python codes that i used to run on the raspberry pi that i would like to run on the s905x-cc, but I’m lost at what code/ library i need to use in python3 to control the GPIO pins.
should i start here with this wiring tool or if there is documentation that i can be pointed to so as i can get answers. thanks in advance
I am getting some weird results while running these commands (on a potato running ubuntu 22.04.1 server). I have a setup with an LED hooked up to the main GPIO header pins to see the results. The set commands work as expected, I am able to set the pin to high and low and observe the expected on and off of the LED. So setting the pin level manually seems to be fine.
However, when I try to get the status of the pin after changing it (since I want to read button presses using the GPIO pins), the status always comes back as high (1), even when I have just set it to be low (0).
So I get results like this:
$ sudo lgpio set 40=0
$ sudo lgpio get 40
1
The other interesting thing is that when I do this with my LED that is hooked up to the GPIO pin whose state I am changing, when I set the pin to 0 the LED goes completely off, but when I do the get on the pin the LED comes on just ever so faintly. So it seems like the get does actually change the state of the pin (I had no idea this was a quantum computer!) which might be why it always returns high.
I have tried this with both lgpio and gpioset and get the same results. Any idea how to properly read the state?
@librecomputer I have two probably very basic questions about the device tree on a ROC-RK3328-CC, which I didn’t think deserved their own thread, but happy to make one.
The Raspian image for ROC-RK3328-CC (as best I can tell) ships with all of the PWM nodes disabled. What’s the purpose/benefit of having available hardware disabled by default? For example, does it save power or resources? Increase security? I’ve been reading a lot about device trees over the last couple of days, and haven’t found a good explanation for this, even though it seems fairly common across many boards and devices.
Ultimately (I think), the DT nodes need to get very specific about actual hardware characteristics of the SOC or board; something like a memory address. Having read through the datasheets for the ROC-RK3328-CC, the RK3328, etc, I see a lot of useful information about the hardware, but I haven’t been able to find the specific hardware values present in the DTB. How would someone creating the device tree for a chip or board from scratch know or find those values, if they aren’t provided in the reference material?
A single pin can have multiple hardware functions outside of a simple GPIO. The hardware functions must be enabled and disabled according to the application needs for that GPIO.
Reference existing overlays. This is covered in kernel documentation. Each board vendor can have different implementation.
Hello, is there a simple guide somewhere on how to set outputs or query inputs in NODE-RED on the AML-905X-CC?
I tried to install “node-red-contrib-libgpiod” or “node-red-contrib-roadrunner” without success. I can’t find any “gpio-in” or “gpio_out” nodes. Please help
Does this tool have any sort of mechanism for driving the GPIOCLK_0 through one of the SoC’s PLLs? On the Pi this can be done with the WiringPi tool, as follows:
gpio mode 7 clock ; gpio clock 7 1000000
To output a roughtly 1MHz clock. Reading through the S905X datasheet I see that there are registers for driving this pin. At the very least I would like to be able to set gpioCLK_0_xtal to 1 on the HHI_XTAL_DIVN_CNTL register in order to measure overall system clock performance via an external frequency counter.