- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
我有两 block 带有 STM32F437 (IGH6 7BA4S VQ PHL 7B 542) 处理器的开发板。我们用 openocd 和 jtag 对它们进行编程,但是最近有一张卡停止工作了。不再可能对卡进行编程,我们发现的差异之一是卡之间的用户选项字节不同。
我尝试做的是使用 options_write 命令。请注意,STM32F4 显然属于“stm32f2x”命令。
openocd -f openocd.cfg -c "reset halt; stm32f2x unlock 0; reset halt; stm32f2x options_write 0 0x0EC"
这导致错误消息:“错误:stm32x 设备 protected ”
在 STM32F437 引用手册 RM0090 的“3.7.2 编程用户选项字节”下,它说:
To run any operation on this sector, the option lock bit (OPTLOCK) in the Flash option control register (FLASH_OPTCR) must be cleared. To be allowed to clear this bit, you have to perform the following sequence: \n
- Write OPTKEY1 = 0x0819 2A3B in the Flash option key register (FLASH_OPTKEYR)
- Write OPTKEY2 = 0x4C5D 6E7F in the Flash option key register (FLASH_OPTKEYR)
The user option bytes can be protected against unwanted erase/program operations by setting the OPTLOCK bit by software.
为此,我在 telnet session 中尝试了以下操作:
mww 0x08 0x08192A3B
mww 0x08 0x04C5D6E7F
mdw 0x0C
mww 0x18 0x0EC
mww 0x14 0x0EC
第1行0x08为FLASH_OPTKEYR,第3行0x0C为FLASH_SR,检查BSY位是否未设置,第4行0x14为FLASH_OPTCR1,第5行0x14为FLASH_OPTCR。
然后重新启动并尝试对应用程序进行编程openocd -f openocd.cfg -c "program HCF-220_07_010_PA2.hex reset exit"
这会导致错误:
Error: stm32x device protected.
我还尝试在编程前执行以下命令解锁:openocd -f openocd.cfg -c "openocd -f openocd.cfg -c "重置暂停; stm32f2x解锁0;程序 HCF-220_07_010_PA2.hex 重置退出”
同样的结果:
Error: stm32x device protected.
更新
我在 telnet 中尝试了以下但没有成功,用户选项仍然是 0xCFC:
mww 0x40023C08 0x08192A3B
mww 0x40023C08 0x04C5D6E7F
mdw 0x40023c0c
mww 0x40023C18 0x0EC
mww 0x40023C14 0x0EC
mww 0x40023C08 0x02
电源循环
在 RM0090 第 3.7.2 章中,它还说:4。在 FLASH_OPTCR 寄存器中设置选项起始位 (OPTSTRT)
因此,上面的 nr 6.
最佳答案
我的工作解决方案如下:
stm32f2x lock 0
是锁不解锁。重置初始化
mww 0x40023C08 0x08192A3B
mww 0x40023C08 0x04C5D6E7F
mdw 0x40023c0c
等待闪存写入完成,确保我们收到 00000000mww 0x40023C18 0x0FFF0000
mww 0x40023C14 0x0FFFAAEC
将 user_options 写入与工作相同mww 0x40023C14 0x0FFFAAEE
设置选项起始位,步骤“4”。在 rm0090。mdw 0x40023c0c
等待闪存删除完成,确保我们收到 00000。这大约需要 10 秒。它不能与 OpenOCD 命令“options_write”一起工作的原因,可以在 OpenOCD 手册中找到。 “user_options”参数采用来自 FLASH_OPTCR 的位 31-28 和 7-0。
关于stm32f4 - Openocd如何将选项字节写入STM32F4,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/48927028/
我正在对 JVM 上的 STM 技术进行一些研究。阅读了一些文档后,我对 Multiverse 的实现有些困惑。 根据 the Multiverse FAQ , Multiverse 不支持检测。然而
我想知道 Clojure 怎么可能已经实现了软件事务内存并且没有发现任何问题,而微软没有完成它的 C# 工作并注意到一些问题使得实现这里描述的 STM 不切实际: http://www.bluebyt
最后,我有以下设置 C:>哪里玩 C:\apps\play-2.2.0\play C:\apps\play-2.2.0\play.bat C:> 哪里 scala C:\apps\scala\bin\
我试图找出 Clojure 所称的 STM 与 Haskell 中实现的 STM 之间的区别。撇开实际的语言语义差异不谈,正如 Rich Hickey 在他的演讲中所说,Clojure 的 STM 实
阅读 Bartosz Milewski 的精彩作品 blog post在 STM 上,我很兴奋地阅读了以下内容: But take into account an important fact: ST
大家好, 在某些时候,我认为这些 stm 实现(我使用过一点点的多元宇宙......),被过度宣传了。因为在某些时候他们使用 CAS 来为他们提供操作的原子性。如果我直接使用 CAS 而不是使用这些实
haskell 的 stm 库中有一个函数,其类型签名如下: alwaysSucceeds :: STM a -> STM () 根据我对 Haskell 中 STM 的了解,在执行 STM 计算时,
在 Clojure 中,我们使用 STM 来实现并发。 我的问题是STM使用数据的时间点值,这是否会带来歧义? 我们如何知道访问了什么值? 最佳答案 Clojure 中的 STM 提供了(通过 ref
我需要有关用作原子更改日志的数据结构的建议。 我正在尝试实现以下算法。有流量传入更改更新内存中的映射。在类似 Haskell 的伪代码中它是 update :: DataSet -> Some
我正在尝试对这两个(软件事务内存和原子操作,我想两者不一样)进行一些基准测试,尽管我没有使用STM做太多事情(它似乎很难使用),但我成功地尝试了对基准测试进行计数,即所有线程将共享计数器递增 5000
我能够使用 STM 初始化状态并将其打印出来: module Main where import Control.Concurrent.STM data State = State {name ::
我读过两个关于 STM 如何实现的完全不同的描述。也许两者都是正确的,或者一个是错误的,我希望有人能阐明这一点。 Take 1(维基百科):允许所有线程修改共享内存,但事务中的每次读写都会被记录下来。
我知道将具有副作用的函数放在 STM 事务中通常是不好的做法,因为它们可能会被重试和调用多次。 然而,在我看来,您可以使用代理来确保只有在事务成功完成后才会执行副作用。 例如 (dosync //
我正在编写一个程序,其中大量代理监听事件并对其使用react。由于Control.Concurrent.Chan.dupChan已弃用我决定使用 TChan 的广告。 TChan 的表现比我预想的差很
我正在研究 Clojure 中的并发编程。 http://clojure.org/concurrent_programming 我了解到atom、ref和agent形式是用来维护程序状态的。 仅ref
你好,我正在阅读《clojure 的乐趣》这本书,在关于 STM 的部分中,他们有一个 2 个事务的图像,其中 A 最初从引用中检索与 B 相同的值,然后事务 A 和 B 都进行计算但 A 首先完成并
我熟悉Database transactions ,并花费了大量的时间调整isolation levels 。我从未在代码中实现过自己的事务模型。 我已通读 the source code对于 Clo
我有一个事务由于某种原因无限期失败,我想在内部使用跟踪指令。例如,要在执行此片段中的事务之前打印 MVar 的状态: data_out do putTMVar
当我们运行 STM 表达式时,它命中了 retry,线程被阻塞,如果条目被修改,事务将再次运行。 但我想知道: 如果我们读取一个 STM 变量,但在导致重试的特定分支中实际未使用该变量,更新它是否会尝
我正在研究 Clojure 中的并发编程。 http://clojure.org/concurrent_programming 我了解到atom、ref 和agent 表单用于维护程序状态。 只有 r
我是一名优秀的程序员,十分优秀!