mirror of
https://github.com/DarkFlippers/unleashed-firmware.git
synced 2025-12-12 12:42:30 +04:00
New clock switch schema, fixes random core2 crashes (#3008)
* Updated stack to 1.17.0 * hal: ble: Fixed stack config * Bumped stack version in config * scripts: added validation of copro stack version in update bundles * Copro: update to 1.17.2 * FuriHal: adjust tick frequency for HSE as sys clk * FuriHal: adjust systick reload on sys clock change * Sync api and format sources * scripts: updated ob.data for newer stack * FuriHal: return core2 hse pll transition on deep sleep * FuriHal: cleanup ble glue * FuriHal: rework ble glue, allow shci_send in critical section * FuriHal: sync api symbols * FuriHal: cleanup BLE glue, remove unused garbage and duplicate declarations * FuriHal: BLE glue cleanup, 2nd iteration * FuriHal: hide tick drift reports under FURI_HAL_OS_DEBUG * Lib: sync stm32wb_copro with latest dev * FuriHal: ble-glue, slightly less editable device name and duplicate definition cleanup * FuriHal: update ble config options, enable some optimizations and ext adv * FuriHal: update clock switch method documentation * FuriHal: better SNBRSA bug workaround fix * FuriHal: complete comment about tick skew * FuriHal: proper condition in clock hsi2hse transition * FuriHal: move PLL start to hse2pll routine, fix lockup caused by core2 switching to HSE before us * FuriHal: explicit HSE start before switch * FuriHal: fix documentation and move flash latency change to later stage, remove duplicate LL_RCC_SetRFWKPClockSource call --------- Co-authored-by: hedger <hedger@nanode.su> Co-authored-by: hedger <hedger@users.noreply.github.com>
This commit is contained in:
@@ -73,6 +73,9 @@ class Main(App):
|
||||
self.parser_generate.add_argument(
|
||||
"--I-understand-what-I-am-doing", dest="disclaimer", required=False
|
||||
)
|
||||
self.parser_generate.add_argument(
|
||||
"--stackversion", dest="stack_version", required=False, default=""
|
||||
)
|
||||
|
||||
self.parser_generate.set_defaults(func=self.generate)
|
||||
|
||||
@@ -93,6 +96,13 @@ class Main(App):
|
||||
if not self.args.radiotype:
|
||||
raise ValueError("Missing --radiotype")
|
||||
radio_meta = CoproBinary(self.args.radiobin)
|
||||
if self.args.stack_version:
|
||||
actual_stack_version_str = f"{radio_meta.img_sig.version_major}.{radio_meta.img_sig.version_minor}.{radio_meta.img_sig.version_sub}"
|
||||
if actual_stack_version_str != self.args.stack_version:
|
||||
self.logger.error(
|
||||
f"Stack version mismatch: expected {self.args.stack_version}, actual {actual_stack_version_str}"
|
||||
)
|
||||
return 1
|
||||
radio_version = self.copro_version_as_int(radio_meta, self.args.radiotype)
|
||||
if (
|
||||
get_stack_type(self.args.radiotype) not in self.WHITELISTED_STACK_TYPES
|
||||
|
||||
Reference in New Issue
Block a user