I am facing a serious trouble. Apparently the dronekit-sitl works for copter and rover but not the plane and causes the following issue:
alphaqueen@DESKTOP-MINFM4M:~$ mavproxy.py --master tcp:127.0.0.1:5760 --sitl 127.0.0.1:5501 --out 127.0.0.1:14550 --out 127.0.0.1:14551
Connect tcp:127.0.0.1:5760 source_system=255
Telemetry log: mav.tlog
Waiting for heartbeat from tcp:127.0.0.1:5760
MAV> AP: Calibrating barometer
online system 1
INITIALISING> Mode INITIALISING
AP: Initialising APM…
PANIC: AP_Baro::read unsuccessful for more than 500ms in AP_Baro::calibrate 
link 1 down
Is it just me or the dronekit-sitl doesn’t support plane??
You can also build sitl from source.
This file has been truncated.
# Setting up the simulation software in Linux
1. Get into the ardupilot project directory.
`cd && cd ardupilot/`
2. Update profile.
## Copter simulation in Linux
1. Go into the ArduCopter directory.
`cd && cd ardupilot/ArduCopter/`
2. Start the simulation with wiping the virtual EEPROM option to load correct parameters.
3. After simulation has started, press Ctrl+C and start the simulation normally.
`sim_vehicle.py --console --map`
Thanks for your reply. Of course I have set the build environment and it works fine with the sitl and I can fly the plane but when it comes to dronekit with sitl to run the external python code for API it doesnt work.
Have you tried that?