# OpenOCD (Win7) and the Photon Programmer Shield

**URL:** <https://community.particle.io/t/openocd-win7-and-the-photon-programmer-shield/14842>\
**Category:** Firmware\
**Created:** [August 28, 2015, 6:27pm UTC](https://community.particle.io/t/openocd-win7-and-the-photon-programmer-shield/14842 "2015-08-28T18:27:21Z")\
**Posts on this page:** 6\
**Page:** 2

<div class="post-metadata">

**Author:** ![k2tom](https://avatars.discourse-cdn.com/v4/letter/k/b9e5f3/32.png) [@k2tom](https://community.particle.io/u/k2tom)\
**Post date:** [September 2, 2015, 3:03pm UTC](https://community.particle.io/t/openocd-win7-and-the-photon-programmer-shield/14842/22 "2015-09-02T15:03:35Z")

</div>

@jvanier,

Thanks! I finally got things going with OpenOCD following your advice. The only minor probelm I ran into is that in Zadig, I had to select Options \> List\_All\_Devices before the Particle\_FT2232 (Interface\_#) would show up in the drop-down. Also, I loaded the WinUSB driver and everything seems okay. I’m able to read/erase/write flash.

Thanks 1e6.

Tom

---

<div class="post-metadata">

**Author:** ![peekay123](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/peekay123/32/810_2.png) [@peekay123](https://community.particle.io/u/peekay123)\
**Post date:** [September 2, 2015, 3:30pm UTC](https://community.particle.io/t/openocd-win7-and-the-photon-programmer-shield/14842/23 "2015-09-02T15:30:00Z")

</div>

@jvanier, thanks for your instructions! Everything is working except that I had to change to gdb port 4444. 😄

---

<div class="post-metadata">

**Author:** ![jvanier](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/jvanier/32/5542_2.png) [@jvanier](https://community.particle.io/u/jvanier)\
**Post date:** [September 2, 2015, 3:55pm UTC](https://community.particle.io/t/openocd-win7-and-the-photon-programmer-shield/14842/24 "2015-09-02T15:55:32Z")

</div>

Welcome!

> [@peekay123](#):
>
> I had to change to gdb port 4444

I'm curious about this comment.

OpenOCD opens port 4444 for its own remote protocol that you can access through telnet, and if you pass `openocd -c "gdb_port 3333"` it will open port 3333 for the gdb remote protocol.

You'd connect with telnet or PuTTY to port 4444 to send commands to OpenOCD like erase, flash, etc.

You'd connect with GDB to port 3333 with `arm-none-eabi-gdb -ex "target remote localhost:3333"`

Why did you change the GDB port to 4444? Was it in the openocd command line or the gdb command line? Didn't it conflict with the OpenOCD remote interface?

---

<div class="post-metadata">

**Author:** ![peekay123](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/peekay123/32/810_2.png) [@peekay123](https://community.particle.io/u/peekay123)\
**Post date:** [September 2, 2015, 4:08pm UTC](https://community.particle.io/t/openocd-win7-and-the-photon-programmer-shield/14842/25 "2015-09-02T16:08:17Z")

</div>

@jvanier, actually now that you mention it, I tried to connect with telnet via port 3333 and it failed - of course! SO, no need for change, just more intelligence on this user’s side 😳

---

<div class="post-metadata">

**Author:** ![ScruffR](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/scruffr/32/6952_2.png) [@ScruffR](https://community.particle.io/u/ScruffR)\
**Post date:** [January 10, 2016, 3:15pm UTC](https://community.particle.io/t/openocd-win7-and-the-photon-programmer-shield/14842/26 "2016-01-10T15:15:26Z")

</div>

@jvanier, thanks for your tutorial, it worked just as you said without any problems 👍

I’m just curious why you suggest to copy `stm32f3x.cfg` and not `stm32f2x.cfg` to `bin-x64`.  
When opening OpenOCD you’re referencing the `stm32f2x.cfg` (I just copied both into the dir)

---

<div class="post-metadata">

**Author:** ![jvanier](https://sea2.discourse-cdn.com/flex026/user_avatar/community.particle.io/jvanier/32/5542_2.png) [@jvanier](https://community.particle.io/u/jvanier)\
**Post date:** [January 10, 2016, 4:03pm UTC](https://community.particle.io/t/openocd-win7-and-the-photon-programmer-shield/14842/27 "2016-01-10T16:03:56Z")

</div>

> [@ScruffR](#):
>
> I'm just curious why you suggest to copy stm32f3x.cfg

'Tis but a typo. Thanks for pointing it out! I fixed it.

[Previous page](https://community.particle.io/t/openocd-win7-and-the-photon-programmer-shield/14842.md?page=1)
