Commit Graph

4 Commits

Author SHA1 Message Date
Hans
a245cd5370 Use -xmode to switch PICkit4 and SNAP application modes (#1596)
* Use libusb to switch a PICkit4 or SNAP to AVR mode

* Fix case

* implement -xmode=pic
Thanks Wireshark

* Print PIC switch info messages

* Fix typo

* Rename SNAP and PICkit4 USB PID

* Make it possible to enter avr mode even when the tool is in bootloader/recovery mode

* Add -xmode to docs

* Tweak grammar

* Add -xmode support for pickit4_isp and snap_isp
still need to figure out how to actually trigger the mode switch form stk500v2.c

* Don't print "unable to open port" error on pgm->open softfail

* Add const

* Simplify SNAP/PICkit4 mode switching code

* Formatting

* Add extra argument to jtag3_open_common
This makes it possible to switch SNAP/PK4 modes from stk500v2.c as well, using pickit4_isp and snap_isp

* Improve extended parameter parsing

* Improve error message

* Improve extended parameter parsing

* Immediately exit after a mode switch

* Remove unnecessary line

* Add missing serial_close

* Remove unnecessary else

* Minor code tweaks

* Update docs

* Formatting

* Improve external parameter parsing and error handling

* Remove unused parameter
2024-01-04 02:02:24 +13:00
MCUdude
30e90bdfd2 Add alternative USB PID for PICkit4/SNAP in PIC mode 2022-12-14 20:11:43 +01:00
MCUdude
13817459e1 Add missing USB VID/PIDs 2022-10-20 12:19:10 +02:00
Marius Greuel
5633a6d88a Move source files to 'src' folder 2021-12-17 09:17:42 +01:00