Ubuntu 20 + Python3 setup

Hi Dash,

I tried to do the following for my connection template.py:

#####dependencies#####

from dronekit import connect, VehicleMode, LocationGlobalRelative, APIException
import time
import socket
#import exceptions
import math
import argparse

######functions######

def connectMyCopter():

parser = argparse.ArgumentParser(description=‘commands’)
parser.add_argument(‘–connect’)
args = parser.parse_args()

connection_string = args.connect

if not connection_string:
import dronekit_sitl
sitl = dronekit_sitl.start_default()
connection_string = sitl.connection_string()

vehicle = connect(connection_string, wait_ready=True)

return vehicle

vehicle = connectMyCopter()

The script runs without error. However, in the terminal that i run the python script I didnt get the same vehicle returned like the video show (>>APM:copter v xxx >>frame : QUAD). Instead, all i got is this one (which i assume shows that the SITL has started)

abagaskara3@abagaskara3-IdeaPad-3-14ARE05:~/courseRoot/dk$ python connection_template.py
Starting copter simulator (SITL)
Downloading SITL from http://dronekit-assets.s3.amazonaws.com/sitl/copter/sitl-linux-copter-3.3.tar.gz
Download Complete.
Payload Extracted.
Ready to boot.
CRITICAL:autopilot:APM:Copter V3.3 (d6053245)
CRITICAL:autopilot:Frame: QUAD
CRITICAL:autopilot:Calibrating barometer
CRITICAL:autopilot:Initialising APM…
CRITICAL:autopilot:barometer calibration complete
CRITICAL:autopilot:GROUND START
abagaskara3@abagaskara3-IdeaPad-3-14ARE05:~/courseRoot/dk$

If i run the SITL drone separately and specify the IP address in the arguments, this is what i got :
image

are you experiencing the same issue as well? or is this to be expected when you’re using python 3? thanks in advance