Simulating Gyro Noise/Sound

For a school project, I am trying to simulate what would happen if I bombarded my Pixhawk 4 mini with soundwaves. Rather than crashing a perfectly good drone, I was wondering if I could simulate this on APM in SITL? Is there a way I can fudge up the gyro/accel info while its in SITL flying a mission?

Thank you so much for all the help

(I am using Pixhawk 4mini with the latest 4.0.6 build)

You would probably need Hardware in the loop, which I think existed some time ago, but is now discontinued…
https://ardupilot.org/dev/docs/hitl-simulators.html
Which kinda sucks because your project sounds very interesting;)

1 Like

I can do Qground hilt but problem is in order to run it on HITL qground shuts the sensors down. So no go on hardware. Software wise I just need to figure out how I can inject my noise :frowning: sadly coding isn’t my strongest suit.

I just realized that I made a mistake, with HITL the computer replaces the sensors, so that wouldn’t work anyways…

Yeah thats why I was looking to see if it would be possible in SITL. Thank you for the suggestions tho. everybit of info and discussion helps.

We already do muck the sensor data up in SITL - looking for things like
SIM_GYR_RND

We can also inject more complex data for our FFT peak-detection code to
be tested against; every commit to master has to pass

tridge did some experiments a long time ago gluing autopilots to speakers
to test their responses - that might be a good way forward for you (crappy
speakers from a second-hand store will cost you virtually nothing).

@Vabe HITL is working in master again :slight_smile:

@amilcarlucas We might have to edit the wiki for newbies like me. Would love to use it in ardupilot rather than px

I already have data for the sensors like BMI055 ICM20948. I am just cluesly looking for a way to add my noise data to SITL or HITL. I was thinking about doing HITL tests using Gazebo’s force menu but Gazebo wont work correctly on HITL. I would love for some expert to show me how I might be able to insert my test data so simulate my results.

Thank you for the wonderful help and replies regardless. you guys are such a lovely and helping bunch.