[Solved] Kernel pwm driver

Hello,

I just received my Navio2 today (yay!)

I’m now looking at the PR you submitted to support it in APM git repo, and the fork that was created here

Currently on the rt-image we have:

 zcat /proc/config.gz |grep -i pwm
# CONFIG_PWM is not set

I was looking for an opportunity to rebuild the rpi2 kernel myself.
I’m thinking we’re going to need Linux PWM driver enabled in the kernel right?

Yeah I’ve ran into the issue with the PWM driver (LinuxPWM_Sysfs) not being implemented in the RT Kernel (Feb 2015), could the developers shed any light on how they got this working?

So i’ve recompiled the rt-image kernel with PWM support.

I now have the /sys/class/pwm directory. I’m not sure what the next step would be though.

pi@navio-rpi ~/ardupilot/ArduCopter $ sudo ./ArduCopter.elf
Raspberry Pi 2 with BCM2709!
LinuxPWM_Sysfs:Unable to open file /sys/class/pwm/pwmchip0/pwm0/duty_cycle: No such file or directory

I can’t find a hint in the pr/navio2 branch here

Unfortunately, we had to delay the release of the image for Navio2 due to a couple of issues. I deeply apologize for this. The issues are almost fixed and we will release the image in a couple of days.

Image for Navio+ is NOT compatible with Navio2. In Navio2 we are using PWM interfaces provided by RC IO microcontroller driver, simple PWM support in the kernel is not enough.

Thanks for the update.
I’ll sit tight and wait for your updates.

I have same problem but with new img.

pi@navio:~ $ sudo ArduCopter-quad -C /dev/ttyAMA0
Raspberry Pi 2 with BCM2709!
LinuxPWM_Sysfs: chip=0 channel=0 Unable to open file /sys/class/pwm/pwmchip0/pwm0/duty_cycle: No such file or directory

This is my first time to use navio. I would appereciate any help.

Hi Robert,

can you confirm you have the “/sys/class/pwm/pwmchip0” directory on your RP2?

Did you use sd-card image and apm from the new docs? (post)

Marking this [Solved] with release of new Navio2 IMG and APM.

1 Like

ye solved. I didn’t update img file, later I messed up in raspi-config soo it’s working on clean img for navio2. Couldn’t make autostart so I cleaned again RPi and now I can autostart but 3dr radio doesn’t work… trying next clean :wink:

2 posts were merged into an existing topic: STUCK! New install pwm problem duty_cycle: No such file or Directory

2 posts were merged into an existing topic: STUCK! New install pwm problem duty_cycle: No such file or Directory