From ce6bb989679e18b5d0d730d9ee3b316a66e205cc Mon Sep 17 00:00:00 2001 From: Cristian Maglie Date: Fri, 1 Dec 2023 16:35:06 +0100 Subject: [PATCH] Added `debug check` command to check if a combination of board/programmer supports debugging. (#2443) * Moved rcp message to proper position * Added gRPC command to check for debugger support * Made debug flags var non-global * Implementation of 'debug check' command * Implementation of cli command 'debug check' * added integration test * Renamed field for clarity * Added minimum debug_fqbn computation in 'debug check' command --- arduino/cores/fqbn.go | 10 + commands/daemon/debug.go | 6 + commands/debug/debug.go | 2 +- commands/debug/debug_info.go | 98 +++- internal/cli/debug/debug.go | 29 +- internal/cli/debug/debug_check.go | 96 ++++ internal/integrationtest/debug/debug_test.go | 57 +- .../testdata/hardware/my/samd/boards.txt | 36 ++ rpc/cc/arduino/cli/commands/v1/commands.pb.go | 193 ++++--- rpc/cc/arduino/cli/commands/v1/commands.proto | 5 + .../cli/commands/v1/commands_grpc.pb.go | 41 ++ rpc/cc/arduino/cli/commands/v1/debug.pb.go | 534 ++++++++++++------ rpc/cc/arduino/cli/commands/v1/debug.proto | 41 +- 13 files changed, 844 insertions(+), 304 deletions(-) create mode 100644 internal/cli/debug/debug_check.go diff --git a/arduino/cores/fqbn.go b/arduino/cores/fqbn.go index 35f48c2207e..c5b4384ae5d 100644 --- a/arduino/cores/fqbn.go +++ b/arduino/cores/fqbn.go @@ -30,6 +30,16 @@ type FQBN struct { Configs *properties.Map } +// MustParseFQBN extract an FQBN object from the input string +// or panics if the input is not a valid FQBN. +func MustParseFQBN(fqbnIn string) *FQBN { + res, err := ParseFQBN(fqbnIn) + if err != nil { + panic(err) + } + return res +} + // ParseFQBN extract an FQBN object from the input string func ParseFQBN(fqbnIn string) (*FQBN, error) { // Split fqbn diff --git a/commands/daemon/debug.go b/commands/daemon/debug.go index f888336d3d9..538d2b171d4 100644 --- a/commands/daemon/debug.go +++ b/commands/daemon/debug.go @@ -66,3 +66,9 @@ func (s *ArduinoCoreServerImpl) GetDebugConfig(ctx context.Context, req *rpc.Get res, err := cmd.GetDebugConfig(ctx, req) return res, convertErrorToRPCStatus(err) } + +// IsDebugSupported checks if debugging is supported for a given configuration +func (s *ArduinoCoreServerImpl) IsDebugSupported(ctx context.Context, req *rpc.IsDebugSupportedRequest) (*rpc.IsDebugSupportedResponse, error) { + res, err := cmd.IsDebugSupported(ctx, req) + return res, convertErrorToRPCStatus(err) +} diff --git a/commands/debug/debug.go b/commands/debug/debug.go index d4a822d59f1..a7f3cec0d2a 100644 --- a/commands/debug/debug.go +++ b/commands/debug/debug.go @@ -118,7 +118,7 @@ func Debug(ctx context.Context, req *rpc.GetDebugConfigRequest, inStream io.Read // getCommandLine compose a debug command represented by a core recipe func getCommandLine(req *rpc.GetDebugConfigRequest, pme *packagemanager.Explorer) ([]string, error) { - debugInfo, err := getDebugProperties(req, pme) + debugInfo, err := getDebugProperties(req, pme, false) if err != nil { return nil, err } diff --git a/commands/debug/debug_info.go b/commands/debug/debug_info.go index 919c75cc1b8..2ed1387280c 100644 --- a/commands/debug/debug_info.go +++ b/commands/debug/debug_info.go @@ -18,6 +18,8 @@ package debug import ( "context" "encoding/json" + "errors" + "reflect" "slices" "strconv" "strings" @@ -41,25 +43,83 @@ func GetDebugConfig(ctx context.Context, req *rpc.GetDebugConfigRequest) (*rpc.G return nil, &arduino.InvalidInstanceError{} } defer release() - return getDebugProperties(req, pme) + return getDebugProperties(req, pme, false) } -func getDebugProperties(req *rpc.GetDebugConfigRequest, pme *packagemanager.Explorer) (*rpc.GetDebugConfigResponse, error) { - // TODO: make a generic function to extract sketch from request - // and remove duplication in commands/compile.go - if req.GetSketchPath() == "" { - return nil, &arduino.MissingSketchPathError{} +// IsDebugSupported checks if the given board/programmer configuration supports debugging. +func IsDebugSupported(ctx context.Context, req *rpc.IsDebugSupportedRequest) (*rpc.IsDebugSupportedResponse, error) { + pme, release := instances.GetPackageManagerExplorer(req.GetInstance()) + if pme == nil { + return nil, &arduino.InvalidInstanceError{} + } + defer release() + configRequest := &rpc.GetDebugConfigRequest{ + Instance: req.GetInstance(), + Fqbn: req.GetFqbn(), + SketchPath: "", + Port: req.GetPort(), + Interpreter: req.GetInterpreter(), + ImportDir: "", + Programmer: req.GetProgrammer(), + } + expectedOutput, err := getDebugProperties(configRequest, pme, true) + var x *arduino.FailedDebugError + if errors.As(err, &x) { + return &rpc.IsDebugSupportedResponse{DebuggingSupported: false}, nil } - sketchPath := paths.New(req.GetSketchPath()) - sk, err := sketch.New(sketchPath) if err != nil { - return nil, &arduino.CantOpenSketchError{Cause: err} + return nil, err + } + + // Compute the minimum FQBN required to get the same debug configuration. + // (i.e. the FQBN cleaned up of the options that do not affect the debugger configuration) + minimumFQBN := cores.MustParseFQBN(req.GetFqbn()) + for _, config := range minimumFQBN.Configs.Keys() { + checkFQBN := minimumFQBN.Clone() + checkFQBN.Configs.Remove(config) + configRequest.Fqbn = checkFQBN.String() + checkOutput, err := getDebugProperties(configRequest, pme, true) + if err == nil && reflect.DeepEqual(expectedOutput, checkOutput) { + minimumFQBN.Configs.Remove(config) + } + } + return &rpc.IsDebugSupportedResponse{ + DebuggingSupported: true, + DebugFqbn: minimumFQBN.String(), + }, nil +} + +func getDebugProperties(req *rpc.GetDebugConfigRequest, pme *packagemanager.Explorer, skipSketchChecks bool) (*rpc.GetDebugConfigResponse, error) { + var ( + sketchName string + sketchDefaultFQBN string + sketchDefaultBuildPath *paths.Path + ) + if !skipSketchChecks { + // TODO: make a generic function to extract sketch from request + // and remove duplication in commands/compile.go + if req.GetSketchPath() == "" { + return nil, &arduino.MissingSketchPathError{} + } + sketchPath := paths.New(req.GetSketchPath()) + sk, err := sketch.New(sketchPath) + if err != nil { + return nil, &arduino.CantOpenSketchError{Cause: err} + } + sketchName = sk.Name + sketchDefaultFQBN = sk.GetDefaultFQBN() + sketchDefaultBuildPath = sk.DefaultBuildPath() + } else { + // Use placeholder sketch data + sketchName = "Sketch" + sketchDefaultFQBN = "" + sketchDefaultBuildPath = paths.New("SketchBuildPath") } // XXX Remove this code duplication!! fqbnIn := req.GetFqbn() - if fqbnIn == "" && sk != nil { - fqbnIn = sk.GetDefaultFQBN() + if fqbnIn == "" { + fqbnIn = sketchDefaultFQBN } if fqbnIn == "" { return nil, &arduino.MissingFQBNError{} @@ -124,16 +184,18 @@ func getDebugProperties(req *rpc.GetDebugConfigRequest, pme *packagemanager.Expl if importDir := req.GetImportDir(); importDir != "" { importPath = paths.New(importDir) } else { - importPath = sk.DefaultBuildPath() - } - if !importPath.Exist() { - return nil, &arduino.NotFoundError{Message: tr("Compiled sketch not found in %s", importPath)} + importPath = sketchDefaultBuildPath } - if !importPath.IsDir() { - return nil, &arduino.NotFoundError{Message: tr("Expected compiled sketch in directory %s, but is a file instead", importPath)} + if !skipSketchChecks { + if !importPath.Exist() { + return nil, &arduino.NotFoundError{Message: tr("Compiled sketch not found in %s", importPath)} + } + if !importPath.IsDir() { + return nil, &arduino.NotFoundError{Message: tr("Expected compiled sketch in directory %s, but is a file instead", importPath)} + } } toolProperties.SetPath("build.path", importPath) - toolProperties.Set("build.project_name", sk.Name+".ino") + toolProperties.Set("build.project_name", sketchName+".ino") // Set debug port property port := req.GetPort() diff --git a/internal/cli/debug/debug.go b/internal/cli/debug/debug.go index 65d2459012e..2ffeb7b5ff4 100644 --- a/internal/cli/debug/debug.go +++ b/internal/cli/debug/debug.go @@ -36,27 +36,31 @@ import ( "github.com/spf13/cobra" ) -var ( - fqbnArg arguments.Fqbn - portArgs arguments.Port - interpreter string - importDir string - printInfo bool - programmer arguments.Programmer - tr = i18n.Tr -) +var tr = i18n.Tr // NewCommand created a new `upload` command func NewCommand() *cobra.Command { + var ( + fqbnArg arguments.Fqbn + portArgs arguments.Port + interpreter string + importDir string + printInfo bool + programmer arguments.Programmer + ) + debugCommand := &cobra.Command{ Use: "debug", Short: tr("Debug Arduino sketches."), Long: tr("Debug Arduino sketches. (this command opens an interactive gdb session)"), Example: " " + os.Args[0] + " debug -b arduino:samd:mkr1000 -P atmel_ice /home/user/Arduino/MySketch", Args: cobra.MaximumNArgs(1), - Run: runDebugCommand, + Run: func(cmd *cobra.Command, args []string) { + runDebugCommand(args, &portArgs, &fqbnArg, interpreter, importDir, &programmer, printInfo) + }, } + debugCommand.AddCommand(newDebugCheckCommand()) fqbnArg.AddToCommand(debugCommand) portArgs.AddToCommand(debugCommand) programmer.AddToCommand(debugCommand) @@ -67,7 +71,8 @@ func NewCommand() *cobra.Command { return debugCommand } -func runDebugCommand(command *cobra.Command, args []string) { +func runDebugCommand(args []string, portArgs *arguments.Port, fqbnArg *arguments.Fqbn, + interpreter string, importDir string, programmer *arguments.Programmer, printInfo bool) { instance := instance.CreateAndInit() logrus.Info("Executing `arduino-cli debug`") @@ -81,7 +86,7 @@ func runDebugCommand(command *cobra.Command, args []string) { if err != nil { feedback.FatalError(err, feedback.ErrGeneric) } - fqbn, port := arguments.CalculateFQBNAndPort(&portArgs, &fqbnArg, instance, sk.GetDefaultFqbn(), sk.GetDefaultPort(), sk.GetDefaultProtocol()) + fqbn, port := arguments.CalculateFQBNAndPort(portArgs, fqbnArg, instance, sk.GetDefaultFqbn(), sk.GetDefaultPort(), sk.GetDefaultProtocol()) debugConfigRequested := &rpc.GetDebugConfigRequest{ Instance: instance, Fqbn: fqbn, diff --git a/internal/cli/debug/debug_check.go b/internal/cli/debug/debug_check.go new file mode 100644 index 00000000000..6942ce807a6 --- /dev/null +++ b/internal/cli/debug/debug_check.go @@ -0,0 +1,96 @@ +// This file is part of arduino-cli. +// +// Copyright 2023 ARDUINO SA (http://www.arduino.cc/) +// +// This software is released under the GNU General Public License version 3, +// which covers the main part of arduino-cli. +// The terms of this license can be found at: +// https://www.gnu.org/licenses/gpl-3.0.en.html +// +// You can be released from the requirements of the above licenses by purchasing +// a commercial license. Buying such a license is mandatory if you want to +// modify or otherwise use the software for commercial activities involving the +// Arduino software without disclosing the source code of your own applications. +// To purchase a commercial license, send an email to license@arduino.cc. + +package debug + +import ( + "context" + "os" + + "github.com/arduino/arduino-cli/commands/debug" + "github.com/arduino/arduino-cli/internal/cli/arguments" + "github.com/arduino/arduino-cli/internal/cli/feedback" + "github.com/arduino/arduino-cli/internal/cli/instance" + rpc "github.com/arduino/arduino-cli/rpc/cc/arduino/cli/commands/v1" + "github.com/sirupsen/logrus" + "github.com/spf13/cobra" +) + +func newDebugCheckCommand() *cobra.Command { + var ( + fqbnArg arguments.Fqbn + portArgs arguments.Port + interpreter string + programmer arguments.Programmer + ) + debugCheckCommand := &cobra.Command{ + Use: "check", + Short: tr("Check if the given board/programmer combination supports debugging."), + Example: " " + os.Args[0] + " debug check -b arduino:samd:mkr1000 -P atmel_ice", + Run: func(cmd *cobra.Command, args []string) { + runDebugCheckCommand(&portArgs, &fqbnArg, interpreter, &programmer) + }, + } + fqbnArg.AddToCommand(debugCheckCommand) + portArgs.AddToCommand(debugCheckCommand) + programmer.AddToCommand(debugCheckCommand) + debugCheckCommand.Flags().StringVar(&interpreter, "interpreter", "console", tr("Debug interpreter e.g.: %s", "console, mi, mi1, mi2, mi3")) + return debugCheckCommand +} + +func runDebugCheckCommand(portArgs *arguments.Port, fqbnArg *arguments.Fqbn, interpreter string, programmerArg *arguments.Programmer) { + instance := instance.CreateAndInit() + logrus.Info("Executing `arduino-cli debug`") + + port, err := portArgs.GetPort(instance, "", "") + if err != nil { + feedback.FatalError(err, feedback.ErrBadArgument) + } + fqbn := fqbnArg.String() + resp, err := debug.IsDebugSupported(context.Background(), &rpc.IsDebugSupportedRequest{ + Instance: instance, + Fqbn: fqbn, + Port: port, + Interpreter: interpreter, + Programmer: programmerArg.String(instance, fqbn), + }) + if err != nil { + feedback.FatalError(err, feedback.ErrGeneric) + } + feedback.PrintResult(&debugCheckResult{&isDebugSupportedResponse{ + DebuggingSupported: resp.GetDebuggingSupported(), + DebugFQBN: resp.GetDebugFqbn(), + }}) +} + +type isDebugSupportedResponse struct { + DebuggingSupported bool `json:"debugging_supported"` + DebugFQBN string `json:"debug_fqbn,omitempty"` +} + +type debugCheckResult struct { + Result *isDebugSupportedResponse +} + +func (d *debugCheckResult) Data() interface{} { + return d.Result +} + +func (d *debugCheckResult) String() string { + if d.Result.DebuggingSupported { + return tr("The given board/programmer configuration supports debugging.") + } + return tr("The given board/programmer configuration does NOT support debugging.") +} diff --git a/internal/integrationtest/debug/debug_test.go b/internal/integrationtest/debug/debug_test.go index a01597468ec..12d4c514e78 100644 --- a/internal/integrationtest/debug/debug_test.go +++ b/internal/integrationtest/debug/debug_test.go @@ -33,13 +33,22 @@ func TestDebug(t *testing.T) { require.NoError(t, err) // Install cores + _, _, err = cli.Run("core", "install", "arduino:avr") + require.NoError(t, err) _, _, err = cli.Run("core", "install", "arduino:samd") require.NoError(t, err) + // Install custom core + customHw, err := paths.New("testdata", "hardware").Abs() + require.NoError(t, err) + err = customHw.CopyDirTo(cli.SketchbookDir().Join("hardware")) + require.NoError(t, err) + integrationtest.CLISubtests{ {"Start", testDebuggerStarts}, {"WithPdeSketchStarts", testDebuggerWithPdeSketchStarts}, {"DebugInformation", testAllDebugInformation}, + {"DebugCheck", testDebugCheck}, }.Run(t, env, cli) } @@ -99,12 +108,6 @@ func testAllDebugInformation(t *testing.T, env *integrationtest.Environment, cli _, _, err := cli.Run("sketch", "new", sketchPath.String()) require.NoError(t, err) - // Install custom core - customHw, err := paths.New("testdata", "hardware").Abs() - require.NoError(t, err) - err = customHw.CopyDirTo(cli.SketchbookDir().Join("hardware")) - require.NoError(t, err) - // Build sketch _, _, err = cli.Run("compile", "-b", "my:samd:my", sketchPath.String(), "--format", "json") require.NoError(t, err) @@ -331,3 +334,45 @@ func testAllDebugInformation(t *testing.T, env *integrationtest.Environment, cli } } } + +func testDebugCheck(t *testing.T, env *integrationtest.Environment, cli *integrationtest.ArduinoCLI) { + _, _, err := cli.Run("debug", "check", "-b", "arduino:samd:mkr1000") + require.Error(t, err) + + out, _, err := cli.Run("debug", "check", "-b", "arduino:samd:mkr1000", "-P", "atmel_ice") + require.NoError(t, err) + require.Contains(t, string(out), "The given board/programmer configuration supports debugging.") + + out, _, err = cli.Run("debug", "check", "-b", "arduino:samd:mkr1000", "-P", "atmel_ice", "--format", "json") + require.NoError(t, err) + requirejson.Query(t, out, `.debugging_supported`, `true`) + + out, _, err = cli.Run("debug", "check", "-b", "arduino:avr:uno", "-P", "atmel_ice") + require.NoError(t, err) + require.Contains(t, string(out), "The given board/programmer configuration does NOT support debugging.") + + out, _, err = cli.Run("debug", "check", "-b", "arduino:avr:uno", "-P", "atmel_ice", "--format", "json") + require.NoError(t, err) + requirejson.Query(t, out, `.debugging_supported`, `false`) + + // Test minimum FQBN compute + out, _, err = cli.Run("debug", "check", "-b", "my:samd:my5", "-P", "atmel_ice", "--format", "json") + require.NoError(t, err) + requirejson.Contains(t, out, `{ "debugging_supported" : false }`) + + out, _, err = cli.Run("debug", "check", "-b", "my:samd:my5:dbg=on", "-P", "atmel_ice", "--format", "json") + require.NoError(t, err) + requirejson.Contains(t, out, `{ "debugging_supported" : true, "debug_fqbn" : "my:samd:my5:dbg=on" }`) + + out, _, err = cli.Run("debug", "check", "-b", "my:samd:my5:dbg=on,cpu=150m", "-P", "atmel_ice", "--format", "json") + require.NoError(t, err) + requirejson.Contains(t, out, `{ "debugging_supported" : true, "debug_fqbn" : "my:samd:my5:dbg=on" }`) + + out, _, err = cli.Run("debug", "check", "-b", "my:samd:my6", "-P", "atmel_ice", "--format", "json") + require.NoError(t, err) + requirejson.Contains(t, out, `{ "debugging_supported" : true, "debug_fqbn" : "my:samd:my6" }`) + + out, _, err = cli.Run("debug", "check", "-b", "my:samd:my6:dbg=on", "-P", "atmel_ice", "--format", "json") + require.NoError(t, err) + requirejson.Contains(t, out, `{ "debugging_supported" : true, "debug_fqbn" : "my:samd:my6" }`) +} diff --git a/internal/integrationtest/debug/testdata/hardware/my/samd/boards.txt b/internal/integrationtest/debug/testdata/hardware/my/samd/boards.txt index 5512eb7e2b3..1333aba8231 100644 --- a/internal/integrationtest/debug/testdata/hardware/my/samd/boards.txt +++ b/internal/integrationtest/debug/testdata/hardware/my/samd/boards.txt @@ -112,3 +112,39 @@ my4.build.mcu=test2 # this one will be overwritten by additional_config my4.debug.svd_file=svd-file my4.debug.additional_config=build.debug.config.{build.mcu} + +# menu options for the following boards +menu.dbg=Debugger +menu.cpu=CPU Speed + +# This does not support debug by default but only after selecting a menu option +my5.name=5th Board +my5.build.core=arduino:arduino +my5.build.variant=arduino:mkr1000 +my5.debug.toolchain.path=gcc-path +my5.debug.toolchain.prefix=gcc-prefix +my5.debug.server.openocd.path=openocd-path +my5.debug.server.openocd.scripts_dir=openocd-scripts-dir +my5.debug.server.openocd.script=single-script +my5.debug.executable= +my5.menu.dbg.off=Debug Disabled +my5.menu.dbg.on=Debug Enabled +my5.menu.dbg.on.debug.executable=YES +my5.menu.cpu.100m=100Mhz +my5.menu.cpu.150m=150Mhz + +# this one has debugger enabled by default +my6.name=5th Board +my6.build.core=arduino:arduino +my6.build.variant=arduino:mkr1000 +my6.debug.toolchain.path=gcc-path +my6.debug.toolchain.prefix=gcc-prefix +my6.debug.server.openocd.path=openocd-path +my6.debug.server.openocd.scripts_dir=openocd-scripts-dir +my6.debug.server.openocd.script=single-script +my6.debug.executable= +my6.menu.dbg.on=Debug Enabled +my6.menu.dbg.on.debug.executable=YES +my6.menu.dbg.off=Debug Disabled +my6.menu.cpu.100m=100Mhz +my6.menu.cpu.150m=150Mhz \ No newline at end of file diff --git a/rpc/cc/arduino/cli/commands/v1/commands.pb.go b/rpc/cc/arduino/cli/commands/v1/commands.pb.go index 67afa35e70b..333b4087070 100644 --- a/rpc/cc/arduino/cli/commands/v1/commands.pb.go +++ b/rpc/cc/arduino/cli/commands/v1/commands.pb.go @@ -1664,7 +1664,7 @@ var file_cc_arduino_cli_commands_v1_commands_proto_rawDesc = []byte{ 0x49, 0x4c, 0x45, 0x44, 0x5f, 0x49, 0x4e, 0x53, 0x54, 0x41, 0x4e, 0x43, 0x45, 0x5f, 0x49, 0x4e, 0x49, 0x54, 0x5f, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x49, 0x4e, 0x44, 0x45, 0x58, 0x5f, 0x44, 0x4f, 0x57, 0x4e, 0x4c, 0x4f, 0x41, 0x44, 0x5f, 0x45, 0x52, 0x52, 0x4f, 0x52, 0x10, 0x04, - 0x32, 0xab, 0x27, 0x0a, 0x12, 0x41, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x43, 0x6f, 0x72, 0x65, + 0x32, 0xac, 0x28, 0x0a, 0x12, 0x41, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x43, 0x6f, 0x72, 0x65, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x61, 0x0a, 0x06, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x12, 0x29, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x43, @@ -1971,19 +1971,28 @@ var file_cc_arduino_cli_commands_v1_commands_proto_rawDesc = []byte{ 0x73, 0x74, 0x1a, 0x29, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x62, 0x75, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x28, - 0x01, 0x30, 0x01, 0x12, 0x79, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x62, 0x75, 0x67, 0x43, - 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x31, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, - 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x62, 0x75, 0x67, 0x43, 0x6f, 0x6e, 0x66, 0x69, - 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, - 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, - 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x62, 0x75, 0x67, 0x43, 0x6f, - 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x48, - 0x5a, 0x46, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x61, 0x72, 0x64, - 0x75, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2d, 0x63, 0x6c, 0x69, - 0x2f, 0x72, 0x70, 0x63, 0x2f, 0x63, 0x63, 0x2f, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2f, - 0x63, 0x6c, 0x69, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2f, 0x76, 0x31, 0x3b, - 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x01, 0x30, 0x01, 0x12, 0x7f, 0x0a, 0x10, 0x49, 0x73, 0x44, 0x65, 0x62, 0x75, 0x67, 0x53, 0x75, + 0x70, 0x70, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x12, 0x33, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, + 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, + 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x73, 0x44, 0x65, 0x62, 0x75, 0x67, 0x53, 0x75, 0x70, 0x70, + 0x6f, 0x72, 0x74, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x34, 0x2e, 0x63, + 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, + 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x73, 0x44, 0x65, 0x62, 0x75, + 0x67, 0x53, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x22, 0x00, 0x12, 0x79, 0x0a, 0x0e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x62, 0x75, 0x67, + 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x31, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, + 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, + 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x62, 0x75, 0x67, 0x43, 0x6f, 0x6e, 0x66, + 0x69, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x32, 0x2e, 0x63, 0x63, 0x2e, 0x61, + 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, + 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x62, 0x75, 0x67, 0x43, + 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, + 0x48, 0x5a, 0x46, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x61, 0x72, + 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2d, 0x63, 0x6c, + 0x69, 0x2f, 0x72, 0x70, 0x63, 0x2f, 0x63, 0x63, 0x2f, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, + 0x2f, 0x63, 0x6c, 0x69, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2f, 0x76, 0x31, + 0x3b, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( @@ -2060,38 +2069,40 @@ var file_cc_arduino_cli_commands_v1_commands_proto_goTypes = []interface{}{ (*MonitorRequest)(nil), // 56: cc.arduino.cli.commands.v1.MonitorRequest (*EnumerateMonitorPortSettingsRequest)(nil), // 57: cc.arduino.cli.commands.v1.EnumerateMonitorPortSettingsRequest (*DebugRequest)(nil), // 58: cc.arduino.cli.commands.v1.DebugRequest - (*GetDebugConfigRequest)(nil), // 59: cc.arduino.cli.commands.v1.GetDebugConfigRequest - (*BoardDetailsResponse)(nil), // 60: cc.arduino.cli.commands.v1.BoardDetailsResponse - (*BoardListResponse)(nil), // 61: cc.arduino.cli.commands.v1.BoardListResponse - (*BoardListAllResponse)(nil), // 62: cc.arduino.cli.commands.v1.BoardListAllResponse - (*BoardSearchResponse)(nil), // 63: cc.arduino.cli.commands.v1.BoardSearchResponse - (*BoardListWatchResponse)(nil), // 64: cc.arduino.cli.commands.v1.BoardListWatchResponse - (*CompileResponse)(nil), // 65: cc.arduino.cli.commands.v1.CompileResponse - (*PlatformInstallResponse)(nil), // 66: cc.arduino.cli.commands.v1.PlatformInstallResponse - (*PlatformDownloadResponse)(nil), // 67: cc.arduino.cli.commands.v1.PlatformDownloadResponse - (*PlatformUninstallResponse)(nil), // 68: cc.arduino.cli.commands.v1.PlatformUninstallResponse - (*PlatformUpgradeResponse)(nil), // 69: cc.arduino.cli.commands.v1.PlatformUpgradeResponse - (*UploadResponse)(nil), // 70: cc.arduino.cli.commands.v1.UploadResponse - (*UploadUsingProgrammerResponse)(nil), // 71: cc.arduino.cli.commands.v1.UploadUsingProgrammerResponse - (*SupportedUserFieldsResponse)(nil), // 72: cc.arduino.cli.commands.v1.SupportedUserFieldsResponse - (*ListProgrammersAvailableForUploadResponse)(nil), // 73: cc.arduino.cli.commands.v1.ListProgrammersAvailableForUploadResponse - (*BurnBootloaderResponse)(nil), // 74: cc.arduino.cli.commands.v1.BurnBootloaderResponse - (*PlatformSearchResponse)(nil), // 75: cc.arduino.cli.commands.v1.PlatformSearchResponse - (*PlatformListResponse)(nil), // 76: cc.arduino.cli.commands.v1.PlatformListResponse - (*LibraryDownloadResponse)(nil), // 77: cc.arduino.cli.commands.v1.LibraryDownloadResponse - (*LibraryInstallResponse)(nil), // 78: cc.arduino.cli.commands.v1.LibraryInstallResponse - (*LibraryUpgradeResponse)(nil), // 79: cc.arduino.cli.commands.v1.LibraryUpgradeResponse - (*ZipLibraryInstallResponse)(nil), // 80: cc.arduino.cli.commands.v1.ZipLibraryInstallResponse - (*GitLibraryInstallResponse)(nil), // 81: cc.arduino.cli.commands.v1.GitLibraryInstallResponse - (*LibraryUninstallResponse)(nil), // 82: cc.arduino.cli.commands.v1.LibraryUninstallResponse - (*LibraryUpgradeAllResponse)(nil), // 83: cc.arduino.cli.commands.v1.LibraryUpgradeAllResponse - (*LibraryResolveDependenciesResponse)(nil), // 84: cc.arduino.cli.commands.v1.LibraryResolveDependenciesResponse - (*LibrarySearchResponse)(nil), // 85: cc.arduino.cli.commands.v1.LibrarySearchResponse - (*LibraryListResponse)(nil), // 86: cc.arduino.cli.commands.v1.LibraryListResponse - (*MonitorResponse)(nil), // 87: cc.arduino.cli.commands.v1.MonitorResponse - (*EnumerateMonitorPortSettingsResponse)(nil), // 88: cc.arduino.cli.commands.v1.EnumerateMonitorPortSettingsResponse - (*DebugResponse)(nil), // 89: cc.arduino.cli.commands.v1.DebugResponse - (*GetDebugConfigResponse)(nil), // 90: cc.arduino.cli.commands.v1.GetDebugConfigResponse + (*IsDebugSupportedRequest)(nil), // 59: cc.arduino.cli.commands.v1.IsDebugSupportedRequest + (*GetDebugConfigRequest)(nil), // 60: cc.arduino.cli.commands.v1.GetDebugConfigRequest + (*BoardDetailsResponse)(nil), // 61: cc.arduino.cli.commands.v1.BoardDetailsResponse + (*BoardListResponse)(nil), // 62: cc.arduino.cli.commands.v1.BoardListResponse + (*BoardListAllResponse)(nil), // 63: cc.arduino.cli.commands.v1.BoardListAllResponse + (*BoardSearchResponse)(nil), // 64: cc.arduino.cli.commands.v1.BoardSearchResponse + (*BoardListWatchResponse)(nil), // 65: cc.arduino.cli.commands.v1.BoardListWatchResponse + (*CompileResponse)(nil), // 66: cc.arduino.cli.commands.v1.CompileResponse + (*PlatformInstallResponse)(nil), // 67: cc.arduino.cli.commands.v1.PlatformInstallResponse + (*PlatformDownloadResponse)(nil), // 68: cc.arduino.cli.commands.v1.PlatformDownloadResponse + (*PlatformUninstallResponse)(nil), // 69: cc.arduino.cli.commands.v1.PlatformUninstallResponse + (*PlatformUpgradeResponse)(nil), // 70: cc.arduino.cli.commands.v1.PlatformUpgradeResponse + (*UploadResponse)(nil), // 71: cc.arduino.cli.commands.v1.UploadResponse + (*UploadUsingProgrammerResponse)(nil), // 72: cc.arduino.cli.commands.v1.UploadUsingProgrammerResponse + (*SupportedUserFieldsResponse)(nil), // 73: cc.arduino.cli.commands.v1.SupportedUserFieldsResponse + (*ListProgrammersAvailableForUploadResponse)(nil), // 74: cc.arduino.cli.commands.v1.ListProgrammersAvailableForUploadResponse + (*BurnBootloaderResponse)(nil), // 75: cc.arduino.cli.commands.v1.BurnBootloaderResponse + (*PlatformSearchResponse)(nil), // 76: cc.arduino.cli.commands.v1.PlatformSearchResponse + (*PlatformListResponse)(nil), // 77: cc.arduino.cli.commands.v1.PlatformListResponse + (*LibraryDownloadResponse)(nil), // 78: cc.arduino.cli.commands.v1.LibraryDownloadResponse + (*LibraryInstallResponse)(nil), // 79: cc.arduino.cli.commands.v1.LibraryInstallResponse + (*LibraryUpgradeResponse)(nil), // 80: cc.arduino.cli.commands.v1.LibraryUpgradeResponse + (*ZipLibraryInstallResponse)(nil), // 81: cc.arduino.cli.commands.v1.ZipLibraryInstallResponse + (*GitLibraryInstallResponse)(nil), // 82: cc.arduino.cli.commands.v1.GitLibraryInstallResponse + (*LibraryUninstallResponse)(nil), // 83: cc.arduino.cli.commands.v1.LibraryUninstallResponse + (*LibraryUpgradeAllResponse)(nil), // 84: cc.arduino.cli.commands.v1.LibraryUpgradeAllResponse + (*LibraryResolveDependenciesResponse)(nil), // 85: cc.arduino.cli.commands.v1.LibraryResolveDependenciesResponse + (*LibrarySearchResponse)(nil), // 86: cc.arduino.cli.commands.v1.LibrarySearchResponse + (*LibraryListResponse)(nil), // 87: cc.arduino.cli.commands.v1.LibraryListResponse + (*MonitorResponse)(nil), // 88: cc.arduino.cli.commands.v1.MonitorResponse + (*EnumerateMonitorPortSettingsResponse)(nil), // 89: cc.arduino.cli.commands.v1.EnumerateMonitorPortSettingsResponse + (*DebugResponse)(nil), // 90: cc.arduino.cli.commands.v1.DebugResponse + (*IsDebugSupportedResponse)(nil), // 91: cc.arduino.cli.commands.v1.IsDebugSupportedResponse + (*GetDebugConfigResponse)(nil), // 92: cc.arduino.cli.commands.v1.GetDebugConfigResponse } var file_cc_arduino_cli_commands_v1_commands_proto_depIdxs = []int32{ 24, // 0: cc.arduino.cli.commands.v1.CreateResponse.instance:type_name -> cc.arduino.cli.commands.v1.Instance @@ -2149,50 +2160,52 @@ var file_cc_arduino_cli_commands_v1_commands_proto_depIdxs = []int32{ 56, // 52: cc.arduino.cli.commands.v1.ArduinoCoreService.Monitor:input_type -> cc.arduino.cli.commands.v1.MonitorRequest 57, // 53: cc.arduino.cli.commands.v1.ArduinoCoreService.EnumerateMonitorPortSettings:input_type -> cc.arduino.cli.commands.v1.EnumerateMonitorPortSettingsRequest 58, // 54: cc.arduino.cli.commands.v1.ArduinoCoreService.Debug:input_type -> cc.arduino.cli.commands.v1.DebugRequest - 59, // 55: cc.arduino.cli.commands.v1.ArduinoCoreService.GetDebugConfig:input_type -> cc.arduino.cli.commands.v1.GetDebugConfigRequest - 2, // 56: cc.arduino.cli.commands.v1.ArduinoCoreService.Create:output_type -> cc.arduino.cli.commands.v1.CreateResponse - 4, // 57: cc.arduino.cli.commands.v1.ArduinoCoreService.Init:output_type -> cc.arduino.cli.commands.v1.InitResponse - 7, // 58: cc.arduino.cli.commands.v1.ArduinoCoreService.Destroy:output_type -> cc.arduino.cli.commands.v1.DestroyResponse - 9, // 59: cc.arduino.cli.commands.v1.ArduinoCoreService.UpdateIndex:output_type -> cc.arduino.cli.commands.v1.UpdateIndexResponse - 11, // 60: cc.arduino.cli.commands.v1.ArduinoCoreService.UpdateLibrariesIndex:output_type -> cc.arduino.cli.commands.v1.UpdateLibrariesIndexResponse - 13, // 61: cc.arduino.cli.commands.v1.ArduinoCoreService.Version:output_type -> cc.arduino.cli.commands.v1.VersionResponse - 15, // 62: cc.arduino.cli.commands.v1.ArduinoCoreService.NewSketch:output_type -> cc.arduino.cli.commands.v1.NewSketchResponse - 18, // 63: cc.arduino.cli.commands.v1.ArduinoCoreService.LoadSketch:output_type -> cc.arduino.cli.commands.v1.LoadSketchResponse - 20, // 64: cc.arduino.cli.commands.v1.ArduinoCoreService.ArchiveSketch:output_type -> cc.arduino.cli.commands.v1.ArchiveSketchResponse - 22, // 65: cc.arduino.cli.commands.v1.ArduinoCoreService.SetSketchDefaults:output_type -> cc.arduino.cli.commands.v1.SetSketchDefaultsResponse - 60, // 66: cc.arduino.cli.commands.v1.ArduinoCoreService.BoardDetails:output_type -> cc.arduino.cli.commands.v1.BoardDetailsResponse - 61, // 67: cc.arduino.cli.commands.v1.ArduinoCoreService.BoardList:output_type -> cc.arduino.cli.commands.v1.BoardListResponse - 62, // 68: cc.arduino.cli.commands.v1.ArduinoCoreService.BoardListAll:output_type -> cc.arduino.cli.commands.v1.BoardListAllResponse - 63, // 69: cc.arduino.cli.commands.v1.ArduinoCoreService.BoardSearch:output_type -> cc.arduino.cli.commands.v1.BoardSearchResponse - 64, // 70: cc.arduino.cli.commands.v1.ArduinoCoreService.BoardListWatch:output_type -> cc.arduino.cli.commands.v1.BoardListWatchResponse - 65, // 71: cc.arduino.cli.commands.v1.ArduinoCoreService.Compile:output_type -> cc.arduino.cli.commands.v1.CompileResponse - 66, // 72: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformInstall:output_type -> cc.arduino.cli.commands.v1.PlatformInstallResponse - 67, // 73: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformDownload:output_type -> cc.arduino.cli.commands.v1.PlatformDownloadResponse - 68, // 74: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformUninstall:output_type -> cc.arduino.cli.commands.v1.PlatformUninstallResponse - 69, // 75: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformUpgrade:output_type -> cc.arduino.cli.commands.v1.PlatformUpgradeResponse - 70, // 76: cc.arduino.cli.commands.v1.ArduinoCoreService.Upload:output_type -> cc.arduino.cli.commands.v1.UploadResponse - 71, // 77: cc.arduino.cli.commands.v1.ArduinoCoreService.UploadUsingProgrammer:output_type -> cc.arduino.cli.commands.v1.UploadUsingProgrammerResponse - 72, // 78: cc.arduino.cli.commands.v1.ArduinoCoreService.SupportedUserFields:output_type -> cc.arduino.cli.commands.v1.SupportedUserFieldsResponse - 73, // 79: cc.arduino.cli.commands.v1.ArduinoCoreService.ListProgrammersAvailableForUpload:output_type -> cc.arduino.cli.commands.v1.ListProgrammersAvailableForUploadResponse - 74, // 80: cc.arduino.cli.commands.v1.ArduinoCoreService.BurnBootloader:output_type -> cc.arduino.cli.commands.v1.BurnBootloaderResponse - 75, // 81: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformSearch:output_type -> cc.arduino.cli.commands.v1.PlatformSearchResponse - 76, // 82: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformList:output_type -> cc.arduino.cli.commands.v1.PlatformListResponse - 77, // 83: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryDownload:output_type -> cc.arduino.cli.commands.v1.LibraryDownloadResponse - 78, // 84: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryInstall:output_type -> cc.arduino.cli.commands.v1.LibraryInstallResponse - 79, // 85: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryUpgrade:output_type -> cc.arduino.cli.commands.v1.LibraryUpgradeResponse - 80, // 86: cc.arduino.cli.commands.v1.ArduinoCoreService.ZipLibraryInstall:output_type -> cc.arduino.cli.commands.v1.ZipLibraryInstallResponse - 81, // 87: cc.arduino.cli.commands.v1.ArduinoCoreService.GitLibraryInstall:output_type -> cc.arduino.cli.commands.v1.GitLibraryInstallResponse - 82, // 88: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryUninstall:output_type -> cc.arduino.cli.commands.v1.LibraryUninstallResponse - 83, // 89: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryUpgradeAll:output_type -> cc.arduino.cli.commands.v1.LibraryUpgradeAllResponse - 84, // 90: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryResolveDependencies:output_type -> cc.arduino.cli.commands.v1.LibraryResolveDependenciesResponse - 85, // 91: cc.arduino.cli.commands.v1.ArduinoCoreService.LibrarySearch:output_type -> cc.arduino.cli.commands.v1.LibrarySearchResponse - 86, // 92: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryList:output_type -> cc.arduino.cli.commands.v1.LibraryListResponse - 87, // 93: cc.arduino.cli.commands.v1.ArduinoCoreService.Monitor:output_type -> cc.arduino.cli.commands.v1.MonitorResponse - 88, // 94: cc.arduino.cli.commands.v1.ArduinoCoreService.EnumerateMonitorPortSettings:output_type -> cc.arduino.cli.commands.v1.EnumerateMonitorPortSettingsResponse - 89, // 95: cc.arduino.cli.commands.v1.ArduinoCoreService.Debug:output_type -> cc.arduino.cli.commands.v1.DebugResponse - 90, // 96: cc.arduino.cli.commands.v1.ArduinoCoreService.GetDebugConfig:output_type -> cc.arduino.cli.commands.v1.GetDebugConfigResponse - 56, // [56:97] is the sub-list for method output_type - 15, // [15:56] is the sub-list for method input_type + 59, // 55: cc.arduino.cli.commands.v1.ArduinoCoreService.IsDebugSupported:input_type -> cc.arduino.cli.commands.v1.IsDebugSupportedRequest + 60, // 56: cc.arduino.cli.commands.v1.ArduinoCoreService.GetDebugConfig:input_type -> cc.arduino.cli.commands.v1.GetDebugConfigRequest + 2, // 57: cc.arduino.cli.commands.v1.ArduinoCoreService.Create:output_type -> cc.arduino.cli.commands.v1.CreateResponse + 4, // 58: cc.arduino.cli.commands.v1.ArduinoCoreService.Init:output_type -> cc.arduino.cli.commands.v1.InitResponse + 7, // 59: cc.arduino.cli.commands.v1.ArduinoCoreService.Destroy:output_type -> cc.arduino.cli.commands.v1.DestroyResponse + 9, // 60: cc.arduino.cli.commands.v1.ArduinoCoreService.UpdateIndex:output_type -> cc.arduino.cli.commands.v1.UpdateIndexResponse + 11, // 61: cc.arduino.cli.commands.v1.ArduinoCoreService.UpdateLibrariesIndex:output_type -> cc.arduino.cli.commands.v1.UpdateLibrariesIndexResponse + 13, // 62: cc.arduino.cli.commands.v1.ArduinoCoreService.Version:output_type -> cc.arduino.cli.commands.v1.VersionResponse + 15, // 63: cc.arduino.cli.commands.v1.ArduinoCoreService.NewSketch:output_type -> cc.arduino.cli.commands.v1.NewSketchResponse + 18, // 64: cc.arduino.cli.commands.v1.ArduinoCoreService.LoadSketch:output_type -> cc.arduino.cli.commands.v1.LoadSketchResponse + 20, // 65: cc.arduino.cli.commands.v1.ArduinoCoreService.ArchiveSketch:output_type -> cc.arduino.cli.commands.v1.ArchiveSketchResponse + 22, // 66: cc.arduino.cli.commands.v1.ArduinoCoreService.SetSketchDefaults:output_type -> cc.arduino.cli.commands.v1.SetSketchDefaultsResponse + 61, // 67: cc.arduino.cli.commands.v1.ArduinoCoreService.BoardDetails:output_type -> cc.arduino.cli.commands.v1.BoardDetailsResponse + 62, // 68: cc.arduino.cli.commands.v1.ArduinoCoreService.BoardList:output_type -> cc.arduino.cli.commands.v1.BoardListResponse + 63, // 69: cc.arduino.cli.commands.v1.ArduinoCoreService.BoardListAll:output_type -> cc.arduino.cli.commands.v1.BoardListAllResponse + 64, // 70: cc.arduino.cli.commands.v1.ArduinoCoreService.BoardSearch:output_type -> cc.arduino.cli.commands.v1.BoardSearchResponse + 65, // 71: cc.arduino.cli.commands.v1.ArduinoCoreService.BoardListWatch:output_type -> cc.arduino.cli.commands.v1.BoardListWatchResponse + 66, // 72: cc.arduino.cli.commands.v1.ArduinoCoreService.Compile:output_type -> cc.arduino.cli.commands.v1.CompileResponse + 67, // 73: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformInstall:output_type -> cc.arduino.cli.commands.v1.PlatformInstallResponse + 68, // 74: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformDownload:output_type -> cc.arduino.cli.commands.v1.PlatformDownloadResponse + 69, // 75: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformUninstall:output_type -> cc.arduino.cli.commands.v1.PlatformUninstallResponse + 70, // 76: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformUpgrade:output_type -> cc.arduino.cli.commands.v1.PlatformUpgradeResponse + 71, // 77: cc.arduino.cli.commands.v1.ArduinoCoreService.Upload:output_type -> cc.arduino.cli.commands.v1.UploadResponse + 72, // 78: cc.arduino.cli.commands.v1.ArduinoCoreService.UploadUsingProgrammer:output_type -> cc.arduino.cli.commands.v1.UploadUsingProgrammerResponse + 73, // 79: cc.arduino.cli.commands.v1.ArduinoCoreService.SupportedUserFields:output_type -> cc.arduino.cli.commands.v1.SupportedUserFieldsResponse + 74, // 80: cc.arduino.cli.commands.v1.ArduinoCoreService.ListProgrammersAvailableForUpload:output_type -> cc.arduino.cli.commands.v1.ListProgrammersAvailableForUploadResponse + 75, // 81: cc.arduino.cli.commands.v1.ArduinoCoreService.BurnBootloader:output_type -> cc.arduino.cli.commands.v1.BurnBootloaderResponse + 76, // 82: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformSearch:output_type -> cc.arduino.cli.commands.v1.PlatformSearchResponse + 77, // 83: cc.arduino.cli.commands.v1.ArduinoCoreService.PlatformList:output_type -> cc.arduino.cli.commands.v1.PlatformListResponse + 78, // 84: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryDownload:output_type -> cc.arduino.cli.commands.v1.LibraryDownloadResponse + 79, // 85: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryInstall:output_type -> cc.arduino.cli.commands.v1.LibraryInstallResponse + 80, // 86: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryUpgrade:output_type -> cc.arduino.cli.commands.v1.LibraryUpgradeResponse + 81, // 87: cc.arduino.cli.commands.v1.ArduinoCoreService.ZipLibraryInstall:output_type -> cc.arduino.cli.commands.v1.ZipLibraryInstallResponse + 82, // 88: cc.arduino.cli.commands.v1.ArduinoCoreService.GitLibraryInstall:output_type -> cc.arduino.cli.commands.v1.GitLibraryInstallResponse + 83, // 89: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryUninstall:output_type -> cc.arduino.cli.commands.v1.LibraryUninstallResponse + 84, // 90: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryUpgradeAll:output_type -> cc.arduino.cli.commands.v1.LibraryUpgradeAllResponse + 85, // 91: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryResolveDependencies:output_type -> cc.arduino.cli.commands.v1.LibraryResolveDependenciesResponse + 86, // 92: cc.arduino.cli.commands.v1.ArduinoCoreService.LibrarySearch:output_type -> cc.arduino.cli.commands.v1.LibrarySearchResponse + 87, // 93: cc.arduino.cli.commands.v1.ArduinoCoreService.LibraryList:output_type -> cc.arduino.cli.commands.v1.LibraryListResponse + 88, // 94: cc.arduino.cli.commands.v1.ArduinoCoreService.Monitor:output_type -> cc.arduino.cli.commands.v1.MonitorResponse + 89, // 95: cc.arduino.cli.commands.v1.ArduinoCoreService.EnumerateMonitorPortSettings:output_type -> cc.arduino.cli.commands.v1.EnumerateMonitorPortSettingsResponse + 90, // 96: cc.arduino.cli.commands.v1.ArduinoCoreService.Debug:output_type -> cc.arduino.cli.commands.v1.DebugResponse + 91, // 97: cc.arduino.cli.commands.v1.ArduinoCoreService.IsDebugSupported:output_type -> cc.arduino.cli.commands.v1.IsDebugSupportedResponse + 92, // 98: cc.arduino.cli.commands.v1.ArduinoCoreService.GetDebugConfig:output_type -> cc.arduino.cli.commands.v1.GetDebugConfigResponse + 57, // [57:99] is the sub-list for method output_type + 15, // [15:57] is the sub-list for method input_type 15, // [15:15] is the sub-list for extension type_name 15, // [15:15] is the sub-list for extension extendee 0, // [0:15] is the sub-list for field type_name diff --git a/rpc/cc/arduino/cli/commands/v1/commands.proto b/rpc/cc/arduino/cli/commands/v1/commands.proto index d16aab2c5a5..76f50210a58 100644 --- a/rpc/cc/arduino/cli/commands/v1/commands.proto +++ b/rpc/cc/arduino/cli/commands/v1/commands.proto @@ -184,6 +184,11 @@ service ArduinoCoreService { // Start a debug session and communicate with the debugger tool. rpc Debug(stream DebugRequest) returns (stream DebugResponse) {} + // Determine if debugging is suported given a specific configuration. + rpc IsDebugSupported(IsDebugSupportedRequest) + returns (IsDebugSupportedResponse) {} + + // Query the debugger information given a specific configuration. rpc GetDebugConfig(GetDebugConfigRequest) returns (GetDebugConfigResponse) {} } diff --git a/rpc/cc/arduino/cli/commands/v1/commands_grpc.pb.go b/rpc/cc/arduino/cli/commands/v1/commands_grpc.pb.go index 454d07dd5d2..2772b0aa1df 100644 --- a/rpc/cc/arduino/cli/commands/v1/commands_grpc.pb.go +++ b/rpc/cc/arduino/cli/commands/v1/commands_grpc.pb.go @@ -74,6 +74,7 @@ const ( ArduinoCoreService_Monitor_FullMethodName = "/cc.arduino.cli.commands.v1.ArduinoCoreService/Monitor" ArduinoCoreService_EnumerateMonitorPortSettings_FullMethodName = "/cc.arduino.cli.commands.v1.ArduinoCoreService/EnumerateMonitorPortSettings" ArduinoCoreService_Debug_FullMethodName = "/cc.arduino.cli.commands.v1.ArduinoCoreService/Debug" + ArduinoCoreService_IsDebugSupported_FullMethodName = "/cc.arduino.cli.commands.v1.ArduinoCoreService/IsDebugSupported" ArduinoCoreService_GetDebugConfig_FullMethodName = "/cc.arduino.cli.commands.v1.ArduinoCoreService/GetDebugConfig" ) @@ -169,6 +170,9 @@ type ArduinoCoreServiceClient interface { EnumerateMonitorPortSettings(ctx context.Context, in *EnumerateMonitorPortSettingsRequest, opts ...grpc.CallOption) (*EnumerateMonitorPortSettingsResponse, error) // Start a debug session and communicate with the debugger tool. Debug(ctx context.Context, opts ...grpc.CallOption) (ArduinoCoreService_DebugClient, error) + // Determine if debugging is suported given a specific configuration. + IsDebugSupported(ctx context.Context, in *IsDebugSupportedRequest, opts ...grpc.CallOption) (*IsDebugSupportedResponse, error) + // Query the debugger information given a specific configuration. GetDebugConfig(ctx context.Context, in *GetDebugConfigRequest, opts ...grpc.CallOption) (*GetDebugConfigResponse, error) } @@ -1021,6 +1025,15 @@ func (x *arduinoCoreServiceDebugClient) Recv() (*DebugResponse, error) { return m, nil } +func (c *arduinoCoreServiceClient) IsDebugSupported(ctx context.Context, in *IsDebugSupportedRequest, opts ...grpc.CallOption) (*IsDebugSupportedResponse, error) { + out := new(IsDebugSupportedResponse) + err := c.cc.Invoke(ctx, ArduinoCoreService_IsDebugSupported_FullMethodName, in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + func (c *arduinoCoreServiceClient) GetDebugConfig(ctx context.Context, in *GetDebugConfigRequest, opts ...grpc.CallOption) (*GetDebugConfigResponse, error) { out := new(GetDebugConfigResponse) err := c.cc.Invoke(ctx, ArduinoCoreService_GetDebugConfig_FullMethodName, in, out, opts...) @@ -1122,6 +1135,9 @@ type ArduinoCoreServiceServer interface { EnumerateMonitorPortSettings(context.Context, *EnumerateMonitorPortSettingsRequest) (*EnumerateMonitorPortSettingsResponse, error) // Start a debug session and communicate with the debugger tool. Debug(ArduinoCoreService_DebugServer) error + // Determine if debugging is suported given a specific configuration. + IsDebugSupported(context.Context, *IsDebugSupportedRequest) (*IsDebugSupportedResponse, error) + // Query the debugger information given a specific configuration. GetDebugConfig(context.Context, *GetDebugConfigRequest) (*GetDebugConfigResponse, error) mustEmbedUnimplementedArduinoCoreServiceServer() } @@ -1250,6 +1266,9 @@ func (UnimplementedArduinoCoreServiceServer) EnumerateMonitorPortSettings(contex func (UnimplementedArduinoCoreServiceServer) Debug(ArduinoCoreService_DebugServer) error { return status.Errorf(codes.Unimplemented, "method Debug not implemented") } +func (UnimplementedArduinoCoreServiceServer) IsDebugSupported(context.Context, *IsDebugSupportedRequest) (*IsDebugSupportedResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method IsDebugSupported not implemented") +} func (UnimplementedArduinoCoreServiceServer) GetDebugConfig(context.Context, *GetDebugConfigRequest) (*GetDebugConfigResponse, error) { return nil, status.Errorf(codes.Unimplemented, "method GetDebugConfig not implemented") } @@ -2059,6 +2078,24 @@ func (x *arduinoCoreServiceDebugServer) Recv() (*DebugRequest, error) { return m, nil } +func _ArduinoCoreService_IsDebugSupported_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(IsDebugSupportedRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(ArduinoCoreServiceServer).IsDebugSupported(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: ArduinoCoreService_IsDebugSupported_FullMethodName, + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(ArduinoCoreServiceServer).IsDebugSupported(ctx, req.(*IsDebugSupportedRequest)) + } + return interceptor(ctx, in, info, handler) +} + func _ArduinoCoreService_GetDebugConfig_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(GetDebugConfigRequest) if err := dec(in); err != nil { @@ -2160,6 +2197,10 @@ var ArduinoCoreService_ServiceDesc = grpc.ServiceDesc{ MethodName: "EnumerateMonitorPortSettings", Handler: _ArduinoCoreService_EnumerateMonitorPortSettings_Handler, }, + { + MethodName: "IsDebugSupported", + Handler: _ArduinoCoreService_IsDebugSupported_Handler, + }, { MethodName: "GetDebugConfig", Handler: _ArduinoCoreService_GetDebugConfig_Handler, diff --git a/rpc/cc/arduino/cli/commands/v1/debug.pb.go b/rpc/cc/arduino/cli/commands/v1/debug.pb.go index fa8c52bed21..a596613a8e2 100644 --- a/rpc/cc/arduino/cli/commands/v1/debug.pb.go +++ b/rpc/cc/arduino/cli/commands/v1/debug.pb.go @@ -109,34 +109,21 @@ func (x *DebugRequest) GetSendInterrupt() bool { return false } -type GetDebugConfigRequest struct { +// The streaming response may contain chunks of data from the debugger or an +// error. +type DebugResponse struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - // Arduino Core Service instance from the `Init` response. - Instance *Instance `protobuf:"bytes,1,opt,name=instance,proto3" json:"instance,omitempty"` - // Fully qualified board name of the board in use - // (e.g., `arduino:samd:mkr1000`). If this is omitted, the FQBN attached to - // the sketch will be used. - Fqbn string `protobuf:"bytes,2,opt,name=fqbn,proto3" json:"fqbn,omitempty"` - // Path to the sketch that is running on the board. The compiled executable - // is expected to be located under this path. - SketchPath string `protobuf:"bytes,3,opt,name=sketch_path,json=sketchPath,proto3" json:"sketch_path,omitempty"` - // Port of the debugger (optional). - Port *Port `protobuf:"bytes,4,opt,name=port,proto3" json:"port,omitempty"` - // Which GDB command interpreter to use. - Interpreter string `protobuf:"bytes,5,opt,name=interpreter,proto3" json:"interpreter,omitempty"` - // Directory containing the compiled executable. If `import_dir` is not - // specified, the executable is assumed to be in - // `{sketch_path}/build/{fqbn}/`. - ImportDir string `protobuf:"bytes,8,opt,name=import_dir,json=importDir,proto3" json:"import_dir,omitempty"` - // The programmer to use for debugging. - Programmer string `protobuf:"bytes,9,opt,name=programmer,proto3" json:"programmer,omitempty"` + // Incoming data from the debugger tool. + Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"` + // Incoming error output from the debugger tool. + Error string `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"` } -func (x *GetDebugConfigRequest) Reset() { - *x = GetDebugConfigRequest{} +func (x *DebugResponse) Reset() { + *x = DebugResponse{} if protoimpl.UnsafeEnabled { mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[1] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -144,13 +131,13 @@ func (x *GetDebugConfigRequest) Reset() { } } -func (x *GetDebugConfigRequest) String() string { +func (x *DebugResponse) String() string { return protoimpl.X.MessageStringOf(x) } -func (*GetDebugConfigRequest) ProtoMessage() {} +func (*DebugResponse) ProtoMessage() {} -func (x *GetDebugConfigRequest) ProtoReflect() protoreflect.Message { +func (x *DebugResponse) ProtoReflect() protoreflect.Message { mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[1] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) @@ -162,88 +149,213 @@ func (x *GetDebugConfigRequest) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use GetDebugConfigRequest.ProtoReflect.Descriptor instead. -func (*GetDebugConfigRequest) Descriptor() ([]byte, []int) { +// Deprecated: Use DebugResponse.ProtoReflect.Descriptor instead. +func (*DebugResponse) Descriptor() ([]byte, []int) { return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{1} } -func (x *GetDebugConfigRequest) GetInstance() *Instance { +func (x *DebugResponse) GetData() []byte { if x != nil { - return x.Instance + return x.Data } return nil } -func (x *GetDebugConfigRequest) GetFqbn() string { +func (x *DebugResponse) GetError() string { if x != nil { - return x.Fqbn + return x.Error } return "" } -func (x *GetDebugConfigRequest) GetSketchPath() string { +type IsDebugSupportedRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Arduino Core Service instance from the `Init` response. + Instance *Instance `protobuf:"bytes,1,opt,name=instance,proto3" json:"instance,omitempty"` + // Fully qualified board name of the board in use (e.g., + // `arduino:samd:mkr1000`). + Fqbn string `protobuf:"bytes,2,opt,name=fqbn,proto3" json:"fqbn,omitempty"` + // Port of the debugger (optional). + Port *Port `protobuf:"bytes,3,opt,name=port,proto3" json:"port,omitempty"` + // Which GDB command interpreter to use. + Interpreter string `protobuf:"bytes,4,opt,name=interpreter,proto3" json:"interpreter,omitempty"` + // The programmer to use for debugging. + Programmer string `protobuf:"bytes,5,opt,name=programmer,proto3" json:"programmer,omitempty"` +} + +func (x *IsDebugSupportedRequest) Reset() { + *x = IsDebugSupportedRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *IsDebugSupportedRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*IsDebugSupportedRequest) ProtoMessage() {} + +func (x *IsDebugSupportedRequest) ProtoReflect() protoreflect.Message { + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use IsDebugSupportedRequest.ProtoReflect.Descriptor instead. +func (*IsDebugSupportedRequest) Descriptor() ([]byte, []int) { + return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{2} +} + +func (x *IsDebugSupportedRequest) GetInstance() *Instance { if x != nil { - return x.SketchPath + return x.Instance + } + return nil +} + +func (x *IsDebugSupportedRequest) GetFqbn() string { + if x != nil { + return x.Fqbn } return "" } -func (x *GetDebugConfigRequest) GetPort() *Port { +func (x *IsDebugSupportedRequest) GetPort() *Port { if x != nil { return x.Port } return nil } -func (x *GetDebugConfigRequest) GetInterpreter() string { +func (x *IsDebugSupportedRequest) GetInterpreter() string { if x != nil { return x.Interpreter } return "" } -func (x *GetDebugConfigRequest) GetImportDir() string { +func (x *IsDebugSupportedRequest) GetProgrammer() string { if x != nil { - return x.ImportDir + return x.Programmer } return "" } -func (x *GetDebugConfigRequest) GetProgrammer() string { +type IsDebugSupportedResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // True if debugging is supported + DebuggingSupported bool `protobuf:"varint,1,opt,name=debugging_supported,json=debuggingSupported,proto3" json:"debugging_supported,omitempty"` + // This is the same FQBN given in the IsDebugSupportedRequest but cleaned + // up of the board options that do not affect the debugger configuration. + // It may be used by clients/IDE to group slightly different boards option + // selections under the same debug configuration. + DebugFqbn string `protobuf:"bytes,2,opt,name=debug_fqbn,json=debugFqbn,proto3" json:"debug_fqbn,omitempty"` +} + +func (x *IsDebugSupportedResponse) Reset() { + *x = IsDebugSupportedResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *IsDebugSupportedResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*IsDebugSupportedResponse) ProtoMessage() {} + +func (x *IsDebugSupportedResponse) ProtoReflect() protoreflect.Message { + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[3] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use IsDebugSupportedResponse.ProtoReflect.Descriptor instead. +func (*IsDebugSupportedResponse) Descriptor() ([]byte, []int) { + return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{3} +} + +func (x *IsDebugSupportedResponse) GetDebuggingSupported() bool { if x != nil { - return x.Programmer + return x.DebuggingSupported + } + return false +} + +func (x *IsDebugSupportedResponse) GetDebugFqbn() string { + if x != nil { + return x.DebugFqbn } return "" } -type DebugResponse struct { +type GetDebugConfigRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - // Incoming data from the debugger tool. - Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"` - // Incoming error output from the debugger tool. - Error string `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"` + // Arduino Core Service instance from the `Init` response. + Instance *Instance `protobuf:"bytes,1,opt,name=instance,proto3" json:"instance,omitempty"` + // Fully qualified board name of the board in use + // (e.g., `arduino:samd:mkr1000`). If this is omitted, the FQBN attached to + // the sketch will be used. + Fqbn string `protobuf:"bytes,2,opt,name=fqbn,proto3" json:"fqbn,omitempty"` + // Path to the sketch that is running on the board. The compiled executable + // is expected to be located under this path. + SketchPath string `protobuf:"bytes,3,opt,name=sketch_path,json=sketchPath,proto3" json:"sketch_path,omitempty"` + // Port of the debugger (optional). + Port *Port `protobuf:"bytes,4,opt,name=port,proto3" json:"port,omitempty"` + // Which GDB command interpreter to use. + Interpreter string `protobuf:"bytes,5,opt,name=interpreter,proto3" json:"interpreter,omitempty"` + // Directory containing the compiled executable. If `import_dir` is not + // specified, the executable is assumed to be in + // `{sketch_path}/build/{fqbn}/`. + ImportDir string `protobuf:"bytes,8,opt,name=import_dir,json=importDir,proto3" json:"import_dir,omitempty"` + // The programmer to use for debugging. + Programmer string `protobuf:"bytes,9,opt,name=programmer,proto3" json:"programmer,omitempty"` } -func (x *DebugResponse) Reset() { - *x = DebugResponse{} +func (x *GetDebugConfigRequest) Reset() { + *x = GetDebugConfigRequest{} if protoimpl.UnsafeEnabled { - mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[2] + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } } -func (x *DebugResponse) String() string { +func (x *GetDebugConfigRequest) String() string { return protoimpl.X.MessageStringOf(x) } -func (*DebugResponse) ProtoMessage() {} +func (*GetDebugConfigRequest) ProtoMessage() {} -func (x *DebugResponse) ProtoReflect() protoreflect.Message { - mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[2] +func (x *GetDebugConfigRequest) ProtoReflect() protoreflect.Message { + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -254,21 +366,56 @@ func (x *DebugResponse) ProtoReflect() protoreflect.Message { return mi.MessageOf(x) } -// Deprecated: Use DebugResponse.ProtoReflect.Descriptor instead. -func (*DebugResponse) Descriptor() ([]byte, []int) { - return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{2} +// Deprecated: Use GetDebugConfigRequest.ProtoReflect.Descriptor instead. +func (*GetDebugConfigRequest) Descriptor() ([]byte, []int) { + return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{4} } -func (x *DebugResponse) GetData() []byte { +func (x *GetDebugConfigRequest) GetInstance() *Instance { if x != nil { - return x.Data + return x.Instance } return nil } -func (x *DebugResponse) GetError() string { +func (x *GetDebugConfigRequest) GetFqbn() string { if x != nil { - return x.Error + return x.Fqbn + } + return "" +} + +func (x *GetDebugConfigRequest) GetSketchPath() string { + if x != nil { + return x.SketchPath + } + return "" +} + +func (x *GetDebugConfigRequest) GetPort() *Port { + if x != nil { + return x.Port + } + return nil +} + +func (x *GetDebugConfigRequest) GetInterpreter() string { + if x != nil { + return x.Interpreter + } + return "" +} + +func (x *GetDebugConfigRequest) GetImportDir() string { + if x != nil { + return x.ImportDir + } + return "" +} + +func (x *GetDebugConfigRequest) GetProgrammer() string { + if x != nil { + return x.Programmer } return "" } @@ -309,7 +456,7 @@ type GetDebugConfigResponse struct { func (x *GetDebugConfigResponse) Reset() { *x = GetDebugConfigResponse{} if protoimpl.UnsafeEnabled { - mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[3] + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[5] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -322,7 +469,7 @@ func (x *GetDebugConfigResponse) String() string { func (*GetDebugConfigResponse) ProtoMessage() {} func (x *GetDebugConfigResponse) ProtoReflect() protoreflect.Message { - mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[3] + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[5] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -335,7 +482,7 @@ func (x *GetDebugConfigResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetDebugConfigResponse.ProtoReflect.Descriptor instead. func (*GetDebugConfigResponse) Descriptor() ([]byte, []int) { - return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{3} + return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{5} } func (x *GetDebugConfigResponse) GetExecutable() string { @@ -425,7 +572,7 @@ type DebugGCCToolchainConfiguration struct { func (x *DebugGCCToolchainConfiguration) Reset() { *x = DebugGCCToolchainConfiguration{} if protoimpl.UnsafeEnabled { - mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[4] + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[6] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -438,7 +585,7 @@ func (x *DebugGCCToolchainConfiguration) String() string { func (*DebugGCCToolchainConfiguration) ProtoMessage() {} func (x *DebugGCCToolchainConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[4] + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[6] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -451,7 +598,7 @@ func (x *DebugGCCToolchainConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use DebugGCCToolchainConfiguration.ProtoReflect.Descriptor instead. func (*DebugGCCToolchainConfiguration) Descriptor() ([]byte, []int) { - return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{4} + return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{6} } // Configuration specific for the 'openocd` server @@ -471,7 +618,7 @@ type DebugOpenOCDServerConfiguration struct { func (x *DebugOpenOCDServerConfiguration) Reset() { *x = DebugOpenOCDServerConfiguration{} if protoimpl.UnsafeEnabled { - mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[5] + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -484,7 +631,7 @@ func (x *DebugOpenOCDServerConfiguration) String() string { func (*DebugOpenOCDServerConfiguration) ProtoMessage() {} func (x *DebugOpenOCDServerConfiguration) ProtoReflect() protoreflect.Message { - mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[5] + mi := &file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -497,7 +644,7 @@ func (x *DebugOpenOCDServerConfiguration) ProtoReflect() protoreflect.Message { // Deprecated: Use DebugOpenOCDServerConfiguration.ProtoReflect.Descriptor instead. func (*DebugOpenOCDServerConfiguration) Descriptor() ([]byte, []int) { - return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{5} + return file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP(), []int{7} } func (x *DebugOpenOCDServerConfiguration) GetPath() string { @@ -545,82 +692,103 @@ var file_cc_arduino_cli_commands_v1_debug_proto_rawDesc = []byte{ 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x25, 0x0a, 0x0e, 0x73, 0x65, 0x6e, 0x64, 0x5f, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x72, 0x75, 0x70, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0d, 0x73, 0x65, 0x6e, 0x64, 0x49, 0x6e, 0x74, 0x65, 0x72, 0x72, - 0x75, 0x70, 0x74, 0x22, 0xa5, 0x02, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x44, 0x65, 0x62, 0x75, 0x67, - 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x40, 0x0a, - 0x08, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x24, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, - 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, - 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x08, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, - 0x12, 0x0a, 0x04, 0x66, 0x71, 0x62, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x66, - 0x71, 0x62, 0x6e, 0x12, 0x1f, 0x0a, 0x0b, 0x73, 0x6b, 0x65, 0x74, 0x63, 0x68, 0x5f, 0x70, 0x61, - 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x6b, 0x65, 0x74, 0x63, 0x68, - 0x50, 0x61, 0x74, 0x68, 0x12, 0x34, 0x0a, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, - 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, - 0x50, 0x6f, 0x72, 0x74, 0x52, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x69, 0x6e, - 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0b, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, - 0x69, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x5f, 0x64, 0x69, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x09, 0x69, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x44, 0x69, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x70, - 0x72, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x6d, 0x65, 0x72, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x70, 0x72, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x6d, 0x65, 0x72, 0x22, 0x39, 0x0a, 0x0d, 0x44, - 0x65, 0x62, 0x75, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, - 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, - 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0xe4, 0x04, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x44, 0x65, - 0x62, 0x75, 0x67, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x61, 0x62, 0x6c, - 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x12, - 0x25, 0x0a, 0x0e, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, 0x70, 0x61, 0x74, - 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, - 0x69, 0x6e, 0x50, 0x61, 0x74, 0x68, 0x12, 0x29, 0x0a, 0x10, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, - 0x61, 0x69, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0f, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x50, 0x72, 0x65, 0x66, 0x69, - 0x78, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x06, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x12, 0x1f, 0x0a, 0x0b, 0x73, 0x65, 0x72, - 0x76, 0x65, 0x72, 0x5f, 0x70, 0x61, 0x74, 0x68, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, - 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x50, 0x61, 0x74, 0x68, 0x12, 0x4d, 0x0a, 0x17, 0x74, 0x6f, - 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, - 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, - 0x79, 0x52, 0x16, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, - 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x47, 0x0a, 0x14, 0x73, 0x65, 0x72, - 0x76, 0x65, 0x72, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x13, 0x73, - 0x65, 0x72, 0x76, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x12, 0x6c, 0x0a, 0x0e, 0x63, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x5f, 0x63, 0x6f, 0x6e, - 0x66, 0x69, 0x67, 0x73, 0x18, 0x09, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x45, 0x2e, 0x63, 0x63, 0x2e, - 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, - 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x65, 0x62, 0x75, 0x67, - 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x73, 0x45, 0x6e, 0x74, 0x72, - 0x79, 0x52, 0x0d, 0x63, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x73, - 0x12, 0x19, 0x0a, 0x08, 0x73, 0x76, 0x64, 0x5f, 0x66, 0x69, 0x6c, 0x65, 0x18, 0x0a, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x07, 0x73, 0x76, 0x64, 0x46, 0x69, 0x6c, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x70, - 0x72, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x6d, 0x65, 0x72, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x0a, 0x70, 0x72, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x6d, 0x65, 0x72, 0x1a, 0x40, 0x0a, 0x12, 0x43, - 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x73, 0x45, 0x6e, 0x74, 0x72, - 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, - 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0x20, 0x0a, - 0x1e, 0x44, 0x65, 0x62, 0x75, 0x67, 0x47, 0x43, 0x43, 0x54, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, - 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, - 0x70, 0x0a, 0x1f, 0x44, 0x65, 0x62, 0x75, 0x67, 0x4f, 0x70, 0x65, 0x6e, 0x4f, 0x43, 0x44, 0x53, - 0x65, 0x72, 0x76, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1f, 0x0a, 0x0b, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, - 0x73, 0x5f, 0x64, 0x69, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x63, 0x72, - 0x69, 0x70, 0x74, 0x73, 0x44, 0x69, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x63, 0x72, 0x69, 0x70, - 0x74, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, - 0x73, 0x42, 0x48, 0x5a, 0x46, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, - 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2d, - 0x63, 0x6c, 0x69, 0x2f, 0x72, 0x70, 0x63, 0x2f, 0x63, 0x63, 0x2f, 0x61, 0x72, 0x64, 0x75, 0x69, - 0x6e, 0x6f, 0x2f, 0x63, 0x6c, 0x69, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2f, - 0x76, 0x31, 0x3b, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x33, + 0x75, 0x70, 0x74, 0x22, 0x39, 0x0a, 0x0d, 0x44, 0x65, 0x62, 0x75, 0x67, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x0c, 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x14, 0x0a, 0x05, 0x65, 0x72, 0x72, 0x6f, + 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x22, 0xe7, + 0x01, 0x0a, 0x17, 0x49, 0x73, 0x44, 0x65, 0x62, 0x75, 0x67, 0x53, 0x75, 0x70, 0x70, 0x6f, 0x72, + 0x74, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x40, 0x0a, 0x08, 0x69, 0x6e, + 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x63, + 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, + 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, + 0x63, 0x65, 0x52, 0x08, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x12, 0x0a, 0x04, + 0x66, 0x71, 0x62, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x66, 0x71, 0x62, 0x6e, + 0x12, 0x34, 0x0a, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, + 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, 0x69, 0x2e, + 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x6f, 0x72, 0x74, + 0x52, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, + 0x72, 0x65, 0x74, 0x65, 0x72, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x69, 0x6e, 0x74, + 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x72, 0x6f, 0x67, + 0x72, 0x61, 0x6d, 0x6d, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x72, + 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x6d, 0x65, 0x72, 0x22, 0x6a, 0x0a, 0x18, 0x49, 0x73, 0x44, 0x65, + 0x62, 0x75, 0x67, 0x53, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2f, 0x0a, 0x13, 0x64, 0x65, 0x62, 0x75, 0x67, 0x67, 0x69, 0x6e, + 0x67, 0x5f, 0x73, 0x75, 0x70, 0x70, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x08, 0x52, 0x12, 0x64, 0x65, 0x62, 0x75, 0x67, 0x67, 0x69, 0x6e, 0x67, 0x53, 0x75, 0x70, 0x70, + 0x6f, 0x72, 0x74, 0x65, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x64, 0x65, 0x62, 0x75, 0x67, 0x5f, 0x66, + 0x71, 0x62, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x64, 0x65, 0x62, 0x75, 0x67, + 0x46, 0x71, 0x62, 0x6e, 0x22, 0xa5, 0x02, 0x0a, 0x15, 0x47, 0x65, 0x74, 0x44, 0x65, 0x62, 0x75, + 0x67, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x40, + 0x0a, 0x08, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x24, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, + 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, + 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x08, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, + 0x12, 0x12, 0x0a, 0x04, 0x66, 0x71, 0x62, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, + 0x66, 0x71, 0x62, 0x6e, 0x12, 0x1f, 0x0a, 0x0b, 0x73, 0x6b, 0x65, 0x74, 0x63, 0x68, 0x5f, 0x70, + 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x6b, 0x65, 0x74, 0x63, + 0x68, 0x50, 0x61, 0x74, 0x68, 0x12, 0x34, 0x0a, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, + 0x2e, 0x63, 0x6c, 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, + 0x2e, 0x50, 0x6f, 0x72, 0x74, 0x52, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x20, 0x0a, 0x0b, 0x69, + 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0b, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x72, 0x65, 0x74, 0x65, 0x72, 0x12, 0x1d, 0x0a, + 0x0a, 0x69, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x5f, 0x64, 0x69, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x09, 0x69, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x44, 0x69, 0x72, 0x12, 0x1e, 0x0a, 0x0a, + 0x70, 0x72, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x6d, 0x65, 0x72, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0a, 0x70, 0x72, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x6d, 0x65, 0x72, 0x22, 0xe4, 0x04, 0x0a, + 0x16, 0x47, 0x65, 0x74, 0x44, 0x65, 0x62, 0x75, 0x67, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x65, 0x78, 0x65, 0x63, 0x75, + 0x74, 0x61, 0x62, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x65, 0x78, 0x65, + 0x63, 0x75, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x6f, 0x6f, 0x6c, 0x63, + 0x68, 0x61, 0x69, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x74, 0x6f, 0x6f, 0x6c, + 0x63, 0x68, 0x61, 0x69, 0x6e, 0x12, 0x25, 0x0a, 0x0e, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, + 0x69, 0x6e, 0x5f, 0x70, 0x61, 0x74, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x74, + 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x50, 0x61, 0x74, 0x68, 0x12, 0x29, 0x0a, 0x10, + 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, + 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, + 0x6e, 0x50, 0x72, 0x65, 0x66, 0x69, 0x78, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x65, 0x72, 0x76, 0x65, + 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x12, + 0x1f, 0x0a, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x5f, 0x70, 0x61, 0x74, 0x68, 0x18, 0x06, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x50, 0x61, 0x74, 0x68, + 0x12, 0x4d, 0x0a, 0x17, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x5f, 0x63, 0x6f, + 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, 0x16, 0x74, 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, + 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, + 0x47, 0x0a, 0x14, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, + 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x14, 0x2e, + 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, + 0x41, 0x6e, 0x79, 0x52, 0x13, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, + 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x6c, 0x0a, 0x0e, 0x63, 0x75, 0x73, 0x74, + 0x6f, 0x6d, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x73, 0x18, 0x09, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x45, 0x2e, 0x63, 0x63, 0x2e, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2e, 0x63, 0x6c, + 0x69, 0x2e, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x44, 0x65, 0x62, 0x75, 0x67, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x43, 0x6f, 0x6e, 0x66, 0x69, + 0x67, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x0d, 0x63, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x43, + 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x73, 0x76, 0x64, 0x5f, 0x66, 0x69, + 0x6c, 0x65, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x76, 0x64, 0x46, 0x69, 0x6c, + 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x72, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x6d, 0x65, 0x72, 0x18, + 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x72, 0x6f, 0x67, 0x72, 0x61, 0x6d, 0x6d, 0x65, + 0x72, 0x1a, 0x40, 0x0a, 0x12, 0x43, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x43, 0x6f, 0x6e, 0x66, 0x69, + 0x67, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, + 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, + 0x02, 0x38, 0x01, 0x22, 0x20, 0x0a, 0x1e, 0x44, 0x65, 0x62, 0x75, 0x67, 0x47, 0x43, 0x43, 0x54, + 0x6f, 0x6f, 0x6c, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x75, 0x72, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x22, 0x70, 0x0a, 0x1f, 0x44, 0x65, 0x62, 0x75, 0x67, 0x4f, 0x70, + 0x65, 0x6e, 0x4f, 0x43, 0x44, 0x53, 0x65, 0x72, 0x76, 0x65, 0x72, 0x43, 0x6f, 0x6e, 0x66, 0x69, + 0x67, 0x75, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, 0x74, 0x68, 0x12, 0x1f, 0x0a, 0x0b, + 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x73, 0x5f, 0x64, 0x69, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0a, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x73, 0x44, 0x69, 0x72, 0x12, 0x18, 0x0a, + 0x07, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x09, 0x52, 0x07, + 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x73, 0x42, 0x48, 0x5a, 0x46, 0x67, 0x69, 0x74, 0x68, 0x75, + 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2f, 0x61, 0x72, + 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2d, 0x63, 0x6c, 0x69, 0x2f, 0x72, 0x70, 0x63, 0x2f, 0x63, 0x63, + 0x2f, 0x61, 0x72, 0x64, 0x75, 0x69, 0x6e, 0x6f, 0x2f, 0x63, 0x6c, 0x69, 0x2f, 0x63, 0x6f, 0x6d, + 0x6d, 0x61, 0x6e, 0x64, 0x73, 0x2f, 0x76, 0x31, 0x3b, 0x63, 0x6f, 0x6d, 0x6d, 0x61, 0x6e, 0x64, + 0x73, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -635,31 +803,35 @@ func file_cc_arduino_cli_commands_v1_debug_proto_rawDescGZIP() []byte { return file_cc_arduino_cli_commands_v1_debug_proto_rawDescData } -var file_cc_arduino_cli_commands_v1_debug_proto_msgTypes = make([]protoimpl.MessageInfo, 7) +var file_cc_arduino_cli_commands_v1_debug_proto_msgTypes = make([]protoimpl.MessageInfo, 9) var file_cc_arduino_cli_commands_v1_debug_proto_goTypes = []interface{}{ (*DebugRequest)(nil), // 0: cc.arduino.cli.commands.v1.DebugRequest - (*GetDebugConfigRequest)(nil), // 1: cc.arduino.cli.commands.v1.GetDebugConfigRequest - (*DebugResponse)(nil), // 2: cc.arduino.cli.commands.v1.DebugResponse - (*GetDebugConfigResponse)(nil), // 3: cc.arduino.cli.commands.v1.GetDebugConfigResponse - (*DebugGCCToolchainConfiguration)(nil), // 4: cc.arduino.cli.commands.v1.DebugGCCToolchainConfiguration - (*DebugOpenOCDServerConfiguration)(nil), // 5: cc.arduino.cli.commands.v1.DebugOpenOCDServerConfiguration - nil, // 6: cc.arduino.cli.commands.v1.GetDebugConfigResponse.CustomConfigsEntry - (*Instance)(nil), // 7: cc.arduino.cli.commands.v1.Instance - (*Port)(nil), // 8: cc.arduino.cli.commands.v1.Port - (*anypb.Any)(nil), // 9: google.protobuf.Any + (*DebugResponse)(nil), // 1: cc.arduino.cli.commands.v1.DebugResponse + (*IsDebugSupportedRequest)(nil), // 2: cc.arduino.cli.commands.v1.IsDebugSupportedRequest + (*IsDebugSupportedResponse)(nil), // 3: cc.arduino.cli.commands.v1.IsDebugSupportedResponse + (*GetDebugConfigRequest)(nil), // 4: cc.arduino.cli.commands.v1.GetDebugConfigRequest + (*GetDebugConfigResponse)(nil), // 5: cc.arduino.cli.commands.v1.GetDebugConfigResponse + (*DebugGCCToolchainConfiguration)(nil), // 6: cc.arduino.cli.commands.v1.DebugGCCToolchainConfiguration + (*DebugOpenOCDServerConfiguration)(nil), // 7: cc.arduino.cli.commands.v1.DebugOpenOCDServerConfiguration + nil, // 8: cc.arduino.cli.commands.v1.GetDebugConfigResponse.CustomConfigsEntry + (*Instance)(nil), // 9: cc.arduino.cli.commands.v1.Instance + (*Port)(nil), // 10: cc.arduino.cli.commands.v1.Port + (*anypb.Any)(nil), // 11: google.protobuf.Any } var file_cc_arduino_cli_commands_v1_debug_proto_depIdxs = []int32{ - 1, // 0: cc.arduino.cli.commands.v1.DebugRequest.debug_request:type_name -> cc.arduino.cli.commands.v1.GetDebugConfigRequest - 7, // 1: cc.arduino.cli.commands.v1.GetDebugConfigRequest.instance:type_name -> cc.arduino.cli.commands.v1.Instance - 8, // 2: cc.arduino.cli.commands.v1.GetDebugConfigRequest.port:type_name -> cc.arduino.cli.commands.v1.Port - 9, // 3: cc.arduino.cli.commands.v1.GetDebugConfigResponse.toolchain_configuration:type_name -> google.protobuf.Any - 9, // 4: cc.arduino.cli.commands.v1.GetDebugConfigResponse.server_configuration:type_name -> google.protobuf.Any - 6, // 5: cc.arduino.cli.commands.v1.GetDebugConfigResponse.custom_configs:type_name -> cc.arduino.cli.commands.v1.GetDebugConfigResponse.CustomConfigsEntry - 6, // [6:6] is the sub-list for method output_type - 6, // [6:6] is the sub-list for method input_type - 6, // [6:6] is the sub-list for extension type_name - 6, // [6:6] is the sub-list for extension extendee - 0, // [0:6] is the sub-list for field type_name + 4, // 0: cc.arduino.cli.commands.v1.DebugRequest.debug_request:type_name -> cc.arduino.cli.commands.v1.GetDebugConfigRequest + 9, // 1: cc.arduino.cli.commands.v1.IsDebugSupportedRequest.instance:type_name -> cc.arduino.cli.commands.v1.Instance + 10, // 2: cc.arduino.cli.commands.v1.IsDebugSupportedRequest.port:type_name -> cc.arduino.cli.commands.v1.Port + 9, // 3: cc.arduino.cli.commands.v1.GetDebugConfigRequest.instance:type_name -> cc.arduino.cli.commands.v1.Instance + 10, // 4: cc.arduino.cli.commands.v1.GetDebugConfigRequest.port:type_name -> cc.arduino.cli.commands.v1.Port + 11, // 5: cc.arduino.cli.commands.v1.GetDebugConfigResponse.toolchain_configuration:type_name -> google.protobuf.Any + 11, // 6: cc.arduino.cli.commands.v1.GetDebugConfigResponse.server_configuration:type_name -> google.protobuf.Any + 8, // 7: cc.arduino.cli.commands.v1.GetDebugConfigResponse.custom_configs:type_name -> cc.arduino.cli.commands.v1.GetDebugConfigResponse.CustomConfigsEntry + 8, // [8:8] is the sub-list for method output_type + 8, // [8:8] is the sub-list for method input_type + 8, // [8:8] is the sub-list for extension type_name + 8, // [8:8] is the sub-list for extension extendee + 0, // [0:8] is the sub-list for field type_name } func init() { file_cc_arduino_cli_commands_v1_debug_proto_init() } @@ -683,7 +855,7 @@ func file_cc_arduino_cli_commands_v1_debug_proto_init() { } } file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetDebugConfigRequest); i { + switch v := v.(*DebugResponse); i { case 0: return &v.state case 1: @@ -695,7 +867,7 @@ func file_cc_arduino_cli_commands_v1_debug_proto_init() { } } file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DebugResponse); i { + switch v := v.(*IsDebugSupportedRequest); i { case 0: return &v.state case 1: @@ -707,7 +879,7 @@ func file_cc_arduino_cli_commands_v1_debug_proto_init() { } } file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetDebugConfigResponse); i { + switch v := v.(*IsDebugSupportedResponse); i { case 0: return &v.state case 1: @@ -719,7 +891,7 @@ func file_cc_arduino_cli_commands_v1_debug_proto_init() { } } file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*DebugGCCToolchainConfiguration); i { + switch v := v.(*GetDebugConfigRequest); i { case 0: return &v.state case 1: @@ -731,6 +903,30 @@ func file_cc_arduino_cli_commands_v1_debug_proto_init() { } } file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GetDebugConfigResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*DebugGCCToolchainConfiguration); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_cc_arduino_cli_commands_v1_debug_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*DebugOpenOCDServerConfiguration); i { case 0: return &v.state @@ -749,7 +945,7 @@ func file_cc_arduino_cli_commands_v1_debug_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_cc_arduino_cli_commands_v1_debug_proto_rawDesc, NumEnums: 0, - NumMessages: 7, + NumMessages: 9, NumExtensions: 0, NumServices: 0, }, diff --git a/rpc/cc/arduino/cli/commands/v1/debug.proto b/rpc/cc/arduino/cli/commands/v1/debug.proto index 9e8341edb54..25142875d38 100644 --- a/rpc/cc/arduino/cli/commands/v1/debug.proto +++ b/rpc/cc/arduino/cli/commands/v1/debug.proto @@ -43,6 +43,39 @@ message DebugRequest { bool send_interrupt = 3; } +// The streaming response may contain chunks of data from the debugger or an +// error. +message DebugResponse { + // Incoming data from the debugger tool. + bytes data = 1; + // Incoming error output from the debugger tool. + string error = 2; +} + +message IsDebugSupportedRequest { + // Arduino Core Service instance from the `Init` response. + Instance instance = 1; + // Fully qualified board name of the board in use (e.g., + // `arduino:samd:mkr1000`). + string fqbn = 2; + // Port of the debugger (optional). + Port port = 3; + // Which GDB command interpreter to use. + string interpreter = 4; + // The programmer to use for debugging. + string programmer = 5; +} + +message IsDebugSupportedResponse { + // True if debugging is supported + bool debugging_supported = 1; + // This is the same FQBN given in the IsDebugSupportedRequest but cleaned + // up of the board options that do not affect the debugger configuration. + // It may be used by clients/IDE to group slightly different boards option + // selections under the same debug configuration. + string debug_fqbn = 2; +} + message GetDebugConfigRequest { // Arduino Core Service instance from the `Init` response. Instance instance = 1; @@ -65,14 +98,6 @@ message GetDebugConfigRequest { string programmer = 9; } -// -message DebugResponse { - // Incoming data from the debugger tool. - bytes data = 1; - // Incoming error output from the debugger tool. - string error = 2; -} - message GetDebugConfigResponse { // The executable binary to debug string executable = 1;