Skip to main content
Topic: Proposed changes to the OpenOCD driver (Read 3229 times) previous topic - next topic

Proposed changes to the OpenOCD driver

Hi all:

I made the following changes to the OpenOCD side, please see the attached source file:

- Discard any stale data from the previous connection.
  This change was discussed here before.
- Disable CR/LF translation.
  I was getting some trouble, see my previous message in this forum.
- Increase the average USB packet size.
  The 1 KiB buffer was underutilized.
  I am getting now better performance with the Arduino Due.
- Option "buspirate_speed fast" now works out of the box.
  I am getting 8 KiB/s transfer with GDB's 'load' command, instead of just 1 KiB/s.
- Some extra comments, error checking, etc.

I wanted to submit a patch to the OpenOCD project, I am using the git head at the moment.

Can somebody review or test the new driver version? I only have a Bus Pirate v3.5 (USB) to test it against.

Thanks,
  rdiez

Re: Proposed changes to the OpenOCD driver

Reply #1
You need to learn how to use git diff (to produce patches), and git format patch (to produce formated patches).... Yet better, learn how to submit code directly to openocd tracking system. (its not that hard and you get proper credit)

Just be sure that the code does not break anything.

Re: Proposed changes to the OpenOCD driver

Reply #2
I thought it would be easier for you guys to git clone the OpenOCD repository and just overwrite the file, you can then view the diff locally.

In order to build and run it, you need to clone the repo anyway, I've seen people here doing it so as to manually add the previously-suggested delay for "buspirate_speed fast" to work. A single diff does not give you enough context to review it properly anyhow.

I really hope somebody can test it, because saying "Just be sure that the code does not break anything" does not really help!