Multi Source Translation Content

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Multi Source Translation Content

讨论

排序依据:
使用 S32K3X8EVB-Q289 板载调试器对自定义 S32K358 目标进行编程 我目前正在使用 S32K3X8EVB-Q289 评估板,并基于 S32K358 MCU 开发了定制硬件设计。 请问您能否澄清一下: 官方是否支持使用 EVB 板载调试器对外部 S32K358 目标进行编程/调试? 如果支持,EVB 需要进行哪些跳线设置或硬件修改? 为此应该使用哪个调试连接器? 与使用 S32 调试探针相比,有哪些局限性? 是否有相关文档或应用笔记描述此配置? 感谢您的支持。 问候, 亚什·古普塔 Re: Using S32K3X8EVB-Q289 On-Board Debugger to Program a Custom S32K358 Target 你好@Yash2530 , 1. 是的,支持使用 S32K3X8EVB-Q289 板载调试器对外部 S32K358 目标进行编程/调试。实际上,EVB 板载 OpenSDA 调试器使用的是 P&E Micro 开发的引导加载程序/调试应用程序 - https://community.nxp.com/t5/S32-Design-Studio/Which-debugging-interface-is-better/mp/1715877 2. 对于此使用情况,EVB 上不需要焊接返工或跳线设置。 3. J55 USB 主机连接器。 4. 实际上,对于外部 S32K358 目标的标准烧录和源代码级调试,EVB 的板载调试器应该足够了。由于我不知道您最看重哪些功能,请您自行比较各项功能: https://www.nxp.com/design/design-center/software/automotive-software-and-tools/s32-design-studio-ide/s32-debugger-for-s32-platform:S32DBG-S32PLATFORM https://www.pemicro.com/products/product_viewDetails.cfm?product_id=15320180&productTab=5045 5. 是的, https://www.nxp.com/webapp/Download? colCode=S32K3X8EVB-Q289HWUM 顺祝商祺! 帕维尔 Re: Using S32K3X8EVB-Q289 On-Board Debugger to Program a Custom S32K358 Target @PavelL , 尝试对外部控制器进行编程时出现此错误。 CMD>VC 正在验证目标文件 CRC-16 校验值是否与设备范围匹配…… 区块 00400000-0042F4B7 ... 计算出的 CRC-16 值与数据块不匹配。(文件 = $A9EE,设备 = $EDEF) 验证设备闪存时出错 Flash编程过程中发生错误。 信息:DAP IDCODE = 0x6BA02477 信息:DAP 已成功启动。DP CTRL/STAT = 0xF0000000 启动 RESET 脚本 (C:\NXP\S32DS.3.6.7\eclipse\plugins\com.pemicro.debug.gdbjtag.pne_6.1.8.202603121731\supportFiles_ARM\NXP\S32K3xx\S32K358.mac)... REM 启用 MC_ME 模块中选定内核的时钟 延迟200毫秒…… 完毕。 REM 初始化 RAM 和 DMA: REM 初始化 DMA TCD: REM 将有效的可执行代码复制到每个要使用的核心的 RAM 中。 REM 启用 MC_ME 中所需的内核: 延迟20毫秒…… 完毕。 延迟20毫秒…… 完毕。 重置脚本 (C:\NXP\S32DS.3.6.7\eclipse\plugins\com.pemicro.debug.gdbjtag.pne_6.1.8.202603121731\supportFiles_ARM\NXP\S32K3xx\S32K358.mac)完全的。 PEmicro GDB 启动失败:闪存编程期间出错。调试会话结束。 PE错误:下载到设备时出错。调试会话结束。 通过 127.0.0.1 与“127.0.0.1”断开连接。通过端口“53100”与6224断开连接 PE-ERROR:错误:尝试发送响应,但连接已关闭。 通过 127.0.0.1 与“127.0.0.1”断开连接。通过端口“53104”与7224断开连接 信息:DAP IDCODE = 0x6BA02477 目标设备已断开连接。 Yash2530_0-1789183717483.jpegYash2530_0-1789183717483.jpegYash2530_0-1789183717483.jpegYash2530_0-1789183717483.jpegYash2530_0-1789183717483.jpegYash2530_0-1789183717483.jpegYash2530_0-1789183717483.jpeg 请帮我解决这些问题。 问候, 亚什·古普塔 Re: Using S32K3X8EVB-Q289 On-Board Debugger to Program a Custom S32K358 Target 你好@Yash2530 , 我使用 S32K3X8EVB-Q289 和通过 J55 连接的板载 PEmicro 调试器进行了参考测试。 在我的测试中,第一次 CRC 验证也报告了不匹配,因为现有的 flash 内容与正在下载的应用程序不同。然而,编程顺序随后继续进行,包括闪存擦除和编程。因此,初始 CRC 不匹配不一定是根本原因,也不能单独确认安全调试已启用。 重要的区别在于,在你提供的日志中,调试会话在第一个 VC 命令之后立即终止。我没有看到后续用于擦除和编程闪存的 EM 和 PM 命令。 请检查 PEmicro 调试启动配置,特别是是否启用了可执行文件下载和闪存编程。请同时提供从会话开始到结束的完整 PEmicro 日志。日志开头应显示 CM 命令和选定的 .arp 文件。闪存算法。 作为参考,我成功的测试使用了以下针对 HSE 禁用设备的算法: PavelL_0-1789370094591.pngPavelL_0-1789370094591.pngPavelL_0-1789370094591.pngPavelL_0-1789370094591.pngPavelL_0-1789370094591.pngPavelL_0-1789370094591.png 请确认您在配置中选择的算法与您的 S32K358 设备的实际状态相符,例如 HSE 已禁用或 HSE 已启用。   顺便说一下,下次请另开新帖——我们只会在最后一条回复发布7天后才开始追踪社区帖子。我只接收更新订阅邮件,偶尔会错过一些。 顺祝商祺! 帕维尔 Re: Using S32K3X8EVB-Q289 On-Board Debugger to Program a Custom S32K358 Target 你好@PavelL , 我已经对设备进行了编程,问题出在 JTAG 的 RESET 引脚与板载 MCU 和目标板 MCU 的冲突上。所以我将复位引脚与 JTAG RESET 引脚隔离,编程就可以正常工作了。现在唯一的问题是我需要手动重置MCU。 您是否也使用了自定义目标以及 EVK 板 jtag(J50 和 J55(usb))连接器? 此致, 亚什·古普塔 Re: Using S32K3X8EVB-Q289 On-Board Debugger to Program a Custom S32K358 Target 你好@Yash2530 , 是的,我使用过外部 PEmicro 调试器和 Lauterbach TRACE32。 根据我的笔记,EVB 上的所有跳线都保持在默认位置,只有 J685 和 J23 被设置为位置 2-3。 供您参考,跳线配置如下: J685:2-3 J23:2-3 J25:1-2 J30:1-2 J31:1-2 J691:1-2 J37:2-3 J746:2-3 J13:1-2 J16:1-2 J701:1-2 在这种配置下,我的设备中编程、调试和自动RESET功能都能正常工作。请将这些跳线设置与您当前的EVB配置进行比较。 顺祝商祺! 帕维尔 Re: Using S32K3X8EVB-Q289 On-Board Debugger to Program a Custom S32K358 Target 你好@Yash2530 , “提供 i2c 和 spi 示例代码”是一个新话题。为了保持讨论主题的清晰性,请创建一个新的专门讨论主题。 感谢您的理解。 顺祝商祺! 帕维尔 Re: Using S32K3X8EVB-Q289 On-Board Debugger to Program a Custom S32K358 Target @PavelL , 感谢您的回复,这真的很有帮助。您能否也分享一下 I2C 和 SPI 的示例代码?因为 RTD 的示例代码包含环回示例。我尝试通过保持外设的主控状态,使用 SPI 和 I2C 初始化外设,但是我在 SPI 和 I2C 上都没有收到时钟信号,MOSI 和 MISO 也没有响应。如果你能分享一个,那就太好了。 谢谢! 亚什·古普塔
查看全文
FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external device; Subject: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external device; suspect conflict with onboard tri-radio module (MAYA-W27x) Hi NXP team, I'm trying to bring up an external SPI device (Waveshare 2-CH CAN HAT(https://www.waveshare.com/wiki/2-CH_CAN_HAT), dual MCP2515) on the FRDM-IMX93 board's EXPI 40-pin header (P11), using LPSPI3 (GPIO_IO08–11, matching the RPi-compatible pin positions). I've confirmed the HAT itself is fully functional (tested and working on a genuine Raspberry Pi with the standard dtoverlay=mcp2515 configuration). Board / BSP: FRDM-IMX93, model NXP FRDM-IMX93 NXP i.MX Release Distro 6.18-whinlatter, kernel 6.18.2-1.0.0-gf49f45233f7b What I've configured (all verified correct at the device tree level): Overlay adds mcp2515@0/mcp2515@1 under &lpspi3, with cs-gpios = <&gpio2 8 1>, <&gpio2 7 1>; (GPIO_IO08/GPIO_IO07), matching the GPIO-based CS pattern I found in NXP's own upstream patch for a similar FRDM-IMX93 SPI3 peripheral (pixpaper display overlay). Extended &pinctrl_lpspi3 to mux GPIO_IO07 (CS1) as GPIO, since it was previously (MUX UNCLAIMED) in /sys/kernel/debug/pinctrl/. Disabled the pre-existing spidev0 node that was conflicting with CS0. Enabled reg_vexp_3v3/reg_vexp_5v (regulator-always-on) — these were disabled by default and the EXPI header had no power without this. Confirmed /dev/spidev2.0 is created and pinmux shows correct function assignment (lpspi3grp) on all 4 SPI pins. Symptom: mcp251x driver always fails: spi2.0: Cannot initialize MCP2515. Wrong wiring? (err=19) and spi2.1: MCP251x didn't enter in conf mode after reset (err=110) — completely unchanged across every device-tree variation above. Raw SPI-level test with spidev_test (compatible lwn,bk4) on /dev/spidev2.0: RX buffer returns byte-for-byte identical data regardless of whether MOSI/MISO are physically shorted (loopback), left open, or bridged with a shunt. This suggests the SPI3 signals present at P11 header pins 19/21/23/24 are not being reflected in the controller's actual bus activity — i.e., the signals may not be reaching the header at all, or something else is interfering. Suspected root cause: Per UM12181 (FRDM-IMX93 Board User Manual, Section 2.11 "Tri-radio module interface"), the SPI3 signals (CLK, MOSI, MISO, CS0 — multiplexed on GPIO_IO08-11) are shared between the onboard MAYA-W27x tri-radio module and the M.2 connector, via a bidirectional 1.8V level translator (U729), resistor-selected. The document doesn't clarify whether/how the EXPI header (P11) is electrically isolated from this shared path when SPI3 alternate function is driven from the SoC side. Question: Is P11's exposure of GPIO_IO08-11 electrically independent of the U729 translator/tri-radio path, or does using SPI3 on P11 require any additional configuration (e.g., disabling the tri-radio module, GPIO expander bits, or resistor rework) to route/isolate the signal to the header correctly? Is there a validated reference device tree (similar to imx93-11x11-evk-lpspi.dts for the EVK) for using LPSPI3 externally on the FRDM-IMX93 board specifically? Could a schematic excerpt for the SPI3/U729 signal path be shared to confirm the P11 connection topology? Thanks in advance for your help. Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi FRDM-IMX93: No signal is output to the LPSPI3 (P11 EXPI header) SCK pin Issue I am trying to operate an external SPI device (2× MCP2515 CAN) using LPSPI3 (GPIO_IO08-11, spi@42550000) on the P11 EXPI header. The driver is active, and the peripheral appears to be running “internally,” but no signal is being output to the physical SCK pin (GPIO_IO11). Evidence The overlay is applied without errors; spi2.0/spi2.1 are registered in the SPI core. Power, pinctrl, pinctrl-assert-gpios, cs-gpios, and clock source—all are correct and have been verified. CS0 (same bank, GPIO alternate function, mode=0) works flawlessly—pulses are visible with both a multimeter and a logic analyzer. SCK (mode=1, native LPSPI3_SCK) is completely flat/0V on the logic analyzer—whether the HAT is connected or not, it makes no difference in the continuous trigger loop. Nevertheless, LPSPI3’s IRQ (GIC 97) is actually being triggered in /proc/interrupts (a single transfer attempt generated over 220 interrupts) — the peripheral’s internal logic (status/IER registers) is active. Reading the LPSPI3 base address (0x42550000) with /dev/mem returns a “Bus error” — but flexcan2 (0x425b0000), which is running on the same bus, also returns the same error, meaning this is a general /dev/mem limitation, not specific to LPSPI3 (ruled out via the control group). The DMA theory was tested and ruled out: when overriding dmas with an invalid phandle, the driver fell back to PIO with the message “dma setup error -19, use pio,” but the SCK signal still did not appear. The `clk_ignore_unused` boot argument also made no difference. Conclusion The internal logic of the LPSPI3 peripheral is working (generating interrupts), but the SCK signal never reaches the external pin (GPIO_IO11)—while CS0 (GPIO mode) in the same pinctrl group outputs correctly, SCK (native LPSPI3 alternate function) does not. This appears to point to a configuration detail related to the pad driver/silicon or a configuration detail that NXP should be aware of, which cannot be explained by the device tree or software. Question On the FRDM-IMX93, is there an additional hardware/firmware enable step outside the device tree for LPSPI3_SCK (GPIO_IO11, native alternate function) via P11? There is a known example where LPSPI3 works with the same pins on the i.MX93 EVK (community.nxp.com/t5/i-MX-Processors/iMX93AUTO-EVK-SPI-Configuration-for-QCA7006AQ)—could there be a difference specific to the FRDM? Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi If anything is missing, I can add it. root@imx93-11x11-lpddr4x-frdm:/sys/firmware/devicetree/base# ls '#address-cells' clock-osc-24m firmware mcp2515_clock pmu regulator-hmisc-vddio regulator-vexp-3v3 soc@0 usbphynop2 '#size-cells' clock-osc-32k imx93-lpm memory psci regulator-usdhc2 regulator-vexp-5v sound-mqs usdhc3_pwrseq __symbols__ compatible interrupt-controller@48000000 model regulator-adc-vref regulator-usdhc3 remoteproc-cm33 sw-keys aliases cpus interrupt-parent mqs1 regulator-avdd regulator-vdd-12v reserved-memory thermal-zones chosen display-subsystem ldb-display-controller mqs2 regulator-can2-stby regulator-vdd-5p0v secure-enclave timer clock-ext1 ethosu ldb-phy name regulator-dvdd regulator-vddo serial-number usbphynop1 Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi No, the imx93-11x11-frdm.dts file is the original; I edited the mcp2515-can-hat.dtbo overlay file, https://www.waveshare.com/wiki/2-CH_CAN_HAT, I only changed INT_1 from the default GPIO_25 to GPIO_24 (physical pin 18). Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi Hello @irfanktm  Hope you are doing very well. Actually, there are a direct connections between the i.MX93 FRDM PADs and the P11 GPIO_IO08-IO11 Pines: Manuel_Salas_0-1789421014211.pngManuel_Salas_0-1789421014211.pngManuel_Salas_0-1789421014211.pngManuel_Salas_0-1789421014211.pngManuel_Salas_0-1789421014211.pngManuel_Salas_0-1789421014211.pngManuel_Salas_0-1789421014211.pngManuel_Salas_0-1789421014211.pngManuel_Salas_0-1789421014211.png Could you please share steps to reproduce it by my side? Best regards, Salas. Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi Hello @irfanktm  I just made some test by my side: Manuel_Salas_0-1789495251012.pngManuel_Salas_0-1789495251012.pngManuel_Salas_0-1789495251012.pngManuel_Salas_0-1789495251012.pngManuel_Salas_0-1789495251012.pngManuel_Salas_0-1789495251012.pngManuel_Salas_0-1789495251012.pngManuel_Salas_0-1789495251012.png SPI us working well in my i.MX93 FRDM. Manuel_Salas_1-1789495295645.pngManuel_Salas_1-1789495295645.pngManuel_Salas_1-1789495295645.pngManuel_Salas_1-1789495295645.pngManuel_Salas_1-1789495295645.pngManuel_Salas_1-1789495295645.pngManuel_Salas_1-1789495295645.pngManuel_Salas_1-1789495295645.png I have the same environment as you. One more question. Do yo have voltage in your 3V3 and 5V pines of the i.MX93 FRDM board? If not, please take a look to the below link to enable the regulators of the board: https://community.nxp.com/t5/i-MX-Processors-Knowledge-Base/Enable-3-3-V-and-5-V-Regulators-for-Expansion-Header-on-i-MX9/ta-p/2299415 Best regards, Salas. Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi According to the logs, it makes me think you are trying to access to the SPI device over spidev_test, but the device is being handle by the MCP driver. What I need to know is the entire device tree (.dts) that you are using, like: imx93-11x11-frdm.dts Also, if you modified it, please let me know your modifications. Also, I will try to get an mcp2515 CAN module to try the integration by my side. Best regards, Salas. Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi Please kindly share your entire device tree. Or just the related to the lpspi3 node and pinmux. Best regards, Salas. Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi Yes, I have 3.3v and 5V at the p11 header, Why I have errors? imx93-11x11-lpddr4x-frdm login: root root@imx93-11x11-lpddr4x-frdm:~# dmesg | grep -iE 'mcp251|lpspi3' [ 8.989639] mcp251x: no symbol version for module_layout [ 10.032864] mcp251x spi2.1: MCP251x didn't enter in conf mode after reset [ 10.033021] mcp251x spi2.1: Probe failed, err=110 [ 10.033034] mcp251x spi2.1: probe with driver mcp251x failed with error -110 [ 10.074097] mcp251x spi2.0: Cannot initialize MCP2515. Wrong wiring? [ 10.074256] mcp251x spi2.0: Probe failed, err=19 root@imx93-11x11-lpddr4x-frdm:~# ip link show 1: lo: mtu 65536 qdisc noqueue state UNKNOWN mode DEFAULT group default qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 2: eth0: mtu 1500 qdisc mq state DOWN mode DEFAULT group default qlen 1000 link/ether 90:a9:f7:80:42:26 brd ff:ff:ff:ff:ff:ff 3: eth1: mtu 1500 qdisc mq state DOWN mode DEFAULT group default qlen 1000 link/ether 90:a9:f7:80:42:27 brd ff:ff:ff:ff:ff:ff 4: mlan0: mtu 1500 qdisc mq state UP mode DORMANT group default qlen 1000 link/ether 80:a1:97:50:4e:0d brd ff:ff:ff:ff:ff:ff 5: uap0: mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000 link/ether 82:a1:97:50:4f:0d brd ff:ff:ff:ff:ff:ff 6: wfd0: mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000 link/ether 82:a1:97:50:4e:0d brd ff:ff:ff:ff:ff:ff 7: can0: mtu 16 qdisc noop state DOWN mode DEFAULT group default qlen 10 link/can Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi Technical Support Request — MCP2515 on i.MX93 LPSPI3 Multiple MCP2515 CAN controllers (3 units tested, 2 different manufacturers/boards, 8/16 MHz crystals) connected to an i.MX93-11X11-LPDDR4X-FRDM board via LPSPI3 (SPI2) intermittently fail to reach Configuration mode after reset (CANSTAT should read 0x80). Environment: kernel 6.18.2 (NXP downstream), CONFIG_SPI_FSL_LPSPI built-in, ERR051608 prescale fix present. Device tree / pinctrl verified correct (LPSPI3 SIN/SOUT/SCK properly muxed, CS via cs-gpios). Logic-analyzer captures confirm MOSI/SCK/CS are generated correctly and consistently by the host. Key observation: On a freshly opened spidev handle, the very first RESET + CANSTAT read succeeds (~0x80) roughly 50–60% of the time, with consistent ~2–6 ms timing. If additional RESET+read cycles are issued on the same, still-open SPI file descriptor, they consistently fail afterward, settling into a repeatable ~10–11 ms periodic pattern of fixed values (0x00 / 0xFF / 0xFB) that never reaches 0x80 again. This same failure signature is reproduced across all 3 physical MCP2515 units and 2 different board designs, ruling out a single defective chip/module. Adding inter-transfer delay (delay_usecs), a dummy 'flush' SPI transfer, and increasing the gap between cycles to 100 ms did not change the outcome (0/10 success once the pattern starts). VDD, GND, RESET pin and idle MISO level are all confirmed healthy (3.3 V) throughout. The mainline mcp251x kernel driver's own probe() shows the same instability: 5 consecutive bind attempts (unbind/clear driver_override/bind) all failed, alternating between err=-19 ("Wrong wiring?") and err=-110 ("didn't enter in conf mode after reset") in a regular, non-random pattern. This pattern (good on first transfer after open, then a fixed repeatable failure signature on subsequent transfers within the same session — reproduced by the kernel driver's own probe as well) suggests a state that is not being fully cleared between consecutive LPSPI3 transfers/CS cycles, rather than a defect in the MCP2515 units themselves. Question for NXP: is this consistent with a known LPSPI3 (i.MX93) behavior — e.g. FIFO/CS state not resetting cleanly between back-to-back transfers on the same SPI file descriptor — and is there a recommended driver-level workaround (e.g. required delay, FIFO flush, or CS handling) beyond ERR051608? Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi Technical Support Request MCP2515 (Microchip) SPI communication failure on i.MX93 (NXP) SPI2/LPSPI3 1. Summary Two MCP2515 CAN controllers (Waveshare 2-CH CAN HAT, MCP2515-I/SO, 16 MHz crystal) connected to an i.MX93-11X11-LPDDR4X-FRDM board via LPSPI3 (SPI2, CS0/CS1) never enter Configuration mode after power-up or SPI/hardware reset. All register reads return fixed, non-varying values instead of the expected CANSTAT = 0x80. The kernel mcp251x driver consistently reports probe failure (err=-110 "didn't enter in conf mode after reset", or err=-19 "Wrong wiring?"). 2. Environment SoM/board: i.MX93-11X11-LPDDR4X-FRDM Kernel: 6.18.2-1.0.0-gf49f45233f7b (NXP downstream), CONFIG_SPI_FSL_LPSPI=y (built-in), ERR051608 prescale fix already present SPI bus: LPSPI3 (spi@42550000), 2 chip selects, custom device tree overlay (16 MHz fixed-clock, IRQ GPIO3-23 / GPIO3-24) CAN modules: Waveshare 2-CH CAN HAT, MCP2515-I/SO, marking "E3 2335BK5" (genuine Microchip marking format) Driver: mcp251x (mainline), tested against kernel driver and a custom spidev-based test utility 3. Troubleshooting performed Corrected device tree overlay target (&spi1/&lpspi3 vs. incorrect &spi2 label) — overlay now applies correctly, mcp2515 child nodes present in live DT Verified LPSPI3 pinctrl, cs-gpios, interrupt-parent/GPIO mapping against running device tree — all correct Verified master-side SPI signal integrity with a logic analyzer: MOSI, SCK and CS are generated correctly and consistently by the i.MX93 in several captures Confirmed VDD = 3.3V and idle MISO = 3.3V on both CAN modules (no short to GND) Confirmed RESET pin (pin 17, SOIC-18) = 3.3V (inactive) on both modules Tested SPI Mode 0,0 and Mode 1,1 (CPOL/CPHA), 100 kHz-8 MHz clock — no change in behavior Added 10k pull-up resistors on CS0/CS1 to resolve MISO bus contention between the two parallel MCP2515 devices — this stabilized (but did not correct) the readback data Custom spidev test tool: RESET instruction + immediate/continuous CANSTAT polling (1 ms interval, 300 ms window) after reset — CANSTAT settles instantly to a fixed value and never reaches 0x80 Forced WRITE to CANCTRL (0x80) followed by READ — readback is unaffected by the write, indicating the SPI transaction is not being processed by the CAN controller logic 4. Key observation CS0 device: CANSTAT/CANCTRL/all registers consistently read back 0x00 (100% repeatable across dozens of reset+read cycles, independent of register address, SPI mode, or written value). CS1 device: CANSTAT/CANCTRL/all registers consistently read back 0xFF (100% repeatable, MISO never toggles during the transaction). Both devices show clean, correctly-timed MOSI/SCK/CS from the master, but return a fixed value regardless of instruction, address, or CS pull configuration — this pattern is not explained by SPI mode/timing/wiring on the host side and is consistent with the MCP2515 CAN core never leaving its post-reset/oscillator-not-stable state. 5. Request Given the host-side SPI signaling has been verified correct by logic analyzer and the device tree / kernel driver configuration is confirmed correct, we would like guidance on: Whether this failure signature (fixed register readback, CANSTAT never = 0x80) is consistent with a known MCP2515 crystal/oscillator start-up issue, and recommended oscilloscope/verification procedure for OSC1/OSC2 Whether there are known compatibility issues between MCP2515 and i.MX93 LPSPI (beyond ERR051608, already addressed) Recommended next diagnostic steps or RMA process if a hardware defect in the MCP2515 modules is suspected Please let us know if additional logic analyzer captures, device tree files, or kernel logs would help. Re: FRDM-IMX93 — LPSPI3/EXPI (P11) SPI pins produce no valid SPI transactions with any external devi MCP2515 / i.MX93 LPSPI3 — Root-Cause Update Follow-up to our earlier report. A new, isolating test now points away from the MCP2515 modules entirely and toward the i.MX93 LPSPI3 SPI controller / driver. Test performed: Using a userspace spidev tool, we repeatedly issue RESET + CANSTAT-read cycles on LPSPI3 (500 kHz, Mode 0) while varying only the physical state of the MISO line: MISO wired to a real MCP2515 chip: unstable, rarely reaches the expected 0x80. MISO physically disconnected (floating, no chip attached): a structured, repeating byte pattern (0x00 / 0xFF / 0xFB) still appears, with ~10–11 ms periodicity. MISO tied to GND through a 10kΩ resistor: the same repeating pattern still appears, essentially unchanged. MISO shorted directly to GND (~0Ω): the pattern disappears completely — reads become a flat, constant 0x00. Key finding: The exact same byte sequence, with millisecond-for-millisecond identical timing, reappears across independent runs (different process IDs, different times) and across different physical MISO conditions (disconnected vs. 10kΩ pulldown vs. connected to a real chip). The SPI ioctl() call itself returns success (no error) every time — this is not a failed transfer being masked; real data is being clocked in on every call. Interpretation: A genuinely floating or resistor-loaded input pin should not reproduce an identical, host-independent bit pattern down to the millisecond across separate process invocations. This level of determinism suggests the byte values being read back are not representative of the actual MCP2515 SO/MISO line, but are instead coming from a fixed, repeatable internal state of the LPSPI3 peripheral or its Linux driver (e.g., stale RX FIFO content, or a fixed pattern read regardless of the input pin's real logic level) — only a hard short to GND overrides it. Question for NXP: could LPSPI3 (or its Linux driver, spi-fsl-lpspi) under certain conditions return fixed/stale RX FIFO content instead of the pin's real sampled value? Is there a known erratum or driver behavior that would explain a deterministic, wiring-independent readback pattern like this?
查看全文
需要S32K3xx-WB LPUART RTD。 需要 LPUART 的 S32K3x-WB LPUART 实时驱动程序示例。任何帮助都将不胜感激? 要配置的 mex 文件或任何示例。 Re: S32K3xx-WB LPUART RTD needed. HI “ S32K344 白板示例项目”包含S32K344-WB的示例,包括 LPUART 示例。 然而,这些示例中使用的 RTD 版本已经过时了。 对于新项目,我们建议使用最新的S32K3 RTD 7.0.1;然而,其中包含的 S32K344 示例是为S32K3X4EVB-Q257或S32K3X4EVB-T172设计的。这意味着您需要检查原理图,了解 LPUART 实例和引脚分配方面的差异,并相应地修改 RTD 示例。 此致敬礼, Robin
查看全文
HTRC110 PSK/FSK tag reading Capabilities I need to use HTRC110 to read FSK/PSK modulated tokens (mainly HID MicroProx), I found out that the chip is incapable of dealing with such modulation, any confirmation and explanation as to why? such modulation should be simple to handle. Any other alternative from NXP? Re: HTRC110 PSK/FSK tag reading Capabilities Good afternoon alasa995! I'm also doing this research. How far have you gotten? Best regards, Sergey. Re: HTRC110 PSK/FSK tag reading Capabilities Hi, I managed to make the chip work to decode FSK modulation, all that was needed was to tweak the config for the IC. 
查看全文
S32K312: SWT0機能リセットエスカレーション、破壊リセットステータス、およびSRAM保持 NXPチームの皆様、こんにちは。 私はS32K312 Cortex-M7を使い、S32 Design StudioとAUTOSAR RTD 7.0.1 / AUTOSAR 4.9を使って作業しています。 現在、MC_RGMのリセット動作、特にSWT0機能リセット、機能リセットエスカレーション、破壊的リセット、SRAM保持、SBAF/リカバリ動作、およびPower IPリセットAPIのテストを行っています。 1. SWT0機能リセットエスカレーション 私はSWT0タイムアウトを使用して機能リセットを生成しています。 私のMC_RGMの設定は以下のとおりです。 MC_RGM_FRET_FRET((uint32)15U) MC_RGM_DRET_DRET((uint32)0U) 機能リセットカウンタが増加していることを確認しました。 SWT0機能リセット#1 -> FREC = 1 SWT0機能リセット#2 -> FREC = 2 ... SWT0機能リセット#14 -> FREC = 14 次のSWT0リセット後、FRECはクリア/リセットされますが、期待される動作は確認できませんでした。 DES[MC_RGM_FRE] = 1 私の質問は以下のとおりです。 SWT0_RSTは、S32K312のMC_RGM機能リセットエスカレーションカウンタ(FREC)に参加しますか? FRECがFRET=15に達したとき、MC_RGM_FREを生成し、DES[MC_RGM_FRE]を設定すべきでしょうか? エスカレーション直後、FES、DES、FREC、FRET、Power_Ip_GetResetReason() には具体的にどのような値が期待できるでしょうか? SWT0がFRETエスカレーションに参加するために、追加の設定は必要ですか? SBAFやリカバリーハンドリングはFRETのエスカレーションに支障をきたすことはありますか? SWT0/FRETの上昇に関連する既知の不具合やS32K312の挙動はありますか? アプリケーションを継続的に実行すると、15回目の機能リセット後にアプリケーションやデバッガが停止し、期待される破壊的なリセットを観察できません。これがリセットシーケンス、SBAFリカバリ、またはデバッガに関連しているかどうかを知りたいです。 2.すべてのSWT0機能リセットを破壊的なものにしたい テスト目的で、以下のことも達成したいと考えています。 SWT0タイムアウト ↓ 機能リセット ↓ 即時破壊リセット 15回も機能リセットを待つ代わりに。 以下の設定で実現できますか: FRET = 1U; 具体的には: FRET = 1 の場合、最初の適格な SWT0 機能リセットが破壊的なリセットにエスカレートしますか? MC_RGMの追加設定は必要ですか? SWT0は、このエスカレーションの対象となる情報源として確実に認められるのでしょうか? SBAFや回復行動はこれに影響を与えるのでしょうか? これはRTD 7.0.1の設定で直接サポートされていますか? 3. SRAMデータは、機能リセットのたびに消去されます。 私の理解では、S32K3xxリファレンスマニュアルでは、SRAMやシステムメモリは機能リセット後も保持されるべきです。 SRAMテスト変数を作成しました。 #define SRAM_TEST_ADDR ((volatile uint32_t *)0x204007d4U) そして、それを使って機能リセット後のデータ保持状況を確認する。 しかし、機能リセット後にSRAMデータが消去/ゼロに書き換えられていることを確認しました。 私の質問は以下のとおりです。 機能リセットの際にハードウェアがSRAMを保持し、その後ソフトウェアによって上書きされるのでしょうか? S32K312において、機能リセット後も内容が確実に保持されるSRAM領域はどれですか? 関数リセットを通じてその内容を保持するために、SRAMに変数を配置する推奨される方法は何ですか? 専用の.noinitファイルを使うべきでしょうか?または、保持されたSRAMセクション? データ保持に必要なMC_RGM/SRAMの特定の構成はありますか? 機能リセット間でアプリケーションデータを保持するための推奨されるRTD 7.0.1の方法は何ですか? 4. 直接ソフトウェア破壊的リセット また、Power IPを使って直接的なソフトウェア破壊リセットもテストしています: Power_Ip_Init(&Power_Ip_HwIPsConfigPB); gVar= Power_Ip_GetResetReason(); for (count = 0; count < 10125000; count++); Power_Ip_PerformReset(&Power_Ip_HwIPsConfigPB); 現在のMC_RGM構成には以下が含まれます。 static const Power_Ip_MC_RGM_ConfigType Power_Ip_MC_RGM_ConfigPB = ヤージュ (MCU_DEST_RESET) ... MC_RGM_FRET_FRET((uint32)15U) MC_RGM_DRET_DRET((uint32)0U) }; 破壊的なリセットが発生するが、デバッガーは通信を繰り返し失い、再確立する。 次のようなメッセージを見かけます。 情報: DAP IDCODE = 0x6BA02477 情報:DAPの電源投入に成功しました。DP CTRL/STAT = 0xF0000000 複数回繰り返され、続いて次のもの: 割り込みコマンドを受信しました。執行を停止します。 理解したいのは以下の点です。 破壊的なリセット中に、DAPの再接続が繰り返し発生することは想定されていますか? 破壊リセットシーケンス中にCortex-M7に具体的に何が起こるのでしょうか? 破壊的なリセット後、CPUはいつ再び使用可能になりますか? 単一のソフトウェア破壊リセットをデバッグする推奨される方法は何ですか? 5. Power_Ip_PerformReset() 前のブレークポイント挙動 直前にブレークポイントを確実に到達することはできません: Power_Ip_PerformReset(&Power_Ip_HwIPsConfigPB); APIの前に遅延を設定し、デバッガがアクセスを得るのに十分な時間があると期待していました。 場合によっては、ターゲットを手動で一時停止してから実行を再開した後に初めてブレークポイントに到達することがあります。 理解したいのは以下の点です。 リセットAPIの前に遅延があるのに、なぜデバッガはブレークポイントを見逃すのでしょうか? これは、ターゲットが繰り返しリセットされ、デバッガーがDAP経由で再接続されることに関係していますか? 破壊的なリセットの直前や直後にCPUをキャッチする推奨される方法はありますか? RTDのDISABLE_DEBUGGER_TRAPオプションはこの動作に関係していますか? 6. Power IPの初期化とPower_Ip_SetMode() 私のRTDは以下を提供します: void Power_Ip_Init( const Power_Ip_HwIPsConfigType *HwIPsConfigPtr); void Power_Ip_SetMode(const Power_Ip_ModeConfigType *ModeConfigPtr); void Power_Ip_PerformReset( const Power_Ip_HwIPsConfigType *HwIPsConfigPtr ); Power_Ip_ResetType Power_Ip_GetResetReason(void); Power_Ip_RawResetType Power_Ip_GetResetRawValue(void); 現在使用しているもの: Power_Ip_Init(&Power_Ip_HwIPsConfigPB); そして: gVar = Power_Ip_GetResetReason(); 私のモード設定はPOWER_IP_RUN_MODEです。 以下の点についてご説明をお願いします。 Power IPリセットAPIを使用する前に、Power_Ip_Init(&Power_Ip_HwIPsConfigPB)は正しい初期化方法でしょうか? ソフトウェアの機能的/破壊的リセットテストにはPower_Ip_SetMode()が必要ですか? 選択したモードがPOWER_IP_RUN_MODEなら、このリセットテストでPower_Ip_SetMode()を省略してもいいですか? RTD 7.0.1を使って、ソフトウェアの機能リセットとソフトウェア破壊リセットの設定をどうすればよいですか? 環境 MCU:S32K312 コア:Cortex-M7 S32DS:S32 Design Studio AUTOSAR:4.9 RTD: 7.0.1 リセット元: SWT0 フレット: 15 DRET: 0 試験用の申請書を全部ご用意できます、Power_Ip_PBcfg.c。リンカー構成、MC_RGMレジスタキャプチャ、および必要に応じてデバッガーログ。 よろしくお願いします。 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention こんにちは、 @Sharif417 さん。 1. SWT0機能リセットエスカレーション SWT0_RSTdoes S32K312 FRECに参加し、FRECが15に達するとDES[MC_RGM_FRE]が設定されます。Power_Ip_GetResetReason()を呼び出して「MCU_MC_RGM_FRE_RESET」を返すことで読み取れるはずです。 降格されていない機能リセット源(MCRGM.を通じて)はFERD は FREC のインクリメンションの対象となります。 Power_Ip_Init()はMC_RGMをクリアするので覚えておいてください。DES(値を保存した後)なので、電源モジュールを初期化する前にレジスタ値を取得するか、リセット理由を読み込むようにしてください。 回復モードは、閾値が>8の場合、回復モードがデフォルトで「8」に設定されているため、これに影響を与える可能性があります。sBAFはFRETではなくDRETにも干渉することがあります .「0」の場合、0xFに変わるのがわかります:   Julin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.png アプリケーションを継続的に実行すると、15回目の機能リセット後にアプリケーションやデバッガが停止し、期待される破壊的なリセットを観察できません。これがリセットシーケンス、SBAF復旧、またはデバッガに関連しているのか知りたいです。 デバッガを接続したままにしようとする代わりに、15回目の機能リセット後に接続を試みるか、UARTなどでリセット理由を印刷してみることはできますか? 2. すべてのSWT0機能リセットを破壊的なものにしたい はい、FRET=1であれば、すべての機能リセットで破壊リセットを発行するのに十分です。 追加のMC_RGMは不要です。 sBAF/リカバリーモードはこれに影響を与えないはずです。 はい、POWER モジュール -> 「モジュール設定」 -> 「McuResetConfig」 -> 「機能リセットエスカレーション閾値」で直接設定できます 3. SRAMデータは、機能リセットのたびに消去されます。 その通りです。SRAMは機能リセット後も保持されます。 S32K3は、派生モデルによって、スタンバイRAMとして16KB、32KB、または最大64KBを提供する場合があります。 スタンバイRAMを通じて変数を配置・使用する方法の例をいくつか見つけることができます: [RTD600 MCAL & IP]S32K3 低消費パワーマネージメントANおよびデモ S32K3の低消費電力管理ANとデモ 例:S32K312スタンバイモード、スタンバイRAMおよびPAD(DS3.5 RTD300を維持) スタンバイRAMがクリア/書き換えられる理由は、デフォルトのstartup_cm7.sによるものです。S32DSによって提供される機能は、リセット理由(POR、破壊的、機能的)に関係なく、SRAM全体を初期化します。機能リセットが発生した際に、割り当てられたスタンバイRAMをSRAMの初期化がスキップするように修正する必要があります。以下のコミュニティ投稿を参照してください: S32K311 スタンバイ RAM 保持。 4. 直接ソフトウェア破壊的リセット はい、MCUが機能的/破壊的リセットを発行されると、デバッグサブシステムとクロックはすべて再初期化されるため、デバッガは再びDAPアクセスを再交渉しなければなりません。 破壊的なリセットを行うと、一部のモジュールを除いて、チップの大部分がリセットされます。機能リセットを行うと、すべての通信ペリフェラルやコアがリセットされます。通信プロトコルの健全性は保証されておらず、リセット後に再初期化されることが前提とされています。 接続を維持しようとする代わりに、デバッガの「ターゲットにアタッチ」オプションを使うことができます: Julin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.png 5. Power_Ip_PerformReset() 前のブレークポイントの動作 おそらく再接続のウィンドウを見落としているだけです。for()ループを使う代わりに、フラグはデバッガで再接続した後に手動で変更する変数であるwhile(flag)を使い、「Expressions」タブから使うことができます。 6. Power IPの初期化とPower_Ip_SetMode() はい、Power APIを使用する前にPower_Ip_Init()を呼び出す必要があります。 そうすることをお勧めします。リセットはPower_Ip_PerformReset()を通じて行うことができますが、破壊的リセットか機能リセットのどちらかをMcuResetConfigコンテナ内で設定できます。代わりに、機能リセット用と破壊リセット用2つのパワーモードを宣言できます。次に、Power_Ip_SetMode(Functional_Reset) または Power_Ip_SetMode(Destructive_Reset) を呼び出します。 省略しても構いませんが、すべてのモジュールが正しくゲート化・設定されているか確認するためにPower_Ip_SetMode(RUN_MODE)を呼び出すと良いでしょう。もしプロジェクトに不要であれば省略しても構いません。 A6.2を参照してください。 簡単なテストを作成し、FRET=1を設定し、Power_Ip_SetMode( ) APIを通じて機能リセットを行うと報告FRE_RESET確認できました: Julin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.png よろしくお願いします、 ジュリアン Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention こんにちは、ジュリアンさん。 ご説明いただきありがとうございます。 S32K312で再度テストを行ったので、2つの点について明確にしておきたいと思います。完全なプロジェクトフォルダを添付しておきますので、設定を確認して動作を再現できます。 1. SWT0機能リセットエスカレーション 設定しました: FRET = 15U;DRET = 0U; そして、 125ミリ秒のタイムアウトを設定したSWT0を使用して、機能リセットを生成します。 機能リセットのたびに FREC が増加しているのが観察できます: SWT0 reset #1 -> FREC = 1 SWT0 reset #2 -> FREC = 2 ... SWT0 reset #14 -> FREC = 14 しかし、次のSWT0機能リセットが発生し、 FRET = 15の閾値に達したときに、期待される破壊的リセット状態を観察することができません。 DES[MC_RGM_FRE] = 1 また、15回目の機能リセット後もMCUは動作を続け、予想される破壊的なリセット動作は見られません。私のSRAMテストパーティションに保存されているSRAMデータも、そのままの状態を保っています。 以下の方法でリカバリ動作を無効にしました。 IP_DCM_GPR->DCMRWP1 |= (3 << 22); 添付のプロジェクトを確認して、もう少し詳しく教えていただけますか: 15回目のSWT0機能リセット後、 DES[MC_RGM_FRE] = 1が観測されないのはなぜですか? FRECがFRET = 15に達した後、MCUは確実に破壊的なリセットに入るべきでしょうか?破壊的なリセットが発生した場合、なぜテストパーティションにSRAMの内容が保持されるのでしょうか? 他にMC_RGM/SBAFの設定で見落としているものはありますか? 2. 機能リセットおよび破壊リセット後のSRAM保持 専用のSRAMパーティション/セクションを作成し、その領域にテストデータを保存しました。 SWT0機能リセットを繰り返してもSRAMの値が保持されることを確認しました。これは想定どおりです。 しかし、FRETエスカレーションによって破壊的なリセットが発生すると予想される15回目の機能リセット後でも、SRAMの値は依然として残っています。 また、直接的なソフトウェア破壊リセットも試しましたが、リセット後もSRAM値は保持されていました。 したがって、私の見解は以下のとおりです。 SWT0 functional reset ↓ SRAM value retained 15th functional reset / expected FRET escalation ↓ SRAM value still retained Direct software destructive reset ↓ SRAM value also retained このSRAMの挙動がS32K312上で予想されるものなのか、また私のSRAMテスト領域が破壊的なリセットを経ても保持されるメモリ領域にある可能性があるのか、教えていただけますか? リンカー構成、RTD構成、MC_RGM構成、SWT0構成、テストアプリケーションを含む S32K312プロジェクトフォルダ全体を添付していますので、実際のメモリ配置とリセット設定を確認できます。 再開まで今しばらくお待ちください。 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention こんにちは、 @Sharif417 さん。 1. SWT0機能リセットエスカレーション 1. 15回目のSWT0機能リセット後、DES[MC_RGM_FRE] = 1が観測されないのはなぜですか? 前述したように、Power_Ip_Init() APIはDESレジスタをクリアするため、リセット理由はPower_Ip_GetResetReason()を使用して読み取る必要があります。 2. FRECがFRET = 15に達した後、MCUは確実に破壊リセットに入るべきか?破壊的なリセットが発生した場合、なぜテストパーティションにSRAMの内容が保持されるのでしょうか? はい。FRECがFRTで設定された閾値に達している限り、MCUは破壊的なリセットを発行すべきです。破壊的なリセットが行われていないか、変数の位置が間違っているかのどちらかです。 3. 他にMC_RGM/SBAFの設定で不足しているものはありますか? いいえ。機能リセットエスカレーションの場合、FRETを設定するだけで十分です。 2. 機能リセットおよび破壊リセット後のSRAM保持 1. このSRAMの挙動がS32K312上で予想されるものか、またSRAMテスト領域が破壊的なリセットを経ても保持されるメモリ領域にある可能性があるのか、明確にしていただけますか? しかし、そうあるべきではありません。破壊的なリセットイベントの後、すべてのSRAMコンテンツは失われます。 直接的なソフトウェア破壊リセットをどのようにテストしているのか教えてもらえますか? プロジェクトで Power_Ip_PerformReset() API を使用している場合、それは破壊的ではなく機能的なリセットとして構成されています。 Julin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.png 実は、値を保存してUARTで共有してテストしました。FRDM-A-S32K312はSW2で機能リセットを発行し、FRETは15に設定され、15回のSW機能リセット後にMCU_MC_RGM_FRE_RESETが生成されるのが見えます。これはRTD 6.0.0で発生しています。以下のログをご覧ください。 [RESET] Reason : MCU_F_EXR_RESET (RGM_FES F_FR0) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 2 [RESET] Reason : MCU_SW_DEST_RESET (RGM_DES F_DR29) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 2 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 3 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 4 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 5 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 6 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 7 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 8 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 9 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 10 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 11 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 12 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 13 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 14 [RESET] Reason : MCU_MC_RGM_FRE_RESET (RGM_DES F_DR6) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 RTD 7.0.1では、あなたが言及したのと同じ挙動が見えます(FREが破壊リセットを主張しなかったり、デバッグャが切断されたりするなど): [RESET] Reason : MCU_SW_DEST_RESET (RGM_DES F_DR29) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_DEST_RESET (RGM_DES F_DR29) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 2 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 3 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 4 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 5 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 6 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 7 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 8 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 9 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 10 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 11 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 12 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 13 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 14 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 0 これにより、RTD 6.0.0とRTD 7.0.1の間にPower ドライバにいくつかの違いがあり、それがこれらの症状の原因になっているのではないかと考えています。これが設定の問題なのかバグなのか特定できていません。分析の時間をいただき、必要なら社内チームに連絡してください。 よろしくお願いします、 ジュリアン Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention こんにちは、ジュリアンさん。 ご説明いただきありがとうございます。 ご要望通り、現在使用している ソフトウェアの破壊リセットテストコード/プロジェクト を含むZIPファイルを添付しました。 FRET エスカレーションが RTD 6.0.0で正しく動作するとおっしゃっていましたが、テストで使った RTD 6.0.0の動作するコードやプロジェクト を共有していただけますか? あなたのRTD 6.0.0の動作コードを参考に、私のRTD 7.0.1プロジェクトと比較して、動作の違いを理解したいと考えています。 また、 RTD 6.0.0とRTD 7.0.1の間でパワードライバーに違いや問題がある可能性があるとおっしゃっていましたが、分析が終わったら RTD 7.0.1 の問題についての調査結果を教えていただけますか? 再開まで今しばらくお待ちください。 よろしくお願いします、 シャリフ Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention こんにちは、@Sharif417 さん。 Power_Ipドライバーのソースコードを調べたところ、Power_Ip_MC_RGM_GetResetReason()APIで機能リセットエスカレーションカウンタの修正が適用されているのが見えました。そこに3つ目の節が追加され、DESがビットを設定していてFRETレジスタが現在非ゼロを読み取っている場合にFESも入ります。 RTD 6.0.0: /* If the fields of Destructive Event Status Register (DES) are set then the status of FES register must be ignored */ if (((uint32)0U == ActiveValue) || (MCU_POWER_ON_RESET == ResetReason)) { ... } RTD 7.0.1: /* If the fields of Destructive Event Status Register (DES) are set then the status of FES register must be ignored */ /* If functional reset escalation to destructive reset is disabled, then the status of FES register must be ignored if the fields of Destructive Event Status Register (DES) other than DES[F_POR] are set. */ /* If functional reset escalation to destructive reset is enabled and if the fields of Destructive Event Status Register (DES), other than DES[F_POR], are set, then based on these fields user should check if the cause of the destructive reset was due to functional reset escalation or if it was triggered directly by a destructive reset source, in which case FES needs to be ignored */ if (((uint32)0U == ActiveValue) || (MCU_POWER_ON_RESET == ResetReason) || (((uint32)0U != DesResetStatus) && ((uint32)0U != Power_Ip_pxMC_RGM->FRET))) { ... } これがFESフラグが上書きされる理由です。私の理解が正しければ、ハードウェアは破壊的リセットを正しく実行しているにもかかわらず、リセットモジュールは代わりに機能的リセットを報告している。これは、15回目の機能リセット直後のIP_MC_RGM->DESレジスタを読むことで確認できます: Julin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.png 有効な方法は、3番目の節を変更して、MCU_MC_RGM_FRE_RESETイベントがすでに起こっているかどうかを確認することかもしれません。 /* ----------------------------------------------------------------------- * Enter the FES block if: * a) DES is empty (no destructive reset logged), OR * b) DES has only the Power-On Reset bit, OR * c) DES has bits set AND FRE escalation is configured (FRET != 0) * AND the DES reason is NOT already MCU_MC_RGM_FRE_RESET * ----------------------------------------------------------------------- */ if (((uint32)0U == ActiveValue) || (MCU_POWER_ON_RESET == ResetReason) || (((uint32)0U != DesResetStatus) && ((uint32)0U != Power_Ip_pxMC_RGM->FRET) && (MCU_MC_RGM_FRE_RESET != ResetReason))) RTDドライバの修正はサポートされていないことを覚えておいてください。正しい方法は、SWチームからの公式修正を待つことです。この件については社内チームに報告し、もしあれば彼らからのフィードバックも伝えます。この問題をご指摘いただきありがとうございます。 最後に、あなたのプロジェクトについてですが、Power_Ip_PerformReset()を通じてリセットを発行しているのが見えます。先ほども述べた通り、リセット設定内で「機能リセット」が設定されており、ソフトウェア破壊リセットを発行するには「破壊的リセット」に変更する必要があります: Julin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.png または、ModeSettingConf構造体を追加し、DEST_RESETを選択して、代わりにPower_Ip_SetMode()を呼び出します。 Julin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.png よろしくお願いします、 ジュリアン Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention こんにちは、ジュリアンさん。 あなたの提案に基づき、Power_Ip_GetResetReason()だけに頼るのではなく、MC_RGM DESレジスタとFESレジスタを直接読み取ることで追加のテストを実施しました。 このテストでは、リセットタイプをFRET = 15のソフトウェア機能リセットとして設定しました。ソフトウェアの機能リセットのたびに、FRECカウンターは増加します。15回目のソフトウェア機能リセット後、main()のClock_Ip_Init()の前にブレークポイントを置き、MC_RGMレジスタを直接読み込みました。 volatile uint32_t regValueDes = 0U;volatile uint32_t regValueFes = 0U; regValueDes = IP_MC_RGM->DES;regValueFes = IP_MC_RGM->FES; gVar = Power_Ip_GetResetReason(); 完全なテストコードは以下のとおりです。 int main(void) { volatile uint32_t regValueDes = 0U; volatile uint32_t regValueFes = 0U; regValueDes = IP_MC_RGM->DES; regValueFes = IP_MC_RGM->FES; gVar = Power_Ip_GetResetReason(); Clock_Ip_Init(&Clock_Ip_aClockConfig[0]); Siul2_Port_Ip_Init( NUM_OF_CONFIGURED_PINS_PortContainer_0_BOARD_InitPeripherals, g_pin_mux_000InitConfigArr_PortContainer_0_BOARD_InitPeripherals); Power_Ip_Init(&Power_Ip_HwIPsConfigPB); gVar = Power_Ip_GetResetReason(); /* Disable recovery mode */ IP_DCM_GPR->DCMRWP1 |= (3 << 22); for (count = 0; count < 10125000; count++); Power_Ip_PerformReset(&Power_Ip_HwIPsConfigPB); } 15回目の機能リセット後、Clock_Ip_Init()の前にIP_MC_RGM->DESを直接読み取ります。しかし、DES[MC_RGM_FRE] = 1 は観測されませんでした。DESの値は0のままですが、FESにはリセット状態(私のテストでは0x20000001)が格納されます。 この観察結果に基づくと、問題はPower_Ip_MC_RGM_GetResetReason()やリセット理由の報告だけに限定されない可能性があると考えられます。クロックと電源の初期化前にMC_RGM DESレジスタを直接読み取っているため、破壊的なエスカレーションが発生した場合はDES[MC_RGM_FRE]がFRETエスカレーションを示すと予想していました。 そこで、15回目の機能リセット後にMC_RGMハードウェアレベルでFRETのエスカレーション自体が起きているのか確認していただけますか?もしこの時点で破壊的なエスカレーションが予想されるなら、なぜIP_MC_RGM->DESが0のままなのか教えていただけますか? また、あなたが指摘したPower_Ip_MC_RGM_GetResetReason()の問題に加えて、FREC/FRETのエスカレーション機構自体に関連する追加のRTD 7.0.1の問題や設定があるかどうかも確認していただけますか? この問題の調査にサポートいただき、ありがとうございます。 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention こんにちは、 @Sharif417 さん。 破壊的なリセットは確かに起きていると信じています。以下のテスト手順に従ってください: FRET=1に設定し、機能リセットごとに機能リセットのエスカレーションが発生します。 2つの変数(1つはDESレジスタ用、もう1つはFESレジスタ用)と、変数を読み取る前にコアを停止するためのwhile()ループを宣言します。 int main(void) { volatile uint8_t debug = 1; while(debug); volatile uint32_t regValueDes = 0; volatile uint32_t regValueFes = 0; regValueDes = IP_MC_RGM -> DES; regValueFes = IP_MC_RGM -> FES; ... }​ コードでMCUをフラッシュした後、デバッグ変数を0に変更してプログラムが実行できるようにし、デバッガを切断します。 機能リセットを実行してください(あなたのプログラムや私が示した例を使ってください)。 「Attached to Running Target(走行中のターゲットにアタッチ)」を選択してMCUに接続します。 実行を一時停止し、デバッグ変数を0に設定し、DESおよびFES変数を読み取ります。 Julin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.png この方法では、機能リセットを生成し、接続した後、機能リセットエスカレーション手順に関連するDES[MC_RGM_FRE]ビットが見えます。 なぜDES->0を読んでいるのか分かりませんが、デバッガが接続されたままであれば、リセットシーケンスに干渉しリセットが発生するのではないかと思います。私が共有した手順でテストしてみて、DESが実際に設定されているかどうかを確認することをお勧めします。 状況を随時お知らせください。 よろしくお願いします、 ジュリアン Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention こんにちは、ジュリアンさん。 サポートありがとうございます。 FRET = 1 であなたの手順に従い、DES と FES を読み取る前に while(debug) ループを追加しました。 機能リセット後の破壊リセットのエスカレーションが、while(debug) ループで正しく動作することがわかりました。while(debug)ループがなければ、破壊的なリセットを観察することができませんでした。 「実行中のターゲットにアタッチ」機能を使わなくても動作することを確認しました。 この件を特定するのにご協力いただき、ありがとうございました。 よろしくお願いします、 シャリフ Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention こんにちは、 @Sharif417 さん。 あなたがこの行動を正しく観察できたことを嬉しく思います。 Power_Ip_GetResetReason() の問題については既に報告済みで、現在その件に関するフィードバックを待っています。内部チームから情報を共有したら追加情報を提供しますし、新しいケースやコミュニティ投稿を作成してフォローアップの依頼も可能です。 よろしくお願いします、 ジュリアン Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention こんにちは、ジュリアンさん。 アップデートのご報告と、 Power_Ip_GetResetReason()の問題を社内チームに報告していただき、ありがとうございます。さらなるフィードバックを待ちます。 よろしくお願いします、 シャリフ
查看全文
我正在寻找 AFT05MS004NT 在 30-45 MHz 频率范围内的阻抗。 我正在寻找阻抗 AFT05MS004NT1,30-45 MHz Z负载和Z源 请各位帮帮我 Re: I am looking for the impedance of AFT05MS004NT AT FREQ 30-45 MHZ 你好, 遗憾的是,我们没有 AFT05MS004NT 在 30–45 MHz 频率范围内的阻抗数据。 获取阻抗数据需要专用的特性分析过程,该过程必须针对每个感兴趣的频率分别进行。这个过程很耗时,通常侧重于设备最初被设计并预期运行的频率范围。评估其他频率通常需要设计和建造特定的测试夹具和匹配网络。 因此,对于标准特性范围之外的工作条件(例如不同的频率、功率级或电源电压),阻抗数据并不总是可用。 由此给您带来的不便,我们深表歉意,并感谢您的理解。 Re: I am looking for the impedance of AFT05MS004NT AT FREQ 30-45 MHZ 谢谢你的回答,但是有没有可能让这个部件的发射频率达到 30-45 MHz 呢? 请问如何使用矢量网络分析仪实时获取 Z 轴负载和 Z 轴源?
查看全文
S9KEAZN8 – 低電力モードへのエントリーコード例とスリープ時のPWM信号検出 私はS9KEAZN8を使用しています。低電力モードに入る方法を知りたいです。これを実現する方法を示すコード例を提供していただけませんか? また、MCUが低電力モードのときに、PWM信号の変化を検出する必要があります。この件を適切に処理するにはどうすればよいでしょうか? リファレンスマニュアルにはコード例は掲載されていません。サンプルコードやアドバイスがあれば大変ありがたいです。 ありがとうございます。 Re: S9KEAZN8 – Low power mode entry code example and PWM signal detection in sleep こんにちは@ssjj どのIDEを使用していますか?S32DSを使用している場合は、KEA128用のサンプルプロジェクトが利用可能です。これらの例は、若干の修正を加えることでKEA8にも適用できます。 低電力モードへの移行については、WFIの指示に従ってください。具体的な実装については、PMC_SetMode()などの関数を含むpmc.cファイルを参照してください。   他に質問があれば、遠慮なくご連絡ください。 BR アリス Re: S9KEAZN8 – Low power mode entry code example and PWM signal detection in sleep S9KEAZN8では、必要なクロック/電力設定を設定して低消費電力モードを設定し、適切なWFI(割り込み待機)命令を実行します。正確なモードとウェイクアップソースはS9KEAZN8電源管理モジュールによって異なります。PWM監視の場合、通常MCUは深眠状態でPWMの変化を連続的に測定できないため、割り込み対応タイマー/入力キャプチャチャネルか外部割り込みをウェイクアップソースとして設定します。エッジが検出されたらMCUを起動し、タイマー/入力キャプチャ**ペリフェラル**を使ってPWMの周期/デューティサイクルを測定します。低消費電力モードでは一部のペリフェラルやクロックが無効になっているので、デバイスの低消費電力・クロック制限をよく確認してください。
查看全文
学习 我是NXP S32K144的新手。对于初学者来说,推荐的开发环境是什么?我应该首先学习什么? Re: LEARNING 你好@JASAMANG , 对于初学者,我建议使用S32 Design Studio for S32 Platform以及 S32K144 评估板。 除了 IDE 之外,请安装S32K1 实时驱动程序 (RTD)软件包。对于当前的开发流程,推荐的组合是S32 Design Studio v3.6.0 与 S32K1 RTD 3.0.0 。可以通过“帮助”>“S32DS 扩展和更新”安装 RTD 软件包。 我建议按照以下学习路径进行学习: 导入并运行现有的 S32K144 RTD 示例,例如闪烁 LED 或 GPIO 示例。 学习项目的基本结构、构建过程、烧录和调试。 熟悉 S32 配置工具,特别是引脚、时钟和外设配置。 继续讲解 GPIO、中断、定时器、PWM 和 ADC。 一旦这些基本概念清晰明了,就可以开始学习电机控制示例和工具,例如 FreeMASTER 和 MCAT。 通常来说,从现有示例入手比从头开始创建完整的应用程序要容易得多。 有关 RTD 安装指导,请参阅S32K1 RTD 离线安装指南。虽然这篇文章演示的是较旧的 S32DS/RTD 组合,但它解释了软件包依赖关系和一般的离线安装流程。务必在下载的 RTD 版本的发行说明中核实所需的 S32DS 版本和依赖软件包。 您可能也会发现以下讨论很有用:将 SDK/RTD 安装到 S32 Design Studio 中。它解释了传统 SDK 和 RTD 之间的区别,并提供了 AUTOSAR 和非 AUTOSAR LED 闪烁示例的链接。 您还可以在S32K 知识库中找到有用的示例和技术文章。 如果遇到问题,我建议先在S32K 社区论坛上搜索一下。许多常见问题和疑虑已经在那里讨论并得到了解答。 另外,如果您遇到具体问题,请另开新帖。这有助于保持讨论的清晰性,也使其他用户更容易找到相关信息。   我们会在最后一条回复发出后的七天内持续监测帖子。此后,我们只会收到更新订阅邮件,偶尔可能会错过这些邮件。此后如有任何相关问题,请另开新帖并引用原帖。   如果某个回复解答了您的问题,请点击“接受为解决方案”。如有任何相关问题,请另开新帖并引用原帖。   顺祝商祺! 帕维尔 Re: LEARNING 感谢您提供信息 🙏 Re: LEARNING 我非常感谢您提供的信息。 🙏 
查看全文
Regarding Removes the bond with a device Hello, I'm trying to implement BLE communication using MCUXpresso SDK version 26.03. I have a question about the API function Gap_RemoveBond. The remark states, "This API requires that there are no active connections at call time." 1. Does this mean it can only be used when there are no connected devices? 2. If Gap_RemoveBond cannot be used to remove a bond while an active connection exists, is there a way to remove bonding information while an active connection is active? Additional information regarding the question Suppose there are three devices: ・Peripheral device ・Central device A ・Central device B takuya08_0-1788256233203.pngtakuya08_0-1788256233203.pngtakuya08_0-1788256233203.pngtakuya08_0-1788256233203.pngtakuya08_0-1788256233203.png The Peripheral device is already bonded with both Central A and Central B. When the Peripheral is actively connected to both Central A and Central B: takuya08_1-1788256275044.pngtakuya08_1-1788256275044.pngtakuya08_1-1788256275044.pngtakuya08_1-1788256275044.pngtakuya08_1-1788256275044.png Based on the remark, I understand that the Peripheral cannot delete the bonding information for Central A and B while they are connected. Is there any way to delete bonding information during an active connection? When the Peripheral is actively connected only to Central A: takuya08_2-1788256364083.pngtakuya08_2-1788256364083.pngtakuya08_2-1788256364083.pngtakuya08_2-1788256364083.pngtakuya08_2-1788256364083.png Is it impossible for the Peripheral to delete the bonding information for both Central A and Central B? Or is it possible to delete only Central B's bonding information? When the Peripheral is not connected to any device: takuya08_3-1788256474725.pngtakuya08_3-1788256474725.pngtakuya08_3-1788256474725.pngtakuya08_3-1788256474725.pngtakuya08_3-1788256474725.png Based on the remark, I understand that the Peripheral can delete the bonding information for both Central A and Central B in this case. Thank you for your help. Re: Regarding Removes the bond with a device @sofiaurueta  Thank you for your response. Based on your answer, I understand that bonding information cannot be deleted if even a single device is connected.  However, I would like to double-check to be sure.  2-1788256364083.png2-1788256364083.png2-1788256364083.png2-1788256364083.png If the peripheral has bond information stored for two devices, Central A and Central B, and it is currently connected to Central A, which of the following behaviors occurs? 1. The bond information for the unconnected Central B can be deleted. 2. Neither of the two bond information records can be deleted. Re: Regarding Removes the bond with a device Hello, hope you are doing well. Gap_RemoveBond() can only be called when there are no active BLE connections. The API documentation explicitly requires that all connections be disconnected before bond information is removed. The same restriction applies to Gap_RemoveAllBonds(). There is currently no API in the MCUXpresso SDK BLE Host Stack that supports deleting NVM bond data while any connection is active. The recommended flow for removing a bond during an active use case is as follows: Call Gap_Disconnect(deviceId) for the relevant connected peers, wait for the gConnEvtDisconnected_c connection event confirming disconnection, then call Gap_RemoveBond(nvmIndex). Best regards, Sofia. Re: Regarding Removes the bond with a device Hello,   @sofiaurueta  We are currently considering removing the bonding information. Could you please provide an answer? Thank you for your help.
查看全文
仅可使用钥匙扣/智能卡登录 我在一家制造公司工作,我们正在考虑在车间配备个人电脑,以便员工能够查看零件图纸、确认任务完成情况等等。由于我们希望尽可能减少员工的痛苦,但又要记录谁签署了任务,因此我们正在寻找最佳方式,让员工使用他们已有的门禁卡来开门和打卡。如果这不可行,我们当然愿意考虑其他方案,让员工可以使用某种物理令牌登录,而无需接触键盘或鼠标,更不用说记住用户名和密码了。我研究过智能卡,但它们似乎需要输入密码,而我们希望尽可能避免使用密码。我们了解其中固有的网络安全风险,这些设备将被锁定,只能执行特定任务,而不能访问网络的其他部分。 移动设备上的智能卡 Re: Login with keyfob/smartcard only 我建议使用 MIFARE DESFire EV3。 以下是网页链接: MIFARE DESFire EV3 | 安全免接触式集成电路 | 恩智浦半导体
查看全文
关于移除与设备的连接 你好, 我正在尝试使用 MCUXpresso SDK 版本 26.03 实现 BLE 通信。 我有一个关于 API 函数 Gap_RemoveBond 的问题。 该说明指出:“此 API 要求在调用时不能有任何活动连接。” 1.这是否意味着它只能在没有连接设备的情况下使用? 2. 如果在存在活动连接的情况下不能使用 Gap_RemoveBond 删除绑定,那么在活动连接处于活动状态时,是否有办法删除绑定信息? 关于此问题的更多信息 假设有三种设备: ・外围设备 ・中央设备A ・中央设备B takuya08_0-1788256233203.pngtakuya08_0-1788256233203.pngtakuya08_0-1788256233203.pngtakuya08_0-1788256233203.pngtakuya08_0-1788256233203.png 外围设备已与中央 A 和中央 B 连接。 当外围设备同时与中央设备 A 和中央设备 B 连接时: takuya08_1-1788256275044.pngtakuya08_1-1788256275044.pngtakuya08_1-1788256275044.pngtakuya08_1-1788256275044.pngtakuya08_1-1788256275044.png 根据上述说明,我理解外围设备在中心 A 和中心 B 连接时无法删除它们的绑定信息。 在连接进行中,有没有办法删除绑定信息? 当外围设备仅与中央设备 A 连接时: takuya08_2-1788256364083.pngtakuya08_2-1788256364083.pngtakuya08_2-1788256364083.pngtakuya08_2-1788256364083.pngtakuya08_2-1788256364083.png 外围设备是否有可能删除中央 A 和中央 B 的绑定信息? 或者是否可以只删除中央 B 的绑定信息? 当外围设备未连接到任何设备时: takuya08_3-1788256474725.pngtakuya08_3-1788256474725.pngtakuya08_3-1788256474725.pngtakuya08_3-1788256474725.pngtakuya08_3-1788256474725.png 根据这句话,我理解在这种情况下,外围设备可以删除中央 A 和中央 B 的绑定信息。 感谢您的帮助。 Re: Regarding Removes the bond with a device @sofiaurueta 感谢您的回复。 根据您的回答,我理解即使只连接了一个设备,绑定信息也无法删除。 不过,为了确保万无一失,我想再确认一下。 2-1788256364083.png2-1788256364083.png2-1788256364083.png2-1788256364083.png 如果外围设备存储了两个设备(中央 A 和中央 B)的绑定信息,并且当前连接到中央 A,则会发生下列哪种行为? 1.可以删除未连接的中央 B 的债券信息。 2. 这两条债券信息记录均不可删除。 Re: Regarding Removes the bond with a device 你好,希望你一切都好。 只有当没有活动的 BLE 连接时才能调用Gap_RemoveBond() 。API 文档明确要求在删除债券信息之前必须断开所有连接。同样的限制也适用于 Gap_RemoveAllBonds()。 目前 MCUXpresso SDK BLE 主机堆栈中没有 API 支持在任何连接处于活动状态时删除 NVM 绑定数据。 在实际使用过程中,移除绑定的推荐流程如下: 对相关的已连接对等方调用 Gap_Disconnect(deviceId),等待确认断开连接的 gConnEvtDisconnected_c 连接事件,然后调用 Gap_RemoveBond(nvmIndex)。 此致, 索菲亚。 Re: Regarding Removes the bond with a device 你好, @sofiaurueta 我们目前正在考虑删除债券信息。 请问您能提供答案吗? 感谢您的帮助。
查看全文
学ぶ 私はNXP S32K144を使い始めたばかりです。初心者におすすめの開発環境は何ですか?また、最初に何を学ぶべきでしょうか? Re: LEARNING こんにちは、 @JASAMANG さん、 初心者には、 S32 Design Studio for S32 Platform とS32K144評価ボードを組み合わせて使うことをおすすめします。 IDEに加えて、 S32K1リアルタイム・ドライバ (RTD) パッケージをインストールしてください。現在の開発フローでは、推奨される組み合わせは S32 Design Studio v3.6.0とS32K1 RTD 3.0.0です。RTDパッケージはHelp > S32DS拡張機能とアップデートを通じてインストール可能です。 以下の学習経路をたどることをお勧めします。 既存のS32K144 RTDサンプル(LED点滅サンプルやGPIOサンプルなど)をインポートして実行します。 基本的なプロジェクト構造、ビルドプロセス、フラッシュ書き込み、デバッグについて学びます。 S32の設定ツール、特にピン、クロック、ペリフェラルの設定に慣れておく。 GPIO、割り込み、タイマー、PWM、ADCについて引き続き説明します。 これらの基礎が明らかになったら、FreeMASTERやMCATなどのモータ制御の例やツールに進みましょう。 既存の例から始める方が、最初からアプリケーション全体を作るよりも一般的に簡単です。 RTDの設置手順については、 S32K1 RTDオフライン設置ガイドを参照してください。この記事は古いS32DS/RTDの組み合わせを示しつつ、パッケージ依存関係や一般的なオフラインインストールフローについて説明しています。ダウンロードするRTDバージョンのリリースノートで、必要なS32DSバージョンおよび依存パッケージを必ず確認してください。 この議論も役立つかもしれません: S32 Design StudioにSDK/RTDをインストールする。レガシーSDKとRTDの違いを説明し、AUTOSARおよび非AUTOSARの点滅LED例へのリンクを提供しています S32Kナレッジベースには、役立つ事例や技術記事も掲載されています。 問題が発生した場合は、まずS32Kコミュニティフォーラムを検索することをお勧めします。多くのよくある質問や問題点は、すでにそこで議論され、回答されています。 また、特定の問題に直面した場合は 専用Thread を作成してください。これにより議論が明確になり、他のユーザーが関連情報を見つけやすくなります。   最後の返信から7日間Threadを積極的に監視しています。その後は、更新のための購読メールのみを受け取り、それらは時折見逃されることもあります。この期間以降に関連する質問があれば、新しいThreadを作成し、元のThreadを参照してください。   回答がご質問への回答となっている場合は、 「解決策として承認」をクリックしてください。関連する質問がある場合は、新しいThreadを作成し、元のThreadを参照してください。   よろしくお願いいたします。 パベル Re: LEARNING 情報提供ありがとうございます。 🙏  Re: LEARNING 情報提供ありがとうございます 🙏
查看全文
S32K312:SWT0 功能 RESET 升级、破坏性 RESET 状态和 SRAM 保持 您好,NXP团队, 我正在使用 S32 Design Studio 和 AUTOSAR RTD 7.0.1 / AUTOSAR 4.9 开发 S32K312 Cortex-M7。 我目前正在测试 MC_RGM 复位行为,特别是 SWT0 功能复位、功能复位升级、破坏性复位、SRAM 保持、SBAF/恢复行为以及电源 IP 复位 API。 1. SWT0 功能重置升级 我使用 SWT0 超时来生成功能性重置。 我的 MC_RGM 配置如下: MC_RGM_FRET_FRET((uint32)15U), MC_RGM_DRET_DRET((uint32)0U) 我观察到功能 RESET 计数器不断增加: SWT0 功能复位 #1 -> FREC = 1 SWT0 功能复位 #2 -> FREC = 2 ... SWT0 功能复位 #14 -> FREC = 14 下一次 SWT0 重置后,FREC 被清除/重置,但我没有观察到预期的结果: DES[MC_RGM_FRE] = 1 我的问题是: SWT0_RST 是否参与 S32K312 上的 MC_RGM 功能复位升级计数器 (FREC)? 当 FREC 达到 FRET = 15 时,是否应该生成 MC_RGM_FRE 并设置 DES[MC_RGM_FRE]? 升级后,FES、DES、FREC、FRET、Power_Ip_GetResetReason() 的确切值应该是什么? SWT0参与FRET升级是否需要任何额外的配置? SBAF/恢复处理是否会干扰FRET增强? 是否存在与 SWT0/FRET 升级相关的已知勘误或已知的 S32K312 行为? 当我连续运行该应用程序时,在第 15 次功能性 RESET 后,应用程序/调试器停止运行,而不是让我观察到预期的破坏性 RESET。我想知道这是否与复位序列、SBAF 恢复或调试器有关。 2.我希望每次 SWT0 功能重置都具有破坏性。 为了测试目的,我还想实现以下目标: SWT0 超时 ↓ 功能复位 ↓ 立即进行破坏性重置 而不是等待 15 次功能性 RESET。 能否通过配置来实现: 共振频率 = 1U; 具体来说: FRET = 1 是否会导致第一次符合条件的 SWT0 功能 RESET 升级为破坏性 RESET? 是否需要进行任何额外的 MC_RGM 配置? SWT0 是否一定符合此次升级的资格要求? SBAF/恢复行为会影响这一点吗? RTD 7.0.1 配置是否直接支持此功能? 3.每次功能 RESET 后,SRAM 数据都会被清除。 根据我对 S32K3xx 参考手册的理解,SRAM/系统存储器在功能复位后应该能够保留。 我创建了一个SRAM测试变量: #define SRAM_TEST_ADDR ((volatile uint32_t *)0x204007d4U) 并用它来验证功能 RESET 后的数据保留情况。 但是,我观察到在功能复位后,SRAM 数据被清除/重写为零。 我的问题是: SRAM 在功能复位期间是否由硬件保留,但之后被软件覆盖? S32K312 中哪些 SRAM 区域能够保证在功能 RESET 后保留其内容? 将变量放入 SRAM 中,使其内容在功能 RESET 后得以保留的推荐方法是什么? 我应该使用专用的 .noinit 吗?或者保留SRAM部分? 保持数据是否需要特定的 MC_RGM/SRAM 配置? 对于 RTD 7.0.1 版本,在功能 RESET 后保留应用程序数据的推荐方法是什么? 4. 直接软件破坏性 RESET 我还在测试使用 Power IP 进行直接软件破坏性重置: Power_Ip_Init(&Power_Ip_HwIPsConfigPB); gVar= Power_Ip_GetResetReason(); for (count = 0; count < 10125000; count++); Power_Ip_PerformReset(&Power_Ip_HwIPsConfigPB); 我当前的 MC_RGM 配置包含: static const Power_Ip_MC_RGM_ConfigType Power_Ip_MC_RGM_ConfigPB = { (MCU_DEST_RESET), ... MC_RGM_FRET_FRET((uint32)15U), MC_RGM_DRET_DRET((uint32)0U) }; 破坏性重置发生,但调试器反复失去通信并重新建立通信。 我看到类似这样的信息: 信息:DAP IDCODE = 0x6BA02477 信息:DAP 已成功启动。DP CTRL/STAT = 0xF0000000 重复多次,随后是: 已收到中断命令。停止执行。 我想了解: 在破坏性 RESET 过程中,DAP 是否会反复重新连接? 在破坏性重置序列中,Cortex-M7 究竟发生了什么? 破坏性 RESET 后,CPU 何时才能再次可用? 调试单个软件破坏性重置的推荐方法是什么? 5. Power_Ip_PerformReset() 之前的断点行为 我无法可靠地在以下位置立即触发断点: Power_Ip_PerformReset(&Power_Ip_HwIPsConfigPB); 我在 API 调用前添加了一个延迟,希望调试器有足够的时间获取访问权限。 有时只有在我手动暂停目标程序并恢复执行后,才能到达断点。 我想了解: 为什么即使 RESET API 之前有延迟,调试器仍然会错过断点? 这是否与目标设备反复重置以及调试器通过 DAP 重新连接有关? 是否有推荐的方法可以在破坏性 RESET 之前或之后立即捕获 CPU 状态? RTD DISABLE_DEBUGGER_TRAP 选项与此行为有关吗? 6.电源 IP 初始化和 Power_Ip_SetMode() 我的RTD产品提供: void Power_Ip_Init( const Power_Ip_HwIPsConfigType *HwIPsConfigPtr); void Power_Ip_SetMode(const Power_Ip_ModeConfigType *ModeConfigPtr); void Power_Ip_PerformReset( const Power_Ip_HwIPsConfigType *HwIPsConfigPtr ); Power_Ip_ResetType Power_Ip_GetResetReason(void); Power_Ip_RawResetType Power_Ip_GetResetRawValue(void); 我目前使用: Power_Ip_Init(&Power_Ip_HwIPsConfigPB); 和: gVar = Power_Ip_GetResetReason(); 我的模式配置为 POWER_IP_RUN_MODE。 我想澄清以下问题: 在使用 Power IP 重置 API 之前,Power_Ip_Init(&Power_Ip_HwIPsConfigPB) 是否是正确的初始化方法? 软件功能/破坏性RESET测试是否需要 Power_Ip_SetMode() 函数? 由于我选择的模式是 POWER_IP_RUN_MODE,那么对于此 RESET 测试,是否可以省略 Power_Ip_SetMode()? 如何使用 RTD 7.0.1 配置单独的软件功能RESET和软件破坏性RESET配置? 环境 MCU:S32K312 核心:Cortex-M7 S32DS:S32 设计工作室 AUTOSAR:4.9 RTD:7.0.1 RESET 源:SWT0 格子:15 DRET:0 我可以提供完整的测试应用程序 Power_Ip_PBcfg.c,链接器配置、MC_RGM 寄存器捕获和调试器日志(如有需要)。 谢谢! Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention 你好@Sharif417 , 1. SWT0 功能 RESET 升级 SWT0_RST 参与 S32K312 的 FREC,当 FREC 达到 15 时,DES[MC_RGM_FRE] 将被设置,您可以通过调用 Power_Ip_GetResetReason() 并返回“MCU_MC_RGM_FRE_RESET”来读取该值。 所有未被降级(通过 MCRGM.FERD)的功能复位源均符合递增 FREC 的条件。 请注意,Power_Ip_Init() 会清除 MC_RGM.DES(在保存其值之后),因此请尝试在初始化电源模块之前获取寄存器值,或者直接读取复位原因。 如果阈值大于 8,则恢复模式可能会对此产生影响,因为恢复模式默认设置为“8”。sBAF 也可能干扰DRET,而不是 FRET 。您可以看到,如果阈值为“0”,则会变为 0xF: Julin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.png 当我连续运行应用程序时,在第 15 次功能性 RESET 后,应用程序/调试器会停止运行,而不是让我观察到预期的破坏性 RESET。我想知道这是否与 RESET 顺序、SBAF 恢复或调试器有关。 与其尝试保持调试器连接,不如尝试在第 15 次功能 RESET 后再连接,或者尝试通过 UART 或类似方式打印 RESET 原因? 2. 我希望每次 SWT0 功能重置都具有破坏性。 是的,FRET=1 足以使每次功能性 RESET都发出破坏性 RESET。 无需额外添加 MC_RGM。 sBAF/恢复模式不应对此产生影响。 是的,您可以直接在 POWER 模块-> “模块配置” -> “MCU 复位配置” -> “功能复位升级阈值”中进行配置。 3. 每次功能RESET后,SRAM 数据都会被清除。 正确,功能复位后 SRAM 数据会被保留。 根据衍生型号的不同,S32K3 可提供 16KB、32KB 或高达 64KB 的待机 RAM。 您可以找到一些关于如何通过待机 RAM 放置和使用变量的示例: [RTD600 MCAL & IP] S32K3 低功耗管理 AN 和演示 S32K3 低功耗管理 AN 和演示 例如 S32K312 待机模式和待机 RAM 和 PAD 保持 DS3.5 RTD300 待机内存被清除/重写的原因是默认的 startup_cm7.s 文件。S32DS 提供的复位功能会初始化所有 SRAM,无论复位原因(POR、破坏性复位、功能性复位)如何。您必须对其进行修改,以便在发出功能 RESET 时,SRAM 初始化跳过已分配的备用 RAM。请参考以下社区帖子: S32K311 待机内存保留。 4. 直接软件破坏性RESET 是的,当 MCU 被发出功能性/破坏性复位指令时,调试子系统和时钟都会被重新初始化,这意味着调试器必须再次重新协商 DAP 访问权限。 破坏性复位会导致芯片的大部分部件(除少数模块外)复位。功能复位会导致所有通信外设和内核复位。通信协议的有效性无法保证,重置后假定它们会被重新初始化。 与其尝试保持连接,不如使用调试器的“附加到目标”选项: Julin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.png 5. Power_Ip_PerformReset() 之前的断点行为 很可能你只是错过了重新连接的窗口期。你可以不用 for() 循环,而是使用 while(flag),其中flag是一个变量,你需要在重新连接调试器后,通过“表达式”选项卡手动更改它。 6. 电源 IP 初始化和 Power_Ip_SetMode() 是的,在使用电源 API 之前必须调用 Power_Ip_Init()。 我建议这样做。您可以通过 Power_Ip_PerformReset() 执行 RESET,但是您只能在 McuResetConfig 容器中配置破坏性 RESET 或功能性 RESET。您可以声明两种电源模式:一种用于功能性复位,一种用于破坏性复位。然后只需调用 Power_Ip_SetMode(Functional_Reset) 或 Power_Ip_SetMode(Destructive_Reset)。 可以省略,但是,为了确保每个模块都已正确设置和配置,您应该调用 Power_Ip_SetMode(RUN_MODE)。如果你的项目不需要这一步,你可以省略它。 请参阅 A6.2。 我做了一个简单的测试,在设置 FRET=1 并通过 Power_Ip_SetMode() API 执行功能性复位后,可以看到报告了 FRE_RESET: Julin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.png 此致, 朱利安 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention 你好@Sharif417 , 1. SWT0 功能 RESET 升级 1. 为什么在第 15 次 SWT0 功能 RESET 后,我没有观察到 DES[MC_RGM_FRE] = 1? 正如我之前提到的,Power_Ip_Init() API 会清除 DES 寄存器,这意味着你应该通过Power_Ip_GetResetReason() 来读取复位原因。 2. 当 FREC 达到 FRET = 15 时,MCU 是否必须进入破坏性 RESET?如果发生破坏性重置,为什么我的测试分区中的 SRAM 内容会被保留? 是的。只要 FREC 达到 FRET 中配置的阈值,MCU 就应该发出破坏性 RESET。要么没有发生破坏性重置,要么变量放置错误。 3. 我是否遗漏了其他 MC_RGM/SBAF 配置? 不。对于功能复位升级,只需设置 FRET 即可。 2. 功能RESET和破坏性RESET后的 SRAM 数据保持 1. 请问这种 SRAM 行为在 S32K312 上是否正常?我的 SRAM 测试区域是否可能位于即使在破坏性 RESET 后仍能保留的存储区域中? 不应该出现这种情况。发生破坏性 RESET 事件后,SRAM 中的所有内容都将丢失。 能否详细说明一下您是如何测试直接软件破坏性重置的? 从你的项目中来看,如果你使用的是 Power_Ip_PerformReset() API,它配置为功能性复位,而不是破坏性复位。 Julin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.png 实际上,我通过保存这些值并通过 UART 共享它们来测试这一点,其中 FRDM-A-S32K312 通过 SW2 发出功能复位,FRET 设置为 15,在 15 次 SW 功能复位后,我可以看到 MCU_MC_RGM_FRE_RESET 被生成。这是在RTD 6.0.0版本中出现的问题,请查看以下日志: [RESET] Reason : MCU_F_EXR_RESET (RGM_FES F_FR0) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 2 [RESET] Reason : MCU_SW_DEST_RESET (RGM_DES F_DR29) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 2 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 3 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 4 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 5 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 6 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 7 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 8 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 9 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 10 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 11 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 12 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 13 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 14 [RESET] Reason : MCU_MC_RGM_FRE_RESET (RGM_DES F_DR6) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 在 RTD 7.0.1 中,我观察到了您提到的同样现象(从 FRE 未发出破坏性复位信号,到调试器断开连接): [RESET] Reason : MCU_SW_DEST_RESET (RGM_DES F_DR29) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_DEST_RESET (RGM_DES F_DR29) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 2 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 3 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 4 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 5 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 6 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 7 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 8 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 9 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 10 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 11 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 12 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 13 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 14 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 0 这让我相信 RTD 6.0.0 和 RTD 7.0.1 的功率驱动器之间存在一些差异,从而导致了这些症状。我目前还无法确定这是配置问题还是程序错误,请给我一些时间进行分析,如有必要,我会联系内部团队。 此致, 朱利安 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention 你好,朱利安, 谢谢你的解释。 我已在我的 S32K312 上重复了测试,并想澄清两点观察结果。我附上了完整的项目文件夹,以便您查看配置并重现该问题。 1. SWT0 功能 RESET 升级 我已配置: FRET = 15U;DRET = 0U; 使用SWT0 和 125 毫秒超时来生成功能性 RESET。 我可以观察到每次功能重置后FREC都会增加: SWT0 reset #1 -> FREC = 1 SWT0 reset #2 -> FREC = 2 ... SWT0 reset #14 -> FREC = 14 然而,当下一次 SWT0 功能 RESET 发生且FRET = 15阈值达到时,我无法观察到预期的破坏性 RESET 状态: DES[MC_RGM_FRE] = 1 此外,在第 15 次功能 RESET 后,MCU 继续运行,我没有观察到预期的破坏性 RESET 行为。我的 SRAM 测试分区中存储的 SRAM 数据也完好无损。 我已使用以下命令禁用恢复行为: IP_DCM_GPR->DCMRWP1 |= (3 << 22); 请您审阅一下我附上的项目文件并提出一些疑问: 为什么在第 15 次 SWT0 功能 RESET 后,我没有观察到DES[MC_RGM_FRE] = 1 ? 当FREC达到FRET = 15 时,MCU 是否必须进入破坏性 RESET?如果发生破坏性重置,为什么我的测试分区中的 SRAM 内容会被保留? 我是否遗漏了其他 MC_RGM/SBAF 配置? 2. 功能RESET和破坏性RESET后的 SRAM 数据保持 我创建了一个专用的 SRAM 分区/区域,并将测试数据存储在该区域中。 我已经确认,在多次SWT0 功能 RESET后,SRAM 值得以保留,这是预期的结果。 然而,即使在第 15 次功能 RESET 之后(我预期 FRET 升级会产生破坏性 RESET),SRAM 值仍然保持不变。 我还测试了直接软件破坏性重置,重置后 SRAM 值仍然保留。 因此,我的观察结果是: SWT0 functional reset ↓ SRAM value retained 15th functional reset / expected FRET escalation ↓ SRAM value still retained Direct software destructive reset ↓ SRAM value also retained 请问这种 SRAM 行为在 S32K312 上是否正常?我的 SRAM 测试区域是否可能位于即使经过破坏性 RESET 也会保留的存储区域中? 我附上了完整的 S32K312 项目文件夹,包括链接器配置、RTD 配置、MC_RGM 配置、SWT0 配置和测试应用程序,以便您可以查看实际的存储器放置和复位配置。 感谢您的支持。 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention 你好,朱利安, 谢谢你的解释。 按照要求,我已附上包含我目前正在使用的软件破坏性重置测试代码/项目的ZIP 文件。 既然您提到 FRET 升级在RTD 6.0.0中运行正常,能否请您分享一下您用于测试的RTD 6.0.0 代码/项目? 我想使用您的 RTD 6.0.0 工作代码作为参考,并将其与我的 RTD 7.0.1 项目进行比较,以了解行为上的差异。 另外,您提到您怀疑RTD 6.0.0 和 RTD 7.0.1 的电源驱动程序可能存在差异或问题,请您在完成分析后告知我您关于RTD 7.0.1 问题的发现? 感谢您的支持。 此致, 谢里夫 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention 你好@Sharif417 , 在查看了 Power_Ip 驱动程序的源代码后,我发现 Power_Ip_MC_RGM_GetResetReason() API 中应用了功能复位升级计数器的修复程序,其中添加了第三个子句,如果 DES 有位设置且 FRET 寄存器当前读取非零,则也会进入 FES。 RTD 6.0.0: /* If the fields of Destructive Event Status Register (DES) are set then the status of FES register must be ignored */ if (((uint32)0U == ActiveValue) || (MCU_POWER_ON_RESET == ResetReason)) { ... } RTD 7.0.1: /* If the fields of Destructive Event Status Register (DES) are set then the status of FES register must be ignored */ /* If functional reset escalation to destructive reset is disabled, then the status of FES register must be ignored if the fields of Destructive Event Status Register (DES) other than DES[F_POR] are set. */ /* If functional reset escalation to destructive reset is enabled and if the fields of Destructive Event Status Register (DES), other than DES[F_POR], are set, then based on these fields user should check if the cause of the destructive reset was due to functional reset escalation or if it was triggered directly by a destructive reset source, in which case FES needs to be ignored */ if (((uint32)0U == ActiveValue) || (MCU_POWER_ON_RESET == ResetReason) || (((uint32)0U != DesResetStatus) && ((uint32)0U != Power_Ip_pxMC_RGM->FRET))) { ... } 这就是 FES 标志被覆盖的原因。如果我理解正确,硬件可以正确发出破坏性 RESET,但是 RESET 模块却报告了功能性 RESET。您可以通过在第 15 次功能 RESET 后直接读取 IP_MC_RGM->DES 寄存器来确认这一点: Julin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.png 我认为一个可行的办法是修改第三条语句,检查 MCU_MC_RGM_FRE_RESET 事件是否已经发生: /* ----------------------------------------------------------------------- * Enter the FES block if: * a) DES is empty (no destructive reset logged), OR * b) DES has only the Power-On Reset bit, OR * c) DES has bits set AND FRE escalation is configured (FRET != 0) * AND the DES reason is NOT already MCU_MC_RGM_FRE_RESET * ----------------------------------------------------------------------- */ if (((uint32)0U == ActiveValue) || (MCU_POWER_ON_RESET == ResetReason) || (((uint32)0U != DesResetStatus) && ((uint32)0U != Power_Ip_pxMC_RGM->FRET) && (MCU_MC_RGM_FRE_RESET != ResetReason))) 请注意,修改 RTD 驱动程序不受支持,正确的做法是等待软件团队发布官方修复程序。我会将此行为报告给内部团队,并提供他们的反馈意见(如有)。感谢您指出这个问题。 最后,关于您的项目,我看到您是通过Power_Ip_PerformReset() 函数执行 RESET 的。正如我之前提到的,您在复位配置中配置了“功能复位”,您必须将其更改为“破坏性复位”才能执行软件破坏性复位: Julin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.png 或者添加一个 ModeSettingConf 结构,选择 DEST_RESET,然后调用 Power_Ip_SetMode() 函数: Julin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.png 此致, 朱利安 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention 你好,朱利安, 根据您的建议,我进行了额外的测试,直接读取 MC_RGM DES 和 FES 寄存器,而不是仅仅依赖于 Power_Ip_GetResetReason()。 在这个测试中,我将复位类型配置为软件功能复位,FRET = 15。每次软件功能 RESET 后,FREC 计数器都会递增。在第 15 次软件功能 RESET 后,我在 main() 函数的 Clock_Ip_Init() 函数之前设置了一个断点,并直接读取了 MC_RGM 寄存器: volatile uint32_t regValueDes = 0U;volatile uint32_t regValueFes = 0U; regValueDes = IP_MC_RGM->DES;regValueFes = IP_MC_RGM->FES; gVar = Power_Ip_GetResetReason(); 完整的测试代码如下: int main(void) { volatile uint32_t regValueDes = 0U; volatile uint32_t regValueFes = 0U; regValueDes = IP_MC_RGM->DES; regValueFes = IP_MC_RGM->FES; gVar = Power_Ip_GetResetReason(); Clock_Ip_Init(&Clock_Ip_aClockConfig[0]); Siul2_Port_Ip_Init( NUM_OF_CONFIGURED_PINS_PortContainer_0_BOARD_InitPeripherals, g_pin_mux_000InitConfigArr_PortContainer_0_BOARD_InitPeripherals); Power_Ip_Init(&Power_Ip_HwIPsConfigPB); gVar = Power_Ip_GetResetReason(); /* Disable recovery mode */ IP_DCM_GPR->DCMRWP1 |= (3 << 22); for (count = 0; count < 10125000; count++); Power_Ip_PerformReset(&Power_Ip_HwIPsConfigPB); } 在第 15 次功能复位后,我在 Clock_Ip_Init() 之前直接读取了 IP_MC_RGM->DES。但是,我没有观察到 DES[MC_RGM_FRE] = 1。DES 值保持为 0,而 FES 包含 RESET 状态(在我的测试中为 0x20000001)。 基于此观察,我认为该问题可能不仅限于 Power_Ip_MC_RGM_GetResetReason() 或 RESET-reason 报告。由于我在时钟和电源初始化之前直接读取 MC_RGM DES 寄存器,因此我期望 DES[MC_RGM_FRE] 指示 FRET 升级(如果发生了破坏性升级)。 因此,请您确认一下,在第 15 次功能 RESET 之后,MC_RGM 硬件层面是否发生了 FRET 升级?如果此时预期会发生破坏性升级,请问为什么 IP_MC_RGM->DES 仍然为 0? 另外,除了您发现的 Power_Ip_MC_RGM_GetResetReason() 问题之外,您能否确认是否存在与 FREC/FRET 升级机制本身相关的其他 RTD 7.0.1 问题或配置问题? 感谢您协助我们调查此事。 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention 你好@Sharif417 , 我相信破坏性重置确实正在发生;您可以按照以下我的测试步骤进行操作: 将 FRET 设置为 1,这样每次功能复位都会触发功能复位升级。 声明两个变量(一个用于 DES 寄存器,一个用于 FES 寄存器),以及一个 while() 循环,用于在读取变量之前停止内核。 int main(void) { volatile uint8_t debug = 1; while(debug); volatile uint32_t regValueDes = 0; volatile uint32_t regValueFes = 0; regValueDes = IP_MC_RGM -> DES; regValueFes = IP_MC_RGM -> FES; ... }​ 将代码烧录到 MCU 后,将调试变量改为 0 以启用程序运行并断开调试器。 执行功能复位(您可以使用自己的程序,或者使用我提供的示例)。 选择“连接到运行目标”将其连接到 MCU。 暂停执行,将调试变量设置为 0,并读取 DES 和 FES 变量: Julin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.png 通过这种方法,在生成功能复位并附加之后,我可以看到与功能复位升级过程相关的 DES[MC_RGM_FRE] 位。 我不确定你为什么会读取 DES->0,如果调试器一直连接着,我想这会干扰 RESET 序列,并产生 RESET。我建议按照我分享的步骤进行测试,并确认 DES 是否真的被设置好了。 请随时告知我最新情况。 此致, 朱利安 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention 你好@Sharif417 , 很高兴你能够正确观察到这种行为。 我已经报告了 Power_Ip_GetResetReason() 的问题,正在等待反馈。一旦内部团队分享了更多信息,我可以提供更多信息;或者您可以创建一个新的案例或社区帖子来请求后续信息。 此致, 朱利安 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention 嗨,朱利安, 感谢您的支持。 我按照你的步骤,将 FRET = 1 并添加了 while(debug) 循环,然后再读取 DES 和 FES。 我发现,在 while(debug) 循环中,功能性重置升级后的破坏性重置可以正常工作。如果没有 while(debug) 循环,我就无法观察到破坏性重置。 我还确认,即使不使用“附加到运行目标”,它也能正常工作。 谢谢你帮我找到原因。 此致, 谢里夫 Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention 嗨,朱利安, 感谢您提供最新信息,并向内部团队报告Power_Ip_GetResetReason()问题。我会等待进一步的反馈。 此致, 谢里夫
查看全文
I am looking for the impedance of AFT05MS004NT AT FREQ 30-45 MHZ I am looking for the impedance of the  AFT05MS004NT1 ,ZLOAD AND Z SOURCE FOR 30-45 MHZ  PLEASE HELP ME GUYS Re: I am looking for the impedance of AFT05MS004NT AT FREQ 30-45 MHZ Hello, Unfortunately, we do not have impedance data for the AFT05MS004NT in the 30–45 MHz frequency range. Obtaining impedance data requires a dedicated characterization process that must be performed separately for each frequency of interest. This process is time consuming and typically focuses on the frequency range for which the device was originally characterized and intended to operate. Evaluating additional frequencies often requires the design and construction of specific test fixtures and matching networks. For this reason, impedance data is not always available for operating conditions outside the standard characterization range, such as different frequencies, power levels, or supply voltages. We apologize for any inconvenience and appreciate your understanding. Re: I am looking for the impedance of AFT05MS004NT AT FREQ 30-45 MHZ thx for the answer but is there any chance to make this part to tx at 30-45 mhz ? and could u tell me how to get the zload and z source live with vector network analyzer 
查看全文
模块 phalFelica 中的 NXPNfcRdLib 漏洞 - 常见漏洞与后门-2026-87726 概述 支持软件 NXPNfcRdLib 中发现了一个软件漏洞 - 常见漏洞与后门-2026-87726。NXP NXPNfcRdLib 模块 phalFelica(固件版本 07.14.00_Pub 之前)的 API 边界检查不足,可能允许具有特权的攻击者或不受信任的第三方访问非预期的内存区域,从而可能导致机密性、完整性和可用性的有限损失。 受影响的设备 当 NXPNfcRdLib 版本 07.14.00 及更早版本与基于 FeliCa 的应用程序一起使用时,在基于 CLRC663 系列、PN5180、PN7462 和 PN5190 平台构建的 NFC 阅读器解决方案上部署时,该漏洞会影响这些应用程序。 减轻 请使用NFC读取器库 | NXP 半导体上提供的最新 NXPNfcRdLib。从 07.18.00 开始的所有固件版本都已修复此问题。 致谢 NXP感谢Ezhilamuthan的负责任披露。
查看全文
S9KEAZN8 – Low power mode entry code example and PWM signal detection in sleep I am using S9KEAZN8. I would like to know how to enter low power mode. Could anyone provide a code example showing how to do this? Also, I need to detect PWM signal changes while the MCU is in low power mode. What would be the proper way to handle this? The Reference Manual does not have code examples. Any sample code or guidance would be appreciated. Thanks. Re: S9KEAZN8 – Low power mode entry code example and PWM signal detection in sleep Hello @ssjj  Which IDE are you using? If you are using S32DS, there are example projects available for KEA128. These examples can also be used for KEA8 with minor modifications. About enter low power mode, you can enter through the WFI instruction. For the specific implementation, you can refer to the pmc.c file, which includes functions such as PMC_SetMode().   If you have any other questions, please feel free to get back to me. BR Alice Re: S9KEAZN8 – Low power mode entry code example and PWM signal detection in sleep For the S9KEAZN8, set low-power mode by setting the required clock/power configurations, and execute the appropriate WFI (Wait For Interrupt) instruction; the exact mode and wake-up sources depend on the S9KEAZN8 power-management module. For PWM monitoring, normally the MCU cannot measure PWM changes continuously when deeply asleep, so set-up an interrupt capable timer/input-capture channel or an external interrupt as the wake-up source; when an edge is detected, wake-up the MCU and use the timer/input-capture peripheral to measure the PWM period/duty cycle. Make sure to check the low-power wake-up/clock limitations of your device carefully as some peripherals and clocks are disabled in the deeper low-power modes.
查看全文
S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hello NXP Team, I am working with an S32K312 Cortex-M7 using S32 Design Studio and AUTOSAR RTD 7.0.1 / AUTOSAR 4.9. I am currently testing the MC_RGM reset behavior, particularly SWT0 functional reset, functional reset escalation, destructive reset, SRAM retention, SBAF/recovery behavior, and the Power IP reset APIs. 1. SWT0 functional reset escalation I am using SWT0 timeout to generate functional resets. My MC_RGM configuration is: MC_RGM_FRET_FRET((uint32)15U), MC_RGM_DRET_DRET((uint32)0U) I observe the functional reset counter increasing: SWT0 functional reset #1 -> FREC = 1 SWT0 functional reset #2 -> FREC = 2 ... SWT0 functional reset #14 -> FREC = 14 After the next SWT0 reset, FREC is cleared/reset, but I do not observe the expected: DES[MC_RGM_FRE] = 1 My questions are: Does SWT0_RST participate in the MC_RGM functional reset escalation counter (FREC) on S32K312? When FREC reaches FRET = 15, should MC_RGM_FRE be generated and should DES[MC_RGM_FRE] be set? What exact values should I expect for FES, DES, FREC, FRET, Power_Ip_GetResetReason() immediately after the escalation? Is any additional configuration required for SWT0 to participate in FRET escalation? Can SBAF/recovery handling interfere with FRET escalation? Is there any known erratum or known S32K312 behavior related to SWT0/FRET escalation? When I run the application continuously, after the 15th functional reset the application/debugger stops instead of allowing me to observe the expected destructive reset. I would like to know whether this is related to the reset sequence, SBAF recovery, or the debugger. 2. I want every SWT0 functional reset to become destructive For testing purposes, I would also like to achieve: SWT0 timeout ↓ Functional reset ↓ Immediate destructive reset instead of waiting for 15 functional resets. Can this be achieved by configuring: FRET = 1U;  Specifically: Does FRET = 1 cause the first qualifying SWT0 functional reset to escalate to a destructive reset? Is any additional MC_RGM configuration required? Is SWT0 guaranteed to be a qualifying source for this escalation? Can SBAF/recovery behavior affect this? Is this supported directly through RTD 7.0.1 configuration? 3. SRAM data is cleared after every functional reset According to my understanding of the S32K3xx Reference Manual, SRAM/system memory should be preserved across a functional reset. I created an SRAM test variable: #define SRAM_TEST_ADDR ((volatile uint32_t *)0x204007d4U) and use it to verify retention across functional resets. However, I observe that the SRAM data is being cleared/re-written to zero after a functional reset. My questions are: Is SRAM preserved by the hardware during functional reset but overwritten afterward by software? Which SRAM regions are guaranteed to retain their contents across functional reset on S32K312? What is the recommended way to place a variable in SRAM so that its contents are retained across functional reset? Should I use a dedicated .noinit or retained SRAM section? Is there any specific MC_RGM/SRAM configuration required for retention? What is the recommended RTD 7.0.1 method for retaining application data across functional reset? 4. Direct software destructive reset I am also testing a direct software destructive reset using the Power IP: Power_Ip_Init(&Power_Ip_HwIPsConfigPB); gVar= Power_Ip_GetResetReason(); for (count = 0; count < 10125000; count++); Power_Ip_PerformReset(&Power_Ip_HwIPsConfigPB); My current MC_RGM configuration contains: static const Power_Ip_MC_RGM_ConfigType Power_Ip_MC_RGM_ConfigPB = { (MCU_DEST_RESET), ... MC_RGM_FRET_FRET((uint32)15U), MC_RGM_DRET_DRET((uint32)0U) }; The destructive reset occurs, but the debugger repeatedly loses and re-establishes communication. I see messages such as: INFO: DAP IDCODE = 0x6BA02477 INFO: DAP successfully powered up. DP CTRL/STAT = 0xF0000000 repeated multiple times, followed by: Interrupt command received. Halting execution. I would like to understand: Is repeated DAP reconnection expected during a destructive reset? What exactly happens to the Cortex-M7 during the destructive-reset sequence? When does the CPU become available again after the destructive reset? What is the recommended way to debug a single software destructive reset? 5. Breakpoint behavior before Power_Ip_PerformReset() I cannot reliably hit a breakpoint immediately before: Power_Ip_PerformReset(&Power_Ip_HwIPsConfigPB); I added a delay before the API, expecting the debugger to have enough time to gain access. Sometimes the breakpoint is only reached after I manually pause the target and then resume execution. I would like to understand: Why can the debugger miss the breakpoint even though there is a delay before the reset API? Is this related to the target repeatedly resetting and the debugger reconnecting through DAP? Is there a recommended method for catching the CPU immediately before or immediately after a destructive reset? Is the RTD DISABLE_DEBUGGER_TRAP option relevant to this behavior? 6. Power IP initialization and Power_Ip_SetMode() My RTD provides: void Power_Ip_Init( const Power_Ip_HwIPsConfigType *HwIPsConfigPtr); void Power_Ip_SetMode(const Power_Ip_ModeConfigType *ModeConfigPtr); void Power_Ip_PerformReset( const Power_Ip_HwIPsConfigType *HwIPsConfigPtr ); Power_Ip_ResetType Power_Ip_GetResetReason(void); Power_Ip_RawResetType Power_Ip_GetResetRawValue(void); I currently use: Power_Ip_Init(&Power_Ip_HwIPsConfigPB); and: gVar = Power_Ip_GetResetReason(); My mode configuration is POWER_IP_RUN_MODE. I would like clarification on: Is Power_Ip_Init(&Power_Ip_HwIPsConfigPB) the correct initialization before using the Power IP reset APIs? Is Power_Ip_SetMode() required for software functional/destructive reset testing? Since my selected mode is POWER_IP_RUN_MODE, can Power_Ip_SetMode() be omitted for this reset test? How should I configure separate software functional-reset and software destructive-reset configurations using RTD 7.0.1? Environment MCU: S32K312 Core: Cortex-M7 S32DS: S32 Design Studio AUTOSAR: 4.9 RTD: 7.0.1 Reset source: SWT0 FRET: 15 DRET: 0 I can provide the complete test application, Power_Ip_PBcfg.c, linker configuration, MC_RGM register captures, and debugger logs if required. Thank you. Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hello @Sharif417, 1. SWT0 functional reset escalation SWT0_RSTdoes participate in FREC for S32K312, and when FREC reaches 15, DES[MC_RGM_FRE] is set, which you should be able to read by calling Power_Ip_GetResetReason(), and returning "MCU_MC_RGM_FRE_RESET". All functional reset sources that are not demoted (through MCRGM.FERD) qualify for incrementing FREC. Keep in mind that Power_Ip_Init() clears MC_RGM.DES (after saving its value), so try to get the register values before initializing Power module or simply read reset reason. Recovery Mode may affect this, if the threshold is >8, as Recovery Mode is set to '8' by default. sBAF also may interfere with DRET, not FRET. You can see it is changed to 0xF if it is '0':   Julin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.pngJulin_AragnM_0-1788816978772.png When I run the application continuously, after the 15th functional reset the application/debugger stops instead of allowing me to observe the expected destructive reset. I would like to know whether this is related to the reset sequence, SBAF recovery, or the debugger. Instead of trying to keep the debugger connected, can you try attaching after a 15th functional reset, or try printing the reset reason through UART or similar? 2. I want every SWT0 functional reset to become destructive Yes, FRET=1 is enough for every functional reset to issue a destructive reset. No additional MC_RGM necessary. sBAF/Recovery Mode should not affect this. Yes, you can configure it directly in POWER module -> "Module Configuration" -> "McuResetConfig" -> "Functional Reset Escalation Threshold" 3. SRAM data is cleared after every functional reset Correct, SRAM is preserved after functional reset. Depending on the derivative, S32K3 may provide 16KB, 32KB or up to 64KB for Standby RAM. You can find some examples on how to place and use a variable through Standby RAM: [RTD600 MCAL & IP] S32K3 Low Power Management AN and demos S32K3 Low Power Management AN and demos Example S32K312 Standby mode & Standby RAM and PAD keeping DS3.5 RTD300 The reason that Standby RAM is being cleared/re-written, is because the default startup_cm7.s provided by S32DS initializes all of SRAM, regardless of reset reason (POR, Destructive, Functional). You must modify it so that if a functional reset is issued, SRAM initialization skips the allocated Standby RAM. Please refer to the following community post: S32K311 standby ram retention. 4. Direct software destructive reset Yes, when MCU is issued a functional/destructive reset, the debug subsystem and clocks are all re-initialized, meaning the debugger must re-negotiate DAP access again. A destructive reset leads most parts of the chip, except a few modules, to reset. While a functional reset leads all the communication peripherals and cores to reset. The communication protocols' sanity is not guaranteed and they are assumed to be reinitialized after reset. Instead of trying to keep the connection, you can use the 'Attach to Target' option for the debugger: Julin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.pngJulin_AragnM_1-1788817136992.png 5. Breakpoint behavior before Power_Ip_PerformReset() Most likely you are simply missing the window to reconnect. Instead of using a for() loop, you can simply use while(flag), where flag is a variable you will change manually after reconnecting with the debugger, through the 'Expressions' tab. 6. Power IP initialization and Power_Ip_SetMode() Yes, Power_Ip_Init() must be called before using the Power APIs. I suggest doing so. You can perform resets through Power_Ip_PerformReset(), however, you can only configure either destructive or functional reset in McuResetConfig container. You can instead declare two power modes: one for functional reset, and one for destructive reset. Then simply call Power_Ip_SetMode(Functional_Reset) or Power_Ip_SetMode(Destructive_Reset). It can be omitted, however, you should call Power_Ip_SetMode(RUN_MODE) just to make sure every module is correctly gated and configured. If this is not needed in your project, you can omit it. Please se A6.2. I've made a simple test, and I can see FRE_RESET reported after setting FRET=1, and performing a functional reset through Power_Ip_SetMode() API: Julin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.pngJulin_AragnM_2-1788817284857.png Best regards, Julián Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hello Julián, Thank you for the clarification. I have now repeated the tests on my S32K312 and would like to clarify two observations. I am attaching the complete project folder so that you can review the configuration and reproduce the behavior. 1. SWT0 functional reset escalation I configured: FRET = 15U;DRET = 0U; and use SWT0 with a 125 ms timeout to generate functional resets. I can observe FREC increasing after each functional reset: SWT0 reset #1 -> FREC = 1 SWT0 reset #2 -> FREC = 2 ... SWT0 reset #14 -> FREC = 14 However, when the next SWT0 functional reset occurs and the FRET = 15 threshold is reached, I am not able to observe the expected destructive-reset status: DES[MC_RGM_FRE] = 1 Also, after the 15th functional reset, the MCU continues running and I do not observe the expected destructive-reset behavior. The SRAM data stored in my SRAM test partition also remains intact. I have disabled the recovery behavior using: IP_DCM_GPR->DCMRWP1 |= (3 << 22); Could you please review my attached project and clarify: Why am I not observing DES[MC_RGM_FRE] = 1 after the 15th SWT0 functional reset? After FREC reaches FRET = 15, should the MCU definitely enter a destructive reset? If a destructive reset occurs, why my SRAM contents is retained in my test partition ? Is there any additional MC_RGM/SBAF configuration that I am missing? 2. SRAM retention after functional and destructive reset I created a dedicated SRAM partition/section and stored test data in that region. I have confirmed that the SRAM value is retained across the repeated SWT0 functional resets, which is expected. However, even after the 15th functional reset, where I expect FRET escalation to generate a destructive reset, the SRAM value still remains. I also tested a direct software destructive reset, and the SRAM value was still retained after that reset as well. My observation is therefore: SWT0 functional reset ↓ SRAM value retained 15th functional reset / expected FRET escalation ↓ SRAM value still retained Direct software destructive reset ↓ SRAM value also retained Could you please clarify whether this SRAM behavior is expected on the S32K312, and whether my SRAM test region may be located in a memory area that is retained even across a destructive reset? I am attaching the complete S32K312 project folder, including the linker configuration, RTD configuration, MC_RGM configuration, SWT0 configuration, and test application, so you can review the actual memory placement and reset configuration. Thank you for your support. Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hello @Sharif417, 1. SWT0 functional reset escalation 1. Why am I not observing DES[MC_RGM_FRE] = 1 after the 15th SWT0 functional reset? As I've mentioned, Power_Ip_Init() API clears DES register, meaning you should read reset reason through Power_Ip_GetResetReason() instead.  2. After FREC reaches FRET = 15, should the MCU definitely enter a destructive reset? If a destructive reset occurs, why my SRAM contents is retained in my test partition? Yes. As long as FREC reaches the threshold configured in FRET, MCU should issue a destructive reset. Either a destructive reset is not occurring, or variable is wrongly placed.  3. Is there any additional MC_RGM/SBAF configuration that I am missing? No. For Functional Reset Escalation, simply setting FRET should suffice.  2. SRAM retention after functional and destructive reset 1. Could you please clarify whether this SRAM behavior is expected on the S32K312, and whether my SRAM test region may be located in a memory area that is retained even across a destructive reset? This should not be the case. All SRAM content is lost after a destructive reset event. Can you share how exactly are you testing the direct software destructive reset? From your project, if you are using Power_Ip_PerformReset() API, it is configured as functional reset, not destructive. Julin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.pngJulin_AragnM_0-1788891886849.png Actually, I tested this by saving the values and share them through UART, where FRDM-A-S32K312, issues a functional reset through SW2, FRET is set to 15, and after 15 SW functional resets, I can see MCU_MC_RGM_FRE_RESET being generated. This is in RTD 6.0.0, please see my log below: [RESET] Reason : MCU_F_EXR_RESET (RGM_FES F_FR0) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 2 [RESET] Reason : MCU_SW_DEST_RESET (RGM_DES F_DR29) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 2 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 3 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 4 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 5 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 6 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 7 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 8 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 9 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 10 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 11 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 12 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 13 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 14 [RESET] Reason : MCU_MC_RGM_FRE_RESET (RGM_DES F_DR6) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 In RTD 7.0.1, I can see the same behavior you mention (from FRE not asserting destructive reset, to debugger disconnecting): [RESET] Reason : MCU_SW_DEST_RESET (RGM_DES F_DR29) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_DEST_RESET (RGM_DES F_DR29) [RESET] FRE Counter: 0 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 1 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 2 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 3 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 4 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 5 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 6 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 7 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 8 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 9 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 10 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 11 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 12 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 13 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 14 [RESET] Reason : MCU_SW_FUNC_RESET (RGM_FES F_FR29) [RESET] FRE Counter: 0 This leads me to believe that there are some differences in Power driver between RTD 6.0.0 & RTD 7.0.1 which leads to these symptoms. I have not been able to pinpoint if this is an issue with configuration, or a bug, please give me some time to analyze and contact the internal team if needed. Best regards, Julián Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hello Julián, Thank you for the clarification. As requested, I have attached the ZIP file containing the software destructive-reset test code/project that I am currently using. Since you mentioned that the FRET escalation works correctly with RTD 6.0.0, could you please share the working RTD 6.0.0 code/project that you used for your test? I would like to use your RTD 6.0.0 working code as a reference and compare it with my RTD 7.0.1 project to understand the difference in behavior. Also, as you mentioned that you suspect there may be a difference or issue in the Power driver between RTD 6.0.0 and RTD 7.0.1, could you please let me know your findings regarding the RTD 7.0.1 issue once you have completed the analysis? Thank you for your support. Best regards, Sharif Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hi @Sharif417, After going through the source code for Power_Ip driver, I can see a fix for Functional Reset Escalation Counter was applied in Power_Ip_MC_RGM_GetResetReason() API, where a third clause was added, it also enter FES if DES has bits set AND the FRET register currently reads non-zero. RTD 6.0.0: /* If the fields of Destructive Event Status Register (DES) are set then the status of FES register must be ignored */ if (((uint32)0U == ActiveValue) || (MCU_POWER_ON_RESET == ResetReason)) { ... } RTD 7.0.1: /* If the fields of Destructive Event Status Register (DES) are set then the status of FES register must be ignored */ /* If functional reset escalation to destructive reset is disabled, then the status of FES register must be ignored if the fields of Destructive Event Status Register (DES) other than DES[F_POR] are set. */ /* If functional reset escalation to destructive reset is enabled and if the fields of Destructive Event Status Register (DES), other than DES[F_POR], are set, then based on these fields user should check if the cause of the destructive reset was due to functional reset escalation or if it was triggered directly by a destructive reset source, in which case FES needs to be ignored */ if (((uint32)0U == ActiveValue) || (MCU_POWER_ON_RESET == ResetReason) || (((uint32)0U != DesResetStatus) && ((uint32)0U != Power_Ip_pxMC_RGM->FRET))) { ... } This is why FES flag is overwritten. If I am correct, destructive reset is issued correctly by hardware, however, Reset module reports a functional reset instead. You can confirm this by reading the IP_MC_RGM->DES register directly after the 15th functional reset: Julin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.pngJulin_AragnM_0-1788976448272.png I guess a valid approach could be to change the third clause to check if MCU_MC_RGM_FRE_RESET event has already happened: /* ----------------------------------------------------------------------- * Enter the FES block if: * a) DES is empty (no destructive reset logged), OR * b) DES has only the Power-On Reset bit, OR * c) DES has bits set AND FRE escalation is configured (FRET != 0) * AND the DES reason is NOT already MCU_MC_RGM_FRE_RESET * ----------------------------------------------------------------------- */ if (((uint32)0U == ActiveValue) || (MCU_POWER_ON_RESET == ResetReason) || (((uint32)0U != DesResetStatus) && ((uint32)0U != Power_Ip_pxMC_RGM->FRET) && (MCU_MC_RGM_FRE_RESET != ResetReason))) Keep in mind that modifying the RTD drivers is not supported, and the correct approach is to wait for an official fix from the SW team. I will flag this behavior with the internal team, and provide their feedback, if any. Thank you for pointing this issue out. Lastly, regarding your project, I can see you are issuing a reset through Power_Ip_PerformReset(). As I've mentioned, you have 'Functional Reset' configured inside the Reset configuration, you must change it to 'Destructive Reset' in order to issue a Software Destructive Reset: Julin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.pngJulin_AragnM_2-1788976691375.png or add a ModeSettingConf structure, select DEST_RESET, and call Power_Ip_SetMode() instead: Julin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.pngJulin_AragnM_3-1788976695121.png Best regards, Julián Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hello Julián, Based on your recommendation, I performed an additional test by directly reading the MC_RGM DES and FES registers, rather than relying only on Power_Ip_GetResetReason(). In this test, I configured the reset type as software functional reset with FRET = 15. After each software functional reset, the FREC counter increments. After the 15th software functional reset, I placed a breakpoint in main() before Clock_Ip_Init() and directly read the MC_RGM registers: volatile uint32_t regValueDes = 0U;volatile uint32_t regValueFes = 0U; regValueDes = IP_MC_RGM->DES;regValueFes = IP_MC_RGM->FES; gVar = Power_Ip_GetResetReason(); The complete test code is as follows: int main(void) { volatile uint32_t regValueDes = 0U; volatile uint32_t regValueFes = 0U; regValueDes = IP_MC_RGM->DES; regValueFes = IP_MC_RGM->FES; gVar = Power_Ip_GetResetReason(); Clock_Ip_Init(&Clock_Ip_aClockConfig[0]); Siul2_Port_Ip_Init( NUM_OF_CONFIGURED_PINS_PortContainer_0_BOARD_InitPeripherals, g_pin_mux_000InitConfigArr_PortContainer_0_BOARD_InitPeripherals); Power_Ip_Init(&Power_Ip_HwIPsConfigPB); gVar = Power_Ip_GetResetReason(); /* Disable recovery mode */ IP_DCM_GPR->DCMRWP1 |= (3 << 22); for (count = 0; count < 10125000; count++); Power_Ip_PerformReset(&Power_Ip_HwIPsConfigPB); } After the 15th functional reset, I directly read IP_MC_RGM->DES before Clock_Ip_Init(). However, I did not observe DES[MC_RGM_FRE] = 1. The DES value remains 0, while FES contains the reset status (0x20000001 in my test). Based on this observation, I believe the issue may not be limited to Power_Ip_MC_RGM_GetResetReason() or reset-reason reporting. Since I am directly reading the MC_RGM DES register before the clock and Power initialization, I expected DES[MC_RGM_FRE] to indicate the FRET escalation if the destructive escalation had occurred. Therefore, could you please confirm whether the FRET escalation itself is occurring at the MC_RGM hardware level after the 15th functional reset? If the destructive escalation is expected at this point, could you please advise why IP_MC_RGM->DES remains 0? Also, could you please confirm whether there is any additional RTD 7.0.1 issue or configuration related to the FREC/FRET escalation mechanism itself, in addition to the Power_Ip_MC_RGM_GetResetReason() issue you identified? Thank you for your support in helping us investigate this issue. Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hello @Sharif417, I believe the destructive reset is indeed happening; you can follow my test procedure below: Set FRET=1, so each functional reset triggers a Functional Reset Escalation. Declare two variables (one for DES, and one for FES registers), as well as a while() loop for stopping the core before reading the variables. int main(void) { volatile uint8_t debug = 1; while(debug); volatile uint32_t regValueDes = 0; volatile uint32_t regValueFes = 0; regValueDes = IP_MC_RGM -> DES; regValueFes = IP_MC_RGM -> FES; ... }​ After flashing the MCU with the code, change debug variable to 0 to enable the program to run and disconnect the debugger.  Perform the functional reset (you can use your program, or the example I've provided). Attach to the MCU by selecting "Attach to Running Target". Pause the execution, set debug variable to 0, and read DES & FES variables: Julin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.pngJulin_AragnM_0-1789079229563.png With this method, after generating the functional reset, and attaching, I can see DES[MC_RGM_FRE] bit related to the Functional Reset Escalation procedure. I'm not sure why you are reading DES->0, if debugger was kept connected, I imagine this meddles with the reset sequence, and generated resets. I suggest testing it with the steps I shared and confirm if DES is really being set or not. Please keep me informed. Best regards, Julián Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hello @Sharif417, I'm glad you were able to correctly observe this behavior.  I've already reported the Power_Ip_GetResetReason() issue, I am waiting for feedback on this. I can provide more information once the internal team shares it, or you can create a new case or community post to request follow-up information. Best regards, Julián Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hi Julián, Thank you for the support. I followed your procedure with FRET = 1 and added the while(debug) loop before reading DES and FES. I found that the destructive reset after functional reset escalation works correctly with the while(debug) loop. Without the while(debug) loop, I was not able to observe the destructive reset. I also confirmed that it works even without using “Attach to Running Target”. Thank you for helping me to identify this. Best Regards, Sharif Re: S32K312: SWT0 Functional Reset Escalation, Destructive Reset Status and SRAM Retention Hi Julián, Thank you for the update and for reporting the Power_Ip_GetResetReason() issue to the internal team. I will wait for further feedback. Best regards, Sharif
查看全文
NXPNfcRdLib vulnerability in module phalFelica - CVE-2026-87726 Overview A software vulnerability - CVE-2026-87726 - has been identified in the supporting software NXPNfcRdLib. An insufficient API bounds checking in NXP NXPNfcRdLib module phalFelica up to Firmware version 07.14.00_Pub may allow an attacker with privileges or an untrusted third party to access unintended memory regions, potentially leading to limited loss of confidentiality, integrity, and availability. Impacted devices The vulnerability affects deployments of NXPNfcRdLib versions 07.14.00 and earlier when used in conjunction with FeliCa-based applications on NFC Reader solutions built on the CLRC663 family, PN5180, PN7462, and PN5190 platforms. Mitigation Use the latest NXPNfcRdLib available on NFC Reader Library | NXP Semiconductors All firmware versions from 07.18.00 onwards have fixed this problem. Acknowledgment NXP would like to thank Ezhilamuthan for the responsible disclosure.
查看全文
S9KEAZN8 — 低功耗模式入门代码示例和睡眠时的 PWM 信号检测 我使用的是 S9KEAZN8。我想知道如何进入低功耗模式。谁能提供一个代码示例,说明如何做到这一点? 另外,我需要检测 MCU 处于低功耗模式时的 PWM 信号变化。正确的处理方法是什么? 参考手册没有代码示例。如能提供任何示例代码或指导,将不胜感激。 谢谢。 Re: S9KEAZN8 – Low power mode entry code example and PWM signal detection in sleep 你好@ssjj 您使用的是哪个集成开发环境?如果您使用的是 S32DS,则有适用于 KEA128 的示例项目。这些示例稍作修改后也可用于 KEA8。 关于进入低功耗模式,您可以通过 WFI 指令进入。具体实现可参考 pmc.c 文件,其中包括 PMC_SetMode() 等函数。   如果您有任何其他问题,请随时联系我。 BR 爱丽丝 Re: S9KEAZN8 – Low power mode entry code example and PWM signal detection in sleep 对于 S9KEAZN8,通过设置所需的时钟/电源配置来设置低功耗模式,并执行相应的 WFI(等待中断)指令;确切的模式和唤醒源取决于 S9KEAZN8 电源管理单元。对于 PWM 监测,通常 MCU 在深度睡眠时无法连续测量 PWM 变化,因此设置一个具有中断功能的定时器/输入捕获通道或外部中断作为唤醒源;当检测到边沿时,唤醒 MCU 并使用定时器/输入捕获外设来测量 PWM 周期/占空比。请务必仔细检查设备的低功耗唤醒/时钟限制,因为在更深的低功耗模式下,某些外围设备和时钟会被禁用。
查看全文
Login with keyfob/smartcard only I work in a manufacturing company and we're looking at putting PCs out on the shop floor for employees to be able to do things like look at parts drawings, sign off that tasks are completed etc. As we want this to be as painless as possible but still have a record of who is signing off on the tasks, we are looking at the best way for the employees to use the access control badges they already have for accessing doors and clocking in and out. If that's not feasible we're certainly open to other options that would allow the employees to log in with some kind of physical token and never have to touch a keyboard or mouse let alone remember user names and passwords. I've looked into smart cards, but it appears that they require a PIN which we want to avoid if at all possible. We understand the inherant security risks and these devices would be locked down to only be able to do specific tasks and not have access to another parts of the network. Smart Cards on Mobile Re: Login with keyfob/smartcard only I would suggest the MIFARE DESFire EV3. Here is the web page: MIFARE DESFire EV3 | Secure Contactless IC | NXP Semiconductors
查看全文