Wykres commitów

53 Commity (0145baeb2e3bac31bf9d3cbd0dab38d70618d46b)

Autor SHA1 Wiadomość Data
nightwalker-87 0145baeb2e Fixed memory alignment for STM32L5/U5/H5 chips
(Closes #1362)
2024-01-20 13:00:52 +01:00
nightwalker-87 ba335a47ab STM32F76xxx: Added flashing in dual bank mode
(Closes #1174)
2023-11-27 22:00:27 +01:00
rcubee 99a2be4d28 initial commit 2023-11-11 17:27:05 +01:00
nightwalker-87 fd8d8e6139
Merge branch 'develop' into testing 2023-09-02 17:35:59 +02:00
andrew 1861b8dc9f Fix stm32lx flash loader on STM32L0
STM32L0 chips use loader_code_stm32lx, but this flash loader is built
for armv7-m and uses instructions that are unsupported on STM32L0 (which
have Cortex M0+ cores implementing armv6-m).

In particular, loader_code_stm32lx uses variants of add-immediate that
do not update the condition flags ( `add r0, r0, #4` ). These are 32bit
instructions in armv7-m and are not available in armv6-m.

Enable loader_code_stm32lx to run on both armv6-m and armv7-m by
building for armv6-m, which requires changing the `add` instructions to
`adds` instructions that do update condition flags (which is ok because
the subs updates the condition flags again before the branch).
2023-08-27 13:34:00 -07:00
andrew 2e6cf7d806 Fix use of uninitialized flash_loader_t in stm32l1_write_half_pages
stm32l1_write_half_pages uses a local flash_loader_t that is never
initialized.

This results in stlink_flash_loader_run using uninitialized values for
fl->buf_addr and fl->loader_addr when copying the buffer
and initializing the source register and PC before running the core to
execute the flashloader.

Pass the flash_loader_t from stlink_flashloader_write through to
stm32l1_write_half_pages and use that one instead of an uninitialized
local structure.
2023-08-27 13:33:57 -07:00
nightwalker-87 8fad9be9d0 [refactoring] Clean-up for stlink-lib
- Moved declarations for read/write functions to read_write.h .
- Checked & revised header includes
- Changed some datatypes for write_buffer_to_sram() to avoid explicit
casting.
2023-06-25 15:45:33 +02:00
nightwalker-87 101d77bf7e Formatting & style fixes. 2023-06-24 23:55:12 +02:00
nightwalker-87 5d3f3ec7f4 Set flash_type for STM32H5 devices 2023-06-10 21:37:01 +02:00
nightwalker-87 755c20c08e Replace data types with fixed width typedefs (C99)
- Unified variable type: size_t --> uint32_t
- Removed unnecessary explicit casts
- Minor formatting fixes
2023-06-10 20:07:19 +02:00
nightwalker-87 efc5c3713d Fixed flash-write/verify error
(Closes #1303)
2023-06-09 14:51:57 +02:00
nightwalker-87 be2e7e3883 [refactoring] Clean-up for stlink-lib
- Ensure proper function declaration
- Moved some functions to related modules
- Checked & revised header includes
- Renamed "md5" to "lib_md5"
- New source file "md5"
2023-06-09 01:28:22 +02:00
nightwalker-87 c8eaebc58e Improvents for library documentation
- Renamed header file reg.h to register.h
- Added unified header comments for files
- [doc] flash_loader.h: // Static functions
2023-06-07 22:44:59 +02:00
nightwalker-87 92ad99fe35 Minor fixes & additions
- G49x_G4Ax & WLEx: Added dualbank support
- G49x_G4Ax: Added option byte support
- Minor formatting improvements
- Replaced leftovers for non-fixed length types
2023-06-07 22:01:56 +02:00
nightwalker-87 5e85fd0639 Replace data types with fixed width typedefs (C99)
- Unified variable types (Closes #909)
short --> int16_t
unsigned short --> uint16_t
int --> int32_t
unsigned int --> uint32_t
long --> int32_t
unsigned long --> uint32_t
long long --> int64_t
unsigned long long --> uint64_t

- Added missing header includes
2023-05-08 02:05:55 +02:00
nightwalker-87 5621d541d9 Resorted #defines in stm32flash.h 2023-05-03 13:55:19 +02:00
nightwalker-87 800c8616fb Unified #define names for STM32 devices 2023-04-30 22:32:59 +02:00
nightwalker-87 823187216a st-flash: auto-reset after mass erase 2023-04-30 20:46:37 +02:00
nightwalker-87 7c2c953ff6 Unified chipid enum naming for L0 series 2023-04-30 19:21:17 +02:00
nightwalker-87 1775184084 General Project Update
- Updated CHANGELOG.md
- Updated README.md
- Merged flash loader source files
2023-04-30 14:31:50 +02:00
nightwalker-87 da3d9e3f1e Formatting and whitespace clean-up 2022-01-21 21:31:54 +01:00
nightwalker-87 80b05c547e Updated MCU core-ids 2022-01-17 00:39:57 +01:00
nightwalker-87 7509295222 [refactoring] Clean-up for headers & defines
- Removed additional extern "C" linkage specs
- Removed commented sections
- Moved out further device specific defines
- Renamed defines STM32_CHIP_ID_*
2022-01-16 19:31:22 +01:00
nightwalker-87 c854df5edd Updated MCU core-ids 2022-01-15 01:58:42 +01:00
nightwalker-87 115f7c846a Transition to new enum stm32_chipids 2022-01-09 23:53:30 +01:00
nightwalker-87 9b07c1dc19 Transition to new enum stm32_flash_type 2022-01-09 22:55:56 +01:00
Oleksiy Slyshyk 698b97bbdd fixes printf format formating 2021-08-15 12:30:09 +03:00
Oleksiy Slyshyk bef3321ea4 Fixes few warnings for msvc about type conversion with possible lost data. 2021-08-15 12:18:46 +03:00
nightwalker-87 dc5388d94c Merge branch 'testing' into develop
- Moved chip-specific parameters into separate files (#1129)
- Aligned chip names & references
- General spelling & formatting fixes
- Set of fixes and improvements (#1154)

(Closes #237)
2021-07-16 15:01:13 +02:00
nightwalker-87 c6ecdac78f
Merge pull request #1154 from Ant-ON/l0_soft_loader_fix
Set of fixes and improvements
2021-06-22 21:09:48 +02:00
nightwalker-87 2e6c909c3e General Project Update
- Removed GitHub-CI VE for Ubuntu 16.04 (deprecated)
- Minor fixes for some comments
2021-05-30 23:51:12 +02:00
anton 9acf539c70 Optimizing the half page write fallback 2021-05-26 23:04:39 +05:00
nightwalker-87 620b529956 Aligned naming scheme for chip-ID files 2021-05-16 22:27:14 +02:00
Kristie Simpson f02618c53c Adding option byte info for STM32F411XX 2021-05-11 08:45:05 -06:00
anton 498d11b12b Moved the interrupt masking into flash loader init function 2021-04-25 12:25:45 +05:00
anton 2b3a31609c Moved set the PG flag from loader to code 2021-04-25 12:25:15 +05:00
anton 6bd99d4b55 flash_loader: fixed interrupt masking 2021-04-06 22:03:52 +05:00
anton 4fc6344d44 flash_loader: fixed alignment of size of the lx loader 2021-04-05 22:13:17 +05:00
anton 4334ce48b2 flash_loader: added reset of IWDG
If IWDG is enabled by hardware, then IWDG cannot be disabled by software
2021-04-04 13:35:22 +05:00
anton 817c8ad436 flash_loader: fixed setup PG flag in F0/VL flash loaders, code cleared 2021-04-04 13:34:36 +05:00
anton be9c9dec76 flash_loader: fixed check of the flash loader results 2021-04-04 13:33:46 +05:00
anton c0653f6595 flash_loader: improved handling errors 2021-04-04 13:28:51 +05:00
anton 7cfab876e7 flash_loader: fix typo in the stm32l4 loader 2021-04-04 13:28:02 +05:00
anton 76f153035a flash_loader: disable interrupt before start 2021-03-19 20:44:26 +05:00
anton 41bbbc2e96 flash_loader: fix check BUSY flag, code simplified 2021-03-19 20:44:16 +05:00
anton ebcf04f02b flash_loader: used timeout in ms 2021-03-19 20:43:55 +05:00
Sebastiaan de Schaetzen 9fd7e63ec2 flash_loader: increase wait rounds for slow boards 2021-01-14 11:51:14 +01:00
Ant-ON 277eee7aec Move check of current instruction mode to stlink_run 2020-11-07 13:50:14 +05:00
Ant-ON 85f0e93911 Add switch to Thumb mode before starting flash loader 2020-11-05 17:00:48 +05:00
Ant-ON 304635af64 Using vl flashoader with all F1 series 2020-09-27 14:27:33 +05:00