Author Topic: Affordable JTAG debugger for iMX SoCs?  (Read 1413 times)

0 Members and 1 Guest are viewing this topic.

Offline asmiTopic starter

  • Super Contributor
  • ***
  • Posts: 2733
  • Country: ca
Affordable JTAG debugger for iMX SoCs?
« on: October 18, 2023, 04:19:37 pm »
I have a project coming up which is going to involve an iMX SoC (probably 6, but not sure yet). I never had to deal with them before, and looking at the market, the only JTAG debuggers I found are Segger J-Link and some Olimex one, both are well north of 500$, which is frankly ridiculous in this day and age, especially since the abovementioned project is going to be non-commercial so I can't just include this cost into the contract and call it a day, like I usually do for commercial ones. I know there are folks over here who work with those devices, so please let me know if there are any affordable options for debugging these things.

Offline girishji

  • Contributor
  • Posts: 42
  • Country: pl
    • girish
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #1 on: October 18, 2023, 10:06:50 pm »
There is Segger Edu Mini if it works for you. It retails for ~25USD. I got mine from pihut since I am in Europe.
 

Offline asmiTopic starter

  • Super Contributor
  • ***
  • Posts: 2733
  • Country: ca
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #2 on: October 18, 2023, 10:28:44 pm »
There is Segger Edu Mini if it works for you.
It's been almost two decades since I've been a student, so I don't think that option would work for me, but thanks for response anyway!

Offline Smokey

  • Super Contributor
  • ***
  • Posts: 2597
  • Country: us
  • Not An Expert
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #3 on: October 18, 2023, 10:40:53 pm »
There is Segger Edu Mini if it works for you.
It's been almost two decades since I've been a student, so I don't think that option would work for me, but thanks for response anyway!

We are all lifelong students, really.... :)
It's actually a fully featured unit.  It just nags you once a day to make sure you really really promise not to use it for commercial purposes...
« Last Edit: October 19, 2023, 04:22:30 am by Smokey »
 

Offline asmiTopic starter

  • Super Contributor
  • ***
  • Posts: 2733
  • Country: ca
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #4 on: October 18, 2023, 10:43:06 pm »
We are all lifelong students, really.... :)
Apparently not as far as the vendor is concerned :(

It's actually a fully featured unit.  It just nags you once a day to make sure you are really really promise not to use it for commercial purposes...
That's good to know, since this project is non-commercial, I think I can live with that.

Online nctnico

  • Super Contributor
  • ***
  • Posts: 26910
  • Country: nl
    • NCT Developments
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #5 on: October 18, 2023, 10:56:32 pm »
I'm wondering why you'd need a debugger. Unless you are going to program the SoC bare metal. I've done quite a few projects with various members of the iMX series SoCs and never needed a JTAG debugger. Up to the point that I don't even bother bringing the JTAG pins out in my designs. U-boot and the Linux kernel provided by NXP just work (and the kernel can be debugged over the serial port if you want to).

It looks like OpenOCD has support for the various iMX SoCs and thus a wide variety of JTAG dongles should work but you'll need an initialisation sequence to get the DDR memory and some clocks going. The page seems to have some useful pointers: https://fatalfeel.blogspot.com/2015/12/openocd-with-eclipse-debug-kernel-of.html
« Last Edit: October 18, 2023, 11:20:23 pm by nctnico »
There are small lies, big lies and then there is what is on the screen of your oscilloscope.
 

Offline Smokey

  • Super Contributor
  • ***
  • Posts: 2597
  • Country: us
  • Not An Expert
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #6 on: October 18, 2023, 11:32:17 pm »
Make sure whatever IDE you are using is compatible with whatever debugger you are using. 
 

Offline SiliconWizard

  • Super Contributor
  • ***
  • Posts: 14490
  • Country: fr
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #7 on: October 18, 2023, 11:33:56 pm »
If you manage to set up OpenOCD, then you have in turn support for remote gdb.
 

Offline asmiTopic starter

  • Super Contributor
  • ***
  • Posts: 2733
  • Country: ca
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #8 on: October 19, 2023, 12:00:44 am »
I'm wondering why you'd need a debugger. Unless you are going to program the SoC bare metal. I've done quite a few projects with various members of the iMX series SoCs and never needed a JTAG debugger. Up to the point that I don't even bother bringing the JTAG pins out in my designs. U-boot and the Linux kernel provided by NXP just work (and the kernel can be debugged over the serial port if you want to).
Whenever I begin to work with the new SoC or FPGA, I always design a dev board first for myself, so for it I would like to keep as many options open as possible, which includes JTAG. Besides, since iMX support RTOSes as well as Linux, I see no problems with developing a bare-metal or almost-bare-metal code (the latter is what RTOS essentially is).

Offline mwb1100

  • Frequent Contributor
  • **
  • Posts: 529
  • Country: us
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #9 on: October 19, 2023, 01:47:20 am »
This article explains someone's experience debugging Linux running on an iMX6 with an Olimex ARM-USB-OCD-H JTAG debugger:

  - Debugging Linux Kernel on i.MX6 with JTAG and Visual Studio

The Olimex ARM-USB-OCD-H is 55 EUR and uses OpenOCD.

Here's an article explaining how to use The BusBlaster JTAG debugger ($35) with OpenOCD on an iMX6solo to debug u-boot:

  - Inexpensive JTAG on the imx6 solo: U-Boot Launch and Debug

I have never used any of the tools mentioned, so be sure to perform due diligence.
 

Offline girishji

  • Contributor
  • Posts: 42
  • Country: pl
    • girish
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #10 on: October 19, 2023, 06:51:49 am »
If you end up using -segger edu mini- and developing your own dev board, the one useful feature it lacks is a 5v pin to power the target. You have to power your MCU independent of segger device.
 

Offline tellurium

  • Regular Contributor
  • *
  • Posts: 232
  • Country: ua
Re: Affordable JTAG debugger for iMX SoCs?
« Reply #11 on: October 19, 2023, 10:00:27 am »
A black magic probe might suit: https://black-magic.org/

They make and sell their own probe, which costs about 70EUR, https://www.adafruit.com/product/3839

Their software, however, could be built and flashed to a various of 3rd party devices, e.g. STM32 BlackPill, STM32 Mini F401 (https://stm32-base.org/boards/STM32F401CCU6-STM32-Mini-F401) - those you can get on Ali for a couple of bucks.

I am not affiliated with that project, but I think it is great.
Open source embedded network library https://mongoose.ws
TCP/IP stack + TLS1.3 + HTTP/WebSocket/MQTT in a single file
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf