-
Notifications
You must be signed in to change notification settings - Fork 13.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can’t use pwm command to test AUX Pwm pins #12086
Comments
@Evaneee thanks for the data. What version of PX4 are you using? |
Embarrassed,emmm, Could you tell me what to do to can get the PX4 version? |
is this?? |
Sorry, I did not yet get to this but it's on my list. |
Question 1: That's interesting, I can reproduce this. Question 2: The output of |
@davids5 I'm looking into why I found that whereas When looking at the PX4IO driver px4io.cpp it seems to me that this test mode is not implemented: For FMU in fmu.cpp it is however: Do you have an idea why this is the way it is? And do you know how it should be? 😄 |
From a design perspective there should not be a test mode directly in a driver (because of this). Tests should be applied externally. So the whole test mode should be stripped. |
PWM test - it was a change in the FMU that I needed the test mode flag for. The flag/mode just prevents the real mixer output from stepping on the test output. |
I have no strong opinion but I would like have one way only, or if we really need both ways then both need to be implemented everywhere. We can discuss it in today's devcall. |
sorry I canot do the test, My /dev/pwm_output1 has disappeared, and I can not find it for several days, I write a lot of printf to test the program, and I find a little result about fmu the screenshot and start log is here |
you are right, I test it today, when do pwm test ,pwm_output1 can output ,but QGC do not show... |
Just to close the loop on this
The -m can b 1..128 in steps of 2: 1,2,4,8... and the will walk the pwm signal from ch1-ch7 Hope this helps. I can not comment on weather QGC reports that PWM data back - I use a oscilloscope to measure HW as it reduces the chain of errors to a minimum: Probe on the right pin :) |
Hello all, Before start I just connected USB to pixhawk and closed USB circuit breaker. I didn't close mc_pos_control. Also pressed safety switch. After whole steps, I cut power and started with Finally, I wanted to try this command at the first, I just wanted to dig into this problem and I see that Whole process should be like this? FYI, @julianoes and @davids5 . Thanks. |
@bozkurthan - you have to set the rate on all the channels you want to test first.
Once that is done, the channels are in PWM mode and can be tested. |
Ok, I see. It's mentioned on documentation. Thanks again @davids5 |
This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions. |
operating system: windows 7
board: pixhawk4
I need to test the IOpins and auxpins,I follow
https://dev.px4.io/en/middleware/modules_command.html
Question1:
new start,I use
pwm test -c 12 -p 1200
I got this,sawtooth wave
It seems some program press pwm value in channel 1&2 from 1200 to 900, I don’t know why
I use
mc_att_control stop
fw_att_control stop
same result too
but After when I use
motor_ramp sine 1100 0.5
and use
pwm test -c 12 -p 1200
againthe result changed
seems works well, why this happened?
Question2:
I test auxpwm as I do in testing IOpwm
use
pwm test -c 12 -p 1200 -d /dev/pwm_output1
It does not work at all
who can tell me why?
many thanks!!!
@julianoes Could you can give me some advise??
The text was updated successfully, but these errors were encountered: