-
Notifications
You must be signed in to change notification settings - Fork 4.7k
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
Fixed Wing Aircraft #2955
Comments
I had a try at compiling your branch, the error message was really quite useless. |
Progress UpdateAircraft Physics Control ConstructionI have been continuing to work on the FixedWingPhysics simulation aiming to resolve compilation errors. I have vectorised the control surfaces so ideally they behave as a u tyoe vector. With this I introduced a new file Aeroplane.hpp that instants each control from the ControlSurface.hpp file as a PhysicsBodyVertex class. I have not introduced the thrust vector yet but this shouldn't be too much of a challenge. Aircraft links to the structs in AircraftParams.hpp and applies the aero-forces via Compilation errorWhen I run the repo from visual studio I get the following error :
Im not sure what this error is being caused by, I'm guessing there is no termination condition in the recursive call. If anyone has experienced this before I'd love to get your thoughts. |
That's happening cause the function is calling itself here - https://github.com/AOS55/AirSim-1/blob/FixedWing/AirLib/include/vehicles/fixedwing/firmwares/ardupilot/ArduPlaneApi.hpp#L54 Note that I haven't tested this myself yet |
Thanks yep that was it was quite obvious now I think about it in more detail. It several unresolved external symbol errors now but I think there a case of sorting out further problems with the API. |
Does anyone have any thoughts on this error coming from |
Functions seem to be missing, are all the files uncommented in the AirLib.vcxproj? |
Thats a good point I've uncommented them now, from AirLib.vcxproj, but Im still getting the same link errors from the compiler. When running build.cmd I also get some errors in the command prompt that are slightly different, |
Resolved all build errors now except for one rather unusual one: Not sure where this one links to as when I look at the location of the error in object.hpp which I'm not sure where it lives in the repo as dependencies folder not included in push/pull requests. |
The RPC error was due to the fact that it doesn't know how to pack the Vector3r object, need to convert it into the struct defined in RpcLibAdaptorsBase and then pass it. Opened AOS55#4 which fixes that, and adds the files to CMake. |
Great thanks very much Ill take a look at those errors today, I merged the issue back into fixedwing and have no build.cmd errors on my end too. |
Any thoughts on why I'm getting the following include/visibility related build error from in visual studio? I can see the source file UdpSocket.hpp is still on the repo, could it be related to cmake changes?
|
That's very strange, Windows shouldn't be affected AFAIK since it uses the .sln files. And if this were a problem, then it would have appeared way earlier since support for Rover has been present for many months |
No thats the unusual thing build.cmd doesnt present any errors when run |
Hmm, maybe try running |
Great thanks that seems to have resolved it back to linking problems probably due to decleration again. |
Nice! Still have no idea why VS decided to remove the header file |
Yeah not sure its unusual. |
There is a Facebook group, but I myself haven't used it since a long time. |
Yes I agree thats a good idea, the documentation for AirSim would need to reflect this too as there is not an obvious point of contact when onboarding new users/developers with the application. Also after commenting out the linking errors in the application I have managed to compile through to the blocks environment 😀. |
Awesome, now comes the probably more difficult part of modelling, physics and making sure everything works! |
Yes I agree, would you like to open up a communication issue, I'm not sure if you can do a poll on github? |
Don't think I'm the best person to open such a issue, a maintainer should do this probably. They'll also have to setup the platform and maybe maintain it (no other word is coming to my mind right now) |
Yes that makes sense, a moderator or project manager sort of thing. Perhaps if you know anyone you could |
@madratman @saihv @ironclownfish @jonyMarino Do you think having another (more chat & voice type) communication platform will be worthwhile? This will definitely increase community interaction, and will probably reduce support issues. |
@AOS55 AirLib is actually not compiling for me, getting some undeclared identifier errors for the function declarations which have been commented out. Here's a Travis build - https://travis-ci.com/github/rajat2004/AirSim/builds/181419292, even the Windows build fails. Would also recommend activating Travis on your Github repositories (atleast Airsim), that has saved me a few times when making some changes which don't compile on Windows, or breaking something else. (Side note, I did break the Windows build in my first contribution to Airsim (and others later on also), that was a big motivation to get Travis setup properly on Airsim) |
@rajat2004 hmm ok, this is interesting could you please send me the identifier errors you are getting I will cross-check them on my local machine, I just ran update_to_git.bat and had no further changes and I also ran update_from_git.bat in Blocks and it still compiles ok on my end. A couple of thoughts:
Nice Idea, I have setup Travis with my branch, and it also appears to fail. Looking at the job log it has the following on line 1457. I wonder if this is unity related or just what the .travis.yml script should print to the command line.
|
Very strange that it works on your machine, these are the errors I'm getting -
AirLib compilation doesn't depend on UE, Travis also doesn't have UE, it just tests whether AirLib, ROS wrapper compiles, and there's the recently added Azure Pipelines CI which compiles the entire Blocks project on Ubuntu and Windows and packages it. Yup, I'm rebuilding from the root directory, That's just Travis printing the entire command which failed to run, the errors can be seen above it, starting from here |
Hi @AOS55! Thanks for the amazing work you are driving here! I think we can simplify something in your design. I don't know if there is a simple controller for JSBSim (like SimpleFlight), but it is integrated with the autopilots. So it would seem like a good idea to leave the control on the JSBSim side and leave AirSim alone with perception and reporting collisions. What do you all think? |
Hi @jonyMarino thanks a lot. Yes there is xml files for a lot of the aircraft that sets the gains for controllers defined inside JSBSim, for example the c172x ap. I have also found it useful to directly control the aircraft using a python script which I did for the x8. I expect to use the same script to control the aircraft but with collisions also being calculated by airsim, i.e. update_airsim should also return a collision value and the connection between airsim and jsbsim will happen in the airsim C++ side rather than in the python script, this should be what JSBSimPhysicsEngine. |
Great! This development would have an incredible impact if it could be used for multirotors as well. Why is it that I don't see much work done in JSBSim for that? It is not the best option? |
Thanks, yes certainly there are quite a few useful physics simulations included with JSBSim too such as heavier than air powered rotorcraft (helicopters), airships etc that I haven't looked at but I'm sure others would find useful. My best guess as to why multi rotors haven't been extensively developed is probably age? I think JSBSim started in the late 90s or early 2000s and they just weren't considered significantly at this time except for rc aircraft @seanmcleod may know more? |
In terms of JSBSim and multirotors take a look at the following - JSBSim-Team/jsbsim#333 |
Thanks, @seanmcleod! I opened a discussion about integrating with other simulators here: #3284. It would be great if anyone of you can join. |
Hi all. I'm very interested in the integration of AirSim with JSBSim physics in order to model transitioning vehicles. Just wondering what the current status of this project is and how I can help move it forward. |
Hi @tpool2 thanks for your interest I'll put a general summary out of where I have gotten to with JSBSim integration with AirSim: I spent a while getting JSBSim to compile and link in Visual Studio and with mac/linux by adding the relevant commands to the setup.sh and build.sh or build.cmd. When first building in Unreal I've had to add When run with settings.json as:
The programme runs until it gets the following error:
Looking at the call stack this appears to come from here the connect_member function. I haven't made much more progress past this unfortunately and its proven to be a real challenge. |
Has there been any update on the status of this? I'm looking to implement a fixed wing UAV for a camera GPS project I'm working on, and need to do it via airsim. |
Hi @nikitabeebe! you can use @AOS55 fork: https://github.com/AOS55/Fixedwing-Airsim |
Hi @nikitabeebe sorry for the delay in getting back to you the branch jony suggested is still wip I haven’t looked at it in a while hope to get back soon you might find the fixedwing-airsim repo of more use which uses a python backend with the client pose forwarding. I’m going to put some more documentation in this week happy to setup a meeting to talk through it too. |
@AOS55 Thanks for the great work on getting fixedwing working with Airsim! I am interested in supporting fixedwing vehicles in Airsim with a autopilot (PX4) as a SITL simulation. I have looked into https://github.com/AOS55/Fixedwing-Airsim, but it doesn't seem very obvious how this would work with the implementation using python bindings of jsbsim. @AOS55 Would you have any insights how you envision this would work and how this would maybe fit the jsbsim integration on PX4 side as in https://github.com/Auterion/px4-jsbsim-bridge ? Thank you in advance |
@AOS55 really great work ,I like to know what is the progress ,when i tried to open fixed fixed airsim's block environment in unreal I'm getting errors ,Sir please help me out |
Fixed wing in Airsim , Any Modified version of Airsim to work with fixed wing please help @AOS55 |
Hello AOS55, I have download your AirSim-1 branch and merge it into the newest branch of Airsim, with UE version 4.27, I have gained some understanding of its architecture of AirLib. After some tries and fixed some bugs, the prj is able to be compiled, but with run error. I will continue your work to make it run on fixedwing. I also want use fixedwing to train deep reforcement learning algorithms. Once I make some progress, I will share my work. Thanks for your work. |
这是来自QQ邮箱的假期自动回复邮件。
您好,我最近正在休假中,无法亲自回复您的邮件。我将在假期结束后,尽快给您回复。
|
@PiggyGaGa Thanks for your reply! |
|
hi,How did you structure this project? |
Hello I have compiled this prj, and merge it into the main branch of airsim, but the rolling problem has not been solved, recently, i tried to use external fixedwing model and use setvehiclePose() api to simulate fixwing vehicle, that worked. rolling problem may need more time |
Thank you for your reply,How should I get this project, I got this project in the AOSS5 author's repositories, but when I run the build.cmd command it gets an error, you can take a look at my comment above, can you tell me how to solve it |
Hi, does any one solve this build problem that detect two error |
I didn't compile AirSim-1 prj directly, I merged it into the newest version of airsim, I have made some changes on the code, may be your problem is not complex, can you upload more error information, the screenshot above, I can not see any clue. In other word, have you install Visual studio according to airsim doc, and run build.cmd in vs cmd? You can send you problem to my email 1258204115@qq.com. I will also opensource my changes in airsim in the near future, I used airsim to do some slam/fixedwing/evtol simulations, and have done a lot of work. But it seems that, airsim need some more develop, especially the simulation sensors in airsim are not very good in my experiments. For example I used ros_wrapper to do slam, the frequency of imu is very low, so I have to split the imu sensor into a single thread in ros_wrapper, in the default, imu data are bind with control data in one thread in ros_wrapper. |
Fixed Wing Vehicle Integration
I am working on adding a FixedWing aircraft class into Airsim, so far I have been documenting my work under issue #2508 but as suggested by @rajat2004 it would be usefult to move this work to a new issue so as to improve visibility for others to work on.
Work so far
Please see this post for a detailed breakdown of what has been added in my forked Airsim repository under the fixedwing branch. I will aim to keep updates on this issue of new files, classes, methods & functions with a view to write comprehensive documentation as the code begins to get to a state where it can be merged back into the master branch on the main repo.
Since the last update post on #2508 I have been updating the FixedWingLibClient files to enable communication with Ardupilot. A linked issue has been opened within the ArduPilot Repo.
FixedWing Branch State
Known issues
getElevatorSignal()
etc. I am beginning to realise as I work through the control implementation this was not a good way to go about this and the program is already well setup to accept a more conventional control vector, i.e. the u vector in state-space form. I am planning to go back and correct this to a 4 row u vector.moveByLocalVelocity
that takes a booleanyaw mode
switch andrate
as a command these are set asfalse
and0
in the current implementation. But,moveByLocalVelocity
may be better of if rewritten for fixedwing.Planned Future Work
Initially I am aiming to work to resolve all the known issues and turn all the 🔴 in the state to 🟢. Following from this I will aim to add the following functionality:
[ ] Construct a similar Python API as in multirotor <-- hopefully a short term objective
[ ] Implement Undercarriage for fixedWingLandings
[ ] Deep Reinforcement Learning (DRL) based FW landings <-- main PhD objective, expect to write & publish a paper based on this
[ ] Validate model and control on real UAV and FW aircraft, ties in with above.
Motivation
Principally this is for my PhD at the University of Bristol where I am aiming to use a combination of computer vision and Deep Reinforcement Learning to train an autonomous fixedwing agent/aircraft to navigate to and safely land in an unknown location. This is both with and without power and on a range of fixedwing aircraft including fixedWing UAVs, gliders & multiengine light piston aircraft (<5700Kg). Not only this but when discussing AirSim with my colleagues we believe that having a fixedWing simulator capable of highfidelity graphics and SITL that is efficient will be of great benefit.
Ongoing Development
Several users have already been realy helpful (@rajat2004 😀), if anyone has any ideas about how to solve some of the issues I have described above all help is greatly appreciated. In particular if anyone is able to have any success compiling the fixedwing source please let me know as I'm a little stumped 😕 as to why it won't compile.
The text was updated successfully, but these errors were encountered: