# Problems w/ run\_debug, run\_openocd, run\_gdb make targets w/ E300 Arty

**URL:** <https://forums.sifive.com/t/problems-w-run-debug-run-openocd-run-gdb-make-targets-w-e300-arty/332>\
**Category:** Freedom E300\
**Created:** [February 9, 2017, 4:26pm UTC](https://forums.sifive.com/t/problems-w-run-debug-run-openocd-run-gdb-make-targets-w-e300-arty/332 "2017-02-09T16:26:23Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![pkeating](https://avatars.discourse-cdn.com/v4/letter/p/ec9cab/32.png) [@pkeating](https://forums.sifive.com/u/pkeating)\
**Post date:** [February 9, 2017, 4:26pm UTC](https://forums.sifive.com/t/problems-w-run-debug-run-openocd-run-gdb-make-targets-w-e300-arty/332/1 "2017-02-09T16:26:23Z")

</div>

I’m having issues getting openocd to do anything more than upload and run images on my Arty E300 board. The ‘make upload’ target executes successfully, but when I try ‘make run\_debug’ using the same program image, gdb starts but the image exists with 0x0000003 as the exist code after a ‘unhandled trap’ message.  
'make run\_openocd appears to hang after loading the image.  
‘make run\_gdb’ starts gdb running, but none of the gdb commands seem to work correctly (eg, ‘run’ at the gdb prompt generates a ‘don’t know how to run. Try “help target”’ message.  
None of the gdb commands seems to do much of anything at that point. It’s been a while since I’ve needed to use gdb, so there’s a definite chance of pilot error here; any ideas, comments, etc. would be appreciated.

---

<div class="post-metadata">

**Author:** ![mwachs5](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.sifive.com/mwachs5/32/13_2.png) [@mwachs5](https://forums.sifive.com/u/mwachs5)\
**Post date:** [February 9, 2017, 4:34pm UTC](https://forums.sifive.com/t/problems-w-run-debug-run-openocd-run-gdb-make-targets-w-e300-arty/332/2 "2017-02-09T16:34:27Z")

</div>

Hey Phil, sorry for the confusion.

I personally prefer to run the `make run_openocd` and `run_gdb` targets separately, the “run\_debug” target doesn’t work if you want to halt. So let’s ignore `run_debug` for now.

You will need two terminal windows.

In one, just run `make run_openocd`. Then just leave it there. All this has done is launch the OpenOCD process, which talks to the HiFive1 board and halts the running code.

In the other window, run `make run_gdb PROGRAM=demo_gpio` (for example). This launches the GDB process, but you need to actually get it talking to the openOCD process:

`gdb > target extended-remote localhost:3333`

Once you do that, you’ll be able to run the usual suite of GDB commands.

(Yes, we should document the magical incantation above better).

---

<div class="post-metadata">

**Author:** ![brucehoult](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.sifive.com/brucehoult/32/24_2.png) [@brucehoult](https://forums.sifive.com/u/brucehoult)\
**Post date:** [February 9, 2017, 4:57pm UTC](https://forums.sifive.com/t/problems-w-run-debug-run-openocd-run-gdb-make-targets-w-e300-arty/332/3 "2017-02-09T16:57:25Z")

</div>

Everything is the same for the HiFive1? I didn’t try gdb at all yet.

Also: was was wondering about getting an Arty as well. The info says that it comes with a Vivado license and 12 months of updates and support. What happens after that? What does it cost for another year? Can you not pay the next year and keep using the same software without updates?

---

<div class="post-metadata">

**Author:** ![mwachs5](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.sifive.com/mwachs5/32/13_2.png) [@mwachs5](https://forums.sifive.com/u/mwachs5)\
**Post date:** [February 9, 2017, 9:24pm UTC](https://forums.sifive.com/t/problems-w-run-debug-run-openocd-run-gdb-make-targets-w-e300-arty/332/4 "2017-02-09T21:24:05Z")

</div>

Those instructions were geared for HiFive1, for Arty you also need to specifiy `BOARD=freedom-e300-arty`.

The license provided with the board is for Vivado DesignSuite. I’m not sure what happens after a year. The included license is device-locked to the Artix 35-T (the FPGA on the board).

However, Xilinx also provides a free license for ISE WebPack (regardless of whether you bought something), which according the their website, is enough to work with the Arty’s FPGA. I haven’t personally tried it out.

---

<div class="post-metadata">

**Author:** ![dagema](https://sea2.discourse-cdn.com/flex020/user_avatar/forums.sifive.com/dagema/32/59_2.png) [@dagema](https://forums.sifive.com/u/dagema)\
**Post date:** [February 9, 2017, 10:12pm UTC](https://forums.sifive.com/t/problems-w-run-debug-run-openocd-run-gdb-make-targets-w-e300-arty/332/5 "2017-02-09T22:12:42Z")

</div>

My understanding is that after 1 year, you may continue using Vivado, you just do not receive any further updates. In addition, license vouchers are available from Digilent for $10.
