|
11 | 11 | import argparse
|
12 | 12 | from logging import basicConfig as logging_basicConfig
|
13 | 13 | from logging import debug as logging_debug
|
14 |
| - |
15 |
| -# from logging import warning as logging_warning |
16 | 14 | from logging import error as logging_error
|
17 | 15 | from logging import getLevelName as logging_getLevelName
|
18 | 16 | from logging import info as logging_info
|
19 | 17 | from sys import exit as sys_exit
|
| 18 | +from webbrowser import open as webbrowser_open |
20 | 19 |
|
21 | 20 | from MethodicConfigurator import _, __version__
|
22 | 21 | from MethodicConfigurator.backend_filesystem import LocalFilesystem
|
| 22 | +from MethodicConfigurator.backend_filesystem_program_settings import ProgramSettings |
23 | 23 | from MethodicConfigurator.backend_flightcontroller import FlightController
|
24 | 24 | from MethodicConfigurator.common_arguments import add_common_arguments_and_parse
|
25 | 25 | from MethodicConfigurator.frontend_tkinter_base import show_error_message
|
@@ -122,6 +122,13 @@ def main() -> None:
|
122 | 122 |
|
123 | 123 | logging_basicConfig(level=logging_getLevelName(args.loglevel), format="%(asctime)s - %(levelname)s - %(message)s")
|
124 | 124 |
|
| 125 | + if bool(ProgramSettings.get_setting("auto_open_doc_in_browser")): |
| 126 | + url = ( |
| 127 | + "https://ardupilot.github.io/MethodicConfigurator/QUICKSTART.html" |
| 128 | + "#5-use-the-ardupilot-methodic-configurator-software-for-the-first-time" |
| 129 | + ) |
| 130 | + webbrowser_open(url=url, new=0, autoraise=True) |
| 131 | + |
125 | 132 | # Connect to the flight controller and read the parameters
|
126 | 133 | flight_controller, vehicle_type = connect_to_fc_and_read_parameters(args)
|
127 | 134 |
|
|
0 commit comments