Hello, I’m trying to use PWM3(0x032a0000) from TX2-NX. And generated .cfg by altering customer usage of GPIO13 to GP PWM3. But the .cfg changes are not getting reflected in the embedded host.
This is the config file value of pwm3.
“pinmux.0x0c3010a8 = 0x00000401; # gpio_dis5_pu5: gp, tristate-disable, input-disable, lpdr-disable”
While I’m reading the 0x0c3010a8 using busybox devmem from the embedded host after flashing it is showing 0x00000000.
may I know what’s your steps to modify the pinmux spreadsheets in detail.
had you perform the python script $OUT/Linux_for_Tegra/kernel/pinmux/t186/pinmux-dts2cfg.py to converts pinmux dts in to cfg format, and fully flashing the board?
Yes, I performed those python scripts to convert pinmux dts to cfg format. And fully flashed the board. Copied the .cfg file to Linux_for_Tegra/bootloader/t186ref/BCT directory.
are you able to control the PWM via sysfs?
for example,
to populate the channel ID, # echo 0 > /sys/class/pwm/pwmchip2
the channel will be populated and you should be able to configure the require values. # echo <num> > period # echo <num> > duty_cycle # echo 1 > enable
you’ll need to check whether GPIO13 is being used by something else in software, and thus the change is not getting reflected.
please disassembler the dtb file into text file to review the settings.
for example, $ dtc -I dtb -O dts -o output.txt tegra.dtb
devmem dump the values as same as pinmux configuration,
for example, pinmux.0x0c3010a8 = 0x00000405; # gpio_dis5_pu5: gp, pull-down, tristate-disable, input-disable, lpdr-disable