Commit Graph

4506 Commits

Author SHA1 Message Date
Stefan Rueger
bf7062cf6d Put static variables of ser_win32.c into context structure 2024-05-10 17:38:18 +01:00
Stefan Rueger
e652726e1b Put static variables of ser_posix.c into context structure 2024-05-10 17:28:37 +01:00
Stefan Rueger
9a908a24f9 Add argument checks for str_sprintf() 2024-05-10 17:18:54 +01:00
Stefan Rueger
366d9bb66e Fix argument type for str_sprintf() 2024-05-10 17:18:27 +01:00
Stefan Rueger
f833691e00 Make static structure const in ser_win32.c 2024-05-10 17:14:48 +01:00
Stefan Rueger
93ba3e9feb Make static structure const in ser_posix.c 2024-05-10 17:14:15 +01:00
Stefan Rueger
70e1869852 Fix rts cache value in serbb_setpin() for serbb_win32.c 2024-05-10 14:27:39 +01:00
Stefan Rueger
8a807b8a53 Move static variables into PDATA in serbb_win32.c 2024-05-10 14:27:15 +01:00
Stefan Rueger
fbf9a9f539 Move static variables into PDATA in serbb_posix.c 2024-05-10 14:12:54 +01:00
Stefan Rueger
b4ed989c99 Make static struct const in serbb_posix.c 2024-05-10 14:10:37 +01:00
Stefan Rueger
2c8c0a79a1 Improve error messaging 2024-05-10 13:36:52 +01:00
Stefan Rueger
9fb2f42246 Use avr_cc_buffer() instead of static buffer for returning a string 2024-05-10 13:34:25 +01:00
Stefan Rueger
3bbb0930f5 Provide safety margin for avr_cc_buffer(n) 2024-05-10 13:29:24 +01:00
Stefan Rueger
e85ecfa503 Utilise is_memset() in avrcache/developer_opts 2024-05-10 13:07:22 +01:00
Stefan Rueger
9d15a167e7 Provide avr_cc_buffer(n) for allocating n bytes in temporary buffer 2024-05-10 13:03:05 +01:00
Stefan Rueger
5dc019c721 Harden avrdude against early pmsg_...() calls 2024-05-10 12:07:46 +01:00
Stefan Rueger
80251073cd Put static variables of ser_avrdoper.c into context structure 2024-05-10 11:00:18 +01:00
Stefan Rueger
292947d9a8 Put static variable of ppi.c into context structure 2024-05-10 10:29:38 +01:00
Stefan Rueger
443962e577 Improve error message when usb device not found in avrftdi.c 2024-05-10 00:17:09 +01:00
Stefan Rueger
c411555d27 Differentiate cause of Cannot find programmer id 2024-05-10 00:16:00 +01:00
Funkeleinhorn
e72d672859 Move serprog enable logic to pgm->initialize()
This commits moves the logic to enable the serprog programmer to be
ready for programming to the initalize() function as it seems to be the
counterpart of disable() and is called directly before programming
starts. This allows to open() a serprog programmer without blocking the
SPI bus as 0x15 S_PIN_STATE and 0x18 S_CS_MODE is only called in
initalize before the actual programming starts.
2024-05-09 22:46:39 +02:00
Stefan Rueger
9431330887 Change free() to mmt_free() 2024-05-09 19:07:43 +01:00
Stefan Rueger
4ccbf49f0f Change pinmask_to_str() to pinmask_to_strdup()
No longer is the string returned in static space (which the next call
overwrites); instead a mmt_strdup()'d string is returned that needs
mmt_free()'ing.
2024-05-09 19:03:34 +01:00
Stefan Rueger
c5c49d7efd Remove unused function pin_to_str()
... as it was used wrongly and led to errors. Better to use
pin_to_strdup()
2024-05-09 17:30:44 +01:00
Stefan Rueger
e6503115f7 Use pins_to_strdup() instead of pins_to_str()
The latter returns a string in a static buffer that is overwritten by the
next call. Unfortunately, this function was used more than once in
arguments of the *same* msg_error(), which would have given a wrong error
message. pins_to_strdup() returns a string to malloc'd space that needs
freeing.
2024-05-09 17:25:38 +01:00
Stefan Rueger
bf414c7c58 Make static function greppable in fileio.c 2024-05-09 11:06:50 +01:00
Stefan Rueger
c2264ad5a9 Put static variable of config_gram.y into context structure 2024-05-09 11:05:35 +01:00
Stefan Rueger
fb1a63b189 Add author to config_gram.y for contributions from 2022 2024-05-09 10:58:08 +01:00
Stefan Rueger
b25c28aea7 Guard against out-of-range pin_name in config_gram.y 2024-05-09 10:49:40 +01:00
Stefan Rueger
6d8fce594c Put static variable of dfu.c into context structure 2024-05-08 22:32:27 +01:00
Stefan Rueger
0c565354aa Make two static structs read-only in developer_opts.c 2024-05-08 22:23:43 +01:00
Stefan Rueger
161f763507 Consolidate functions returning a prog_modes string 2024-05-08 22:10:06 +01:00
Stefan Rueger
d425e737a4 Remove static variable in winconf.c 2024-05-08 19:58:07 +01:00
Stefan Rueger
d8d47127d9 Update avrdude.conf with new AVRnnDUnn parts 2024-05-08 19:01:00 +01:00
Stefan Rueger
40e75a447f Update avrintel.c from new atdf files 2024-05-08 18:59:32 +01:00
Funkeleinhorn
43e998b5c4 Add documentation and clean up code 2024-05-08 18:13:24 +02:00
Funkeleinhorn
2266a0fe9c Do enable/disable in correct functions instead of in open/close 2024-05-08 16:56:58 +02:00
Funkeleinhorn
b84b2728d0 Make CS an extended parameter 2024-05-08 15:52:30 +02:00
Stefan Rueger
14b337bb97 Put static variables of config.c into context structure 2024-05-07 23:03:02 +01:00
Stefan Rueger
1b0fb273a9 Make static variable const in avrftdi_tpi.c 2024-05-07 22:35:33 +01:00
Stefan Rueger
8a36a2f531 Put static variables of bitbang.c into context structure 2024-05-07 22:24:27 +01:00
Stefan Rueger
fa186e26a3 Put static variables of avrpart.c into context structure 2024-05-07 21:11:39 +01:00
Stefan Rueger
9f69a6e09a Put static variables of avr.c into context structure
... and convert static memory for strings returned by avr_prog_modes()
into closed-circuit memory area in the context structure
2024-05-06 22:37:09 +01:00
Stefan Rueger
638a429337 Add const to pointer argument where possible 2024-05-05 23:06:38 +01:00
Stefan Rueger
5cf001f045 Space pointer declarations consistently 2024-05-05 23:03:41 +01:00
Stefan Rueger
59edcd8c78 Use command line programmer name in messages 2024-05-05 23:00:47 +01:00
Stefan Rueger
14e32f49c4 Adapt messages to AVRDUDE style 2024-05-05 22:57:24 +01:00
Funkeleinhorn
30d9f67ed4 Add serprog programmer
This commit adds support to program AVRs via programmers speaking
the serprog protocol used by flashrom. A programmer implementing this is
for example: https://github.com/stacksmashing/pico-serprog
2024-05-05 16:58:26 +02:00
Stefan Rueger
e35cacf3d9 Silence compiler warning when printing size_t variable 2024-05-02 17:43:15 +01:00
RoboSchmied
54cf8717f0 Fix: 7 typos
Co-authored-by: RoAGmer <no-reply@github.com>
Signed-off-by: Michael Seibt <github@roboschmie.de>
2024-05-02 00:25:16 +02:00