Before logging an issue, please update to the latest release of Visual Micro from the Downloads Page.

When Logging a Support Issue in the Forum, please ensure you have also:-

  • Enabled vMicro > Compiler > Show Build Properties
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Missing openocd config (Read 3180 times)
Habib
Newbies
*
Offline


Posts: 2
Joined: May 10th, 2020
Missing openocd config
May 10th, 2020 at 7:51am
Print Post  
I'm trying to debug an Adafruit ItstyBitsy M4 with a J-link mini.  When I try to "Attach to process..." vMicro runs this command:

Starting: "C:\ProgramData\vmicro\tools\openocd-0.10.0.20200213\bin/openocd.exe" -d2 -l m4\Debug/Blink1.ino_DebugOpenOCD.log}" -s "C:\ProgramData\vmicro\tools\openocd-0.10.0.20200213/scripts/" -f "interface/jlink.cfg" -c "transport select swd" -f ariants/itsybitsy_m4/openocd_scripts/arduino_zero.cfg" -c "init"

It exits with code 1.  Checking the log file I find:

embedded:startup.tcl:26: Error: Can't find riants/itsybitsy_m4/openocd_scripts/arduino_zero.cfg
in procedure 'script' 
at file "embedded:startup.tcl", line 26


When I check under the itsybitsy_m4 directory there isn't any openocd_scripts directory at all.  I'm not sure why these files are missing and I'm not sure how to fix this issue.

Any advice?
  
Back to top
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline


Posts: 2145
Joined: Feb 13th, 2019
Re: Missing openocd config
Reply #1 - May 11th, 2020 at 9:26am
Print Post  
Thanks for the detailed report and information.

The files are only there for boards where the GDB debugging has been integrated into the board package for Arduino.  Looking at the board it uses the ATSAMD51 Cortex M4 Processor, which is listed in our OpenOCD configuration in the atsame5x file...

If you right click on the project in Solution Explorer > Add > Local Board.txt, add below line, save. Then try re-attaching the target again
Code
Select All
tools.jlink.server.targetCmd=-c "transport select swd" -f "target/atsame5x.cfg" 



Let us know if this resolves the issue or if there are still problems.

We can add this to the pre-configured elements in Visual Micro once working to save doing this in the future.
  
Back to top
 
IP Logged
 
Habib
Newbies
*
Offline


Posts: 2
Joined: May 10th, 2020
Re: Missing openocd config
Reply #2 - May 12th, 2020 at 5:38am
Print Post  
Thank you, that seems to have corrected the problem for debugging.  I'm still having the same issue when trying to upload via the j-link.  Is there a different config to update that as well?
  
Back to top
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline


Posts: 2145
Joined: Feb 13th, 2019
Re: Missing openocd config
Reply #3 - May 12th, 2020 at 9:27am
Print Post  
Brilliant, and yes there is the below addition for the program upload. (Debugging is always the safest place to start)

Code
Select All
tools.jlink.program.targetCmd=-c "transport select swd"  -f "target/atsame5x.cfg" 

  
Back to top
 
IP Logged
 
Simon@Visual Micro
Administrator
*****
Offline


Posts: 2145
Joined: Feb 13th, 2019
Re: Missing openocd config
Reply #4 - Sep 15th, 2020 at 8:41am
Print Post  
Off-Topic replies have been moved to this Topic.
  
Back to top
 
IP Logged
 
Kabron
Full Member
***
Offline


Posts: 170
Joined: Nov 1st, 2015
Re: Missing openocd config
Reply #5 - Sep 15th, 2020 at 11:29am
Print Post  
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint