CIQ Stack Tracer
Resolve Connect IQ device crash stacks directly in VS Code. The extension maps pc addresses from device logs to the function, source file, and line number recorded in the compiled debug.xml, then lets you navigate to the source.
Features
Automatically finds *.debug.xml files below the current workspace's bin directory.
Recognizes stack-frame addresses in .yml and .yaml files, for example - pc: 0x100001fb.
Displays an italic result after each address:
onUpdate() as source\TestWatchfaceView.mc:45
Maps absolute source paths from the build machine back into the current workspace.
Navigate from an address to its source line with F12 or the modifier-click configured in VS Code.
Provides CIQ Stack Tracer: Resolve Current Stack Frame in the Command Palette and editor context menu.
Usage
Open the Connect IQ project root in VS Code.
Build the project and make sure its debug file is below the project's bin directory, for example:
bin\TestWatchface.prg.debug.xml
Open a device crash log with a .yml or .yaml extension.
Function and source-location details are displayed after every pc address under Stack.
Place the cursor on an address and press F12 to navigate, or run CIQ Stack Tracer: Resolve Current Stack Frame.
For mouse navigation, hold Ctrl and click the address by default. If editor.multiCursorModifier is set to ctrlCmd, use Alt instead.
Resolution Rules
The extension reads pcToLineNum entries from debug.xml and chooses the closest mapping whose PC address is less than or equal to the address in the log. The log and debug.xml must come from the same build; addresses from a different build commonly cannot be resolved correctly.
Displayed paths are relative to the current workspace root and use Windows \ separators. For example, this path recorded in debug.xml:
C:\ciq_development\TestWatchface\source\TestWatchfaceView.mc
is displayed as:
source\TestWatchfaceView.mc
Resolution Messages
no debug.xml under bin/: no debug XML was found below the workspace's bin directory.
no mapping for 0x...: a debug XML was found, but it has no matching PC mapping. This usually means the log and build artifacts do not match.
- A function and location are displayed but navigation fails: the source file is not in the current workspace, or the source path in the XML cannot be mapped back to the project.
Local Development
Install dependencies and compile the extension:
npm install
npm run compile
Press F5 in VS Code to start an Extension Development Host for testing. After rebuilding the extension, restart that development-host window to load the new version.