ardupilot
ardupilot copied to clipboard
AP_Scheduler: fixed Example code not working by adding ins.update()
The original AP_Scheduler example sketch doesn't work as expected After debugging I found that: The AP_Scheduler library requires ins.update() else it would be stuck in the scheduler.loop();
@peterbarker I have tested the code. It's finished. Original code: Nothing is printed out. My pull request: It prints out messages from scheduler tasks as expected.
I don't know how to resolve failing checks. Could you guide me please.
I have rebased my commits to master on my Fork. Do I need to create a new Pull Request again?
As discussed in Discord, maybe try these steps:
First update your "master" branch to match ardupilot's master branch:
- git remote add trunk https://github.com/ArduPilot/ardupilot.git
- git checkout master
- git fetch trunk
- git rebase trunk/master
- git push
Next rebase your Sche_Test branch off of "master":
- git checkout Sche_Test
- git rebase origin/master
- git push -f
@rmackay9 Thanks for the detailed guide.
In step 5 of "update your master branch to match ArduPilot's master branch" I had to use git push --force instead of git push as it was rejected without --force.
@peterbarker I have made the necessary update. Could you review my change?
@peterbarker I have made the necessary update. Could you review my change?
The example seems to be failing again in here somehow - could you check, please?
@dinhthong I've been looking at this locally.
What sort of board were you running this on?
Certainly my testing on master in SITL show this example as working.
I can see problems if you are running this on a board without an IMU.
@peterbarker I tested with Pixhawk 2.4.8 (very old board). Btw, I think I messed up the code commit again
@dinhthong this example is exiting with an exception in SITL now. That needs to be fixed before merge.
Are you still keen on chasing this?
Ping @dinhthong - needs some attention.
sorry everyone, I can't work on this right now because of the environment setup on my machine. I will get back when I have time. @peterbarker Should I close this pull request?
sorry everyone, I can't work on this right now because of the environment setup on my machine. I will get back when I have time. @peterbarker Should I close this pull request?
Nah, all good. I've cleaned up your patches a little bit and pushed a patch in to get the test passing in SITL.
Will MergeOnCIPass.
Thanks for the fix!