I know I can test a release version in the sim with the -r option in the compiler, but is there a compile option to deploy a debug version of a watch app to a device, for alpha testing?
I haven't found the spec for the compiler options.
I know I can test a release version in the sim with the -r option in the compiler, but is there a compile option to deploy a debug version of a watch app to a device, for alpha testing?
I haven't found the spec for the compiler options.
is there a compile option to deploy a debug version of a watch app to a device, for alpha testing?
[Open Command Palette - CTRL/CMD-SHIFT-P] > Monkey C: Build For Device > [Select Output…
Yes, of course. Thanks. (Back into dev after a bit of a break!)
When you use build for device, and build a debug version, you'll see the prg is much larger than if you build a release version. That's because the stuff in the xml is in the debug build. You just…
is there a compile option to deploy a debug version of a watch app to a device, for alpha testing?
[Open Command Palette - CTRL/CMD-SHIFT-P] > Monkey C: Build For Device > [Select Output Folder] > Debug
As far as I can tell, the "Build For Device" command was intended for building sideloads, based on the fact that it asks you to select between Release or Debug versions (and the fact that it asks for you an output folder.) (In contrast, "Build Current Project" seems tailor-made for building the app to run in the sim)
I know I can test a release version in the sim with the -r option in the compiler
It seems that the absence of the "-r" (release) option tells the compiler to build the debug version, at least based on the difference between the command lines for "Build For Device > Debug" and "Build For Device > Release".
I haven't found the spec for the compiler options
To see all the compiler options, you can either (temporarily) change your VS Code Monkey C extension settings to add the -h option to the compiler options, or run monkeyc directly from the terminal with -h.
On Mac (Terminal):
"$(cat ~"/Library/Application Support/Garmin/ConnectIQ/current-sdk.cfg")"/bin/monkeyc -h
usage: monkeyc [-a <arg>] [-b <arg>] [--build-stats <arg>] [-c <arg>] [-d <arg>]
[--debug-log-level <arg>] [--debug-log-output <arg>] [-e]
[--Eno-invalid-symbol] [-f <arg>] [-g] [-h] [-i <arg>] [-k] [-l <arg>]
[-m <arg>] [--no-gen-styles] [-o <arg>] [-O <arg>] [-p <arg>] [-r] [-s
<arg>] [-t] [-u <arg>] [-v] [-w] [-x <arg>] [-y <arg>] [-z <arg>]
-a,--apidb <arg> API import file
-b,--apimir <arg> API MIR file
--build-stats <arg> Print build stats [0=basic]
-c,--api-level <arg> API Level to target
-d,--device <arg> Target device
--debug-log-level <arg> Debug logging verbosity [0=errors, 1=basic,
2=intermediate, 3=verbose]
--debug-log-output <arg>Output log zip file
-e,--package-app Create an application package.
--Eno-invalid-symbol Do not error when a symbol is found to be invalid
-f,--jungles <arg> Jungle files
-g,--debug Print debug output
-h,--help Prints help information
-i,--import-dbg <arg> Import api.debug.xml
-k,--profile Enable profiling support
-l,--typecheck <arg> Type check [0=off, 1=gradual, 2=informative,
3=strict]
-m,--manifest <arg> Manifest file (deprecated)
--no-gen-styles Do not generate Rez.Styles module
-o,--output <arg> Output file to create
-O,--optimization <arg> Optimization level [0=none, 1=basic, 2=fast
optimizations, 3=slow optimizations] [p=optimize
performance, z=optimize code space]
-p,--project-info <arg> projectInfo.xml file to use when compiling
-r,--release Strip debug information
-s,--sdk-version <arg> SDK version to target (deprecated, use -c
-t,--unit-test Enables compilation of unit tests
-u,--devices <arg> devices.xml file to use when compiling (deprecated)
-v,--version Prints the compiler version
-w,--warn Show compiler warnings
-x,--excludes <arg> Add annotations to the exclude list (deprecated)
-y,--private-key <arg> Private key to sign builds with
$(cat ~"/Library/Application Support/Garmin/ConnectIQ/current-sdk.cfg")"/bin/monkeyc -v
Connect IQ Compiler version: 6.2.1
Yes, of course. Thanks. (Back into dev after a bit of a break!)
One question about this: when side-loading a debug build, am I supposed to also copy the evcc.prg.debug.xml file onto the device?
When you use build for device, and build a debug version, you'll see the prg is much larger than if you build a release version. That's because the stuff in the xml is in the debug build. You just need to copy over the prg and not the xml for a sideload.
With a debug build you'll see a friendly stack trace in ciq_log. With a release build, you use the xml to understand the stack trace in ciq_log
Thanks!