user-1: I want to do on-chip-debugging on an Arduino Mega.
According to its datasheet, the ATmega2560 chip supports JTAG. (IEEE 1149.1 compliant)
Can I use a generic FT2232H interface to do on-chip-debugging on this?
How would a OpenOCD config file look like for this purpose?
Thanks in advance!

user42539: The chip seems to support it:

Multi-Protocol Synchronous Serial Engine (MPSSE) to simplify synchronous serial protocol (USB to JTAG, I2C, SPI or bit-bang) design.  

You'll have to play with the drivers,
and check to see that Arduino brought all the JTAG pins out to header pins.

-1: <p>I want to do on-chip-debugging on an <a href="https://store.arduino.cc/arduino-mega-2560-rev3" rel="nofollow noreferrer">Arduino Mega</a>.
According to its <a href="http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-2549-8-bit-AVR-Microcontroller-ATmega640-1280-1281-2560-2561_datasheet.pdf" rel="nofollow noreferrer">datasheet</a>, the ATmega2560 chip supports JTAG. (IEEE 1149.1 compliant)</p>

<p>Can I use a generic FT2232H interface to do on-chip-debugging on this?</p>

<p>How would a OpenOCD config file look like for this purpose?</p>

<p>Thanks in advance!</p>
 42539: <p>The <a href="http://www.ftdichip.com/Products/ICs/FT232H.htm" rel="nofollow noreferrer">chip</a> seems to support it:</p>

<blockquote>
  <p>Multi-Protocol Synchronous Serial Engine (MPSSE) to simplify synchronous serial protocol (USB to JTAG, I2C, SPI or bit-bang) design.  </p>
</blockquote>

<p>You'll have to play with the drivers,<br>
and check to see that Arduino brought all the JTAG pins out to header pins.</p>
