Open haata opened 9 years ago
Thanks for your submission. I've been heavily restructuring the code (see the cmsis-dap branch). I'll try to add the same behavior to the new code.
I believe that I have seen JLink adapters mass-erasing the target without me holding down reset, but they might have just used the reset line.
Cool, looking forward to the re-factor.
I had a lot of flashing issues with the mk20dx256vlh7 (had to put series resistors on the SWD CLK and IO lines to get it to work). Caused me to inadvertently secure the chip often. Ended up buying a jlink adapter to attempt to unlock. It requires the Reset pin attached to it.
Good to know. I've been working on dedicated programming hardware (with SWD series resistors). Maybe I can get you interested in getting some for your next project :)
Neat! Also, I make sure that the CLK and IO trace lengths are matched (just in case).
I've been trying to standardize on the J-Link needle connector (TC2050-IDC) because it'll do both SWD and JTAG if I need it. Unfortunately Segger flashers are too expensive (I have one, but it's not reasonable to expect everyone to have one, or buying a bunch for the factory). For the bus pirate we just have an adapter to break out the SWD, GND and +5 V.
At minimum I just need SWD (and ideally RESET line control) Another interesting feature the jlink's have is a power level check. Basically, after you tell it to apply 5 V supply, it measures VTref to make sure you're at the correct voltage before attempting anything (i.e. 3.3V). Not really required, but helps debug soldering issues.
(Got 2000+ chips to flash for the Infinity ErgoDox)
Some background:
(It would be nice to actually control the reset line with the bus pirate, similar to a jlink flasher but I'm not familiar enough with ruby/bus pirate to do that right now)