serprog: Add SPI Mode and CS Mode commands

This commit adds two new commands to the serprog protocol which allow
more fine grained control over the SPI bus. This enables more
applications over serprog like e.g. flashing AVR microcontrollers.
This can be tried with my forks of pico-serprog:

https://github.com/funkeleinhorn/pico-serprog/tree/spimode

and avrdude:

https://github.com/funkeleinhorn/avrgirl/tree/serprog-programmer

I announced this change in flashrom and flashprog IRC channels and got
overall positive feedback in the flashprog channel. The same changes
have been sent to flashrom to prevent diverging specs.

Change-Id: Ib2d2e7ca343f6433028bdc00390ba0980cca98a1
Signed-off-by: Funkeleinhorn <git@funkeleinhorn.com>
Reviewed-on: https://review.sourcearcade.org/c/flashprog/+/107
Tested-by: Nico Huber <nico.h@gmx.de>
Reviewed-by: Nico Huber <nico.h@gmx.de>
1 file changed