Multi Source Translation Content

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Multi Source Translation Content

Discussions

Sort by:
[Zephyr ® Series] Part 4: Overview and Practical Applications of Kconfig and Device Trees (Japanese Blog)   From this point on, we'll be moving on to the advanced topics of Zephyr. This session will cover an overview of Kconfig and device trees, followed by hands-on programming exercises to help you utilize them effectively.   One of the key features of Zephyr RTOS, as mentioned previously, is its software scalability (reusability), which makes it easy to reuse software developed once in other projects or derivative products, enabling rapid development.   Furthermore, to support a wide range of hardware platforms, Zephyr employs a powerful configuration system called "Kconfig" and "Devicetree".   This allows you to port programs to different microcontroller boards simply by changing configuration files, without having to rewrite the source code in the same C/C++ language. This article explains the basic mechanisms of Kconfig and the device tree. As a practical application, we will modify the hardware-independent LED blinking program created in Part 3 to run on two different microcontroller boards: " FRDM-MCXA153 " and " FRDM-MCXN947 ".   To run the same application on different boards (microcontrollers and processors), we will explain practical programming methods using Kconfig and the device tree.     table of contents   Preparation Kconfig Basics Device tree fundamentals Best practices for improving software reusability Kconfig and the Device Tree in Practice Create a simple program (hands-on) 1. Program Specifications 2. Directory structure 3. Create Kconfig and prj.conf 4. Creating device tree overlays and board-specific settings 5. Hardware-independent common code (main.c) Create 6. Build and run summary Preparation   Hardware preparation   This article will primarily use the following boards to create and test programs. FRDM-MCXA153 (main use) Additionally, the following boards will be used as supplementary tools to verify the portability of the program you have created. FRDM-MCXN947   SW preparation   This guide assumes that you have already set up the Zephyr development environment (Zephyr SDK, West command, etc.). If you haven't set it up yet, please refer to the second article on environment setup. [Zephyr ® Series] Part 2: First Build and Testing (Japanese Blog)   We will be using the LED blinking program created in the third installment of the Zephyr series. If you haven't created it yet, we recommend creating it by referring to the previous article. [Zephyr ® Series] Part 3: First Steps in Blinking an LED and Software Reusability (Japanese Blog)   Kconfig Basics     Kconfig is a configuration system also used in the Linux kernel. In Zephyr, it is used to manage whether to "enable or disable" software features, or "what parameters to set," such as kernel functions, device drivers, subsystems, and application-specific settings. The following two files are important for Kconfig: The "Kconfig" file defines the selectable configuration items (symbols), their default values, and dependencies. "prj.conf" file *: This file is where application developers specify the values they want to set for items defined in "Kconfig" (such as enabling them with "y" or providing specific numerical values). Using Kconfig, you can exclude unnecessary code from compilation and optimize memory usage. Furthermore, the Kconfig and prj.conf files are all written in text format. How to enable the feature The prj.conf file enables features for the entire project. For example, the ADC, DAC, and OPAMP drivers are defined in Kconfig. When using the functions defined in Kconfig, you declare them by adding "CONFIG_" to the beginning of prj.conf. Kconfig:ADCの定義Kconfig: ADC definition prj.conf例prj.conf example   Device tree fundamentals   Devicetree例Example of a device tree   The device tree is a text file that describes what hardware (CPU, memory, peripherals, pin settings, etc.) a microcontroller supports, as well as the settings and configuration of that hardware. These settings and configurations are then expanded into macros.   Instead of directly writing hardware addresses into C code (hardcoding), information described in the device tree can be read through Zephyr macros, enabling hardware-independent programming. Nodes and Properties: Each element of hardware is represented as a "node" in a hierarchical structure, and register addresses, interrupt numbers, etc., are described as "properties." ".dts" and ".dtsi": Standard hardware configurations for each microcontroller and board are predefined within the Zephyr repository in ".dts" (Devicetree Source) and ".dtsi" (Include) files. dts: Described as the device tree of the board. dtsi: Describes the device tree of an SoC/microcontroller and is provided by the device manufacturer. ".overlay" file: This file is created when you want to override application-specific wiring (e.g., connecting an LED to a specific GPIO pin) or default settings.   Best practices for improving software reusability   To enhance software reusability in Zephyr, it is important to follow the following design principles: Separation of hardware-dependent and hardware-independent parts: C code (`main.c`) For example, avoid directly writing about specific microcontroller register operations or pin numbers. Leverage device tree aliases: Instead of directly referencing actual hardware nodes (e.g., `&red_led` or `&gpioa`), applications should reference abstract names defined in the `aliases` node (e.g., `led0`). This allows you to adapt to different boards simply by changing what the alias points to. Prepare a board-specific device tree (overlay) : When there are differences in some functions, such as in derivative products, you can overwrite (overlay) only the parts with hardware differences for each board. Switching features with Kconfig : Application behavior parameters and the on/off status of specific features are controlled using Kconfig symbols instead of C language "#define".   Kconfig and the Device Tree in Practice   From here, we will learn how to use Kconfig and the device tree by creating a simple program so that we can actually use them in practice .     Create a simple program (hands-on) The program will be created by modifying the LED blinking program we created last time, and will have the following specifications.   Here, as a practical exercise, we will create a common application that runs on both "FRDM-MCXA153" and "FRDM-MCXN947". 1. Program Specifications Source code : Use the code from "Part 3: Your First LED Blinking Program" and make the following modifications. LED blinking speed: The blinking interval can be set using Kconfig. Button Function (Enable/Disable): The button function can be enabled or disabled via Kconfig settings. When enabled, pressing the button will toggle between blinking and constant illumination of the LED. Outputting board name: At startup, the "device (board) name" configured in Kconfig will be output to standard output (terminal). 2. Directory structure   The project directory structure should be as follows:   Add the Kconfig file and boards folder to the "my_hello" folder of the LED blinking program you created last time. Any method of adding the files is fine. On Windows, use the PowerShell `ni` command or a text editor to create a new file and save it in the `my_hello` folder. In Linux, you can create a new, empty file using the `touch` command.   The files under "boards/" handle hardware differences and unique settings specific to each board.     my_hello/ ├── CMakeLists.txt ├── Kconfig <- 新規追加:アプリ独自のKconfig ├── prj.conf <- アプリの共通設定 ├── src/ │ └── main.c <- ハードウェア非依存の共通コード └── boards/ <- 新規作成フォルダ  ├── frdm_mcxa153.overlay <- 新規作成:FRDM-MCXA153用のデバイスツリー設定  ├── frdm_mcxa153.conf <- 新規作成:FRDM-MCXA153用のKconfig設定  ├── frdm_mcxn947_cpu0.overlay <- 新規作成:FRDM-MCXN947用のデバイスツリー設定  └── frdm_mcxn947_cpu0.conf <- 新規作成:FRDM-MCXN947用のKconfig設定   Note : By creating specific files within your application's directory, Zephyr's build system (West) will automatically recognize them and apply the settings. Adding Kconfig: You can add your own configuration symbols by placing a "Kconfig" file in your Applications folder. Board-specific settings ("boards/" directory): By creating a "boards" directory within your application and placing "[board name].overlay" or "[board name].conf" files there, the overlay and Kconfig overrides will be automatically applied only when building with that board as the target.   3. Create Kconfig and prj.conf First, create your own "Kconfig" in the application root directory and define application-specific parameters. my_hello/Kconfig   mainmenu "my LED blink" config CUSTOM_BLINK_RATE_MS int "LED blink rate in milliseconds" default 1000 help Set LED blink frequency. #LEDの点滅周期(ミリ秒)を設定します config ENABLE_BUTTON_TOGGLE bool "Enable button to toggle LED state" default y help Enable button to toggle LED state. # ボタン入力によるLEDの点滅/点灯状態>の切り替え機能を有効にします。 config BOARD_NAME_STRING string "Board Name String" default "Unknown Board" help Set board name for printf. # 標準出力に表示するボード名を設定します。 source "Kconfig.zephyr"     Next, as a common setting for the entire application, there is "prj.conf". This will be written. In this prj.conf file, use the Kconfig symbol you just created to configure it as follows: my_hello/prj.conf   # GPIOの有効化 CONFIG_GPIO=y # アプリケーションの共通設定 CONFIG_CUSTOM_BLINK_RATE_MS=500 CONFIG_ENABLE_BUTTON_TOGGLE=y   4. Creating device tree overlays and board-specific settings Create a directory called "boards" and prepare the necessary files for each board. Main board for FRDM-MCXA153     We map the button on the board (`sw2`) so that it can be accessed from the application using the standard alias `sw0`. `led0` is already in the board definition so it can be omitted here, but it can be explicitly overridden if needed.   my_hello/boards/frdm_mcxa153.overlay / { aliases { sw0 = &user_button_2; /* FRDM-MCXA153のユーザーボタン */ }; };   my_hello/boards/frdm_mcxa153.conf   CONFIG_BOARD_NAME_STRING="FRDM-MCXA153 Board"   By referencing the symbols in this .conf (board-specific Kconfig) within the application (main.c), it becomes possible to output the board name to standard output using the printf function. For FRDM-MCXN947 Similarly, we define "sw0" in the FRDM-MCXN947. This handles any differences in the hardware names of the buttons.   In fact, if the hardware names (which differ depending on the peripheral or instance) vary across boards, you assign the actual hardware to the alias node in the device tree. my_hello/boards/frdm_mcxn947_cpu0.overlay   / { aliases { sw0 = &user_button_3; /* FRDM-MCXN947のユーザーボタン */ }; };   my_hello/ boards/frdm_mcxn947_cpu0.conf   I'll try overriding the LED blinking speed to 250ms only when building with MCXN947.   CONFIG_BOARD_NAME_STRING="FRDM-MCXN947 Board" CONFIG_CUSTOM_BLINK_RATE_MS=250 The application code is the same for FRDM-MCXA153 and FRDM-MCXN947, but you can configure the blinking behavior of the LED separately here. 5. Hardware-independent common code (main.c) Create Write the following in "my_hello/src/main.c":   The LED control section reuses the hardware-independent code (using the "led0" alias) created in the previous article, and incorporates Kconfig and button control into it. my_hello/ src/main.c   #include #include #include /* Devicetreeのエイリアスを参照する */ /* どのボードでも、一番目のLEDは通常 "led0" と定義されています */ #define LED0_NODE DT_ALIAS(led0) #define SW0_NODE DT_ALIAS(sw0) /* エイリアスからGPIO仕様(ポート、ピン、フラグ)を取得 */ static const struct gpio_dt_spec led = GPIO_DT_SPEC_GET(LED0_NODE, gpios); /* ボタン機能がKconfigで有効化されている場合のみコンパイルされる部分 */ #ifdef CONFIG_ENABLE_BUTTON_TOGGLE static const struct gpio_dt_spec sw = GPIO_DT_SPEC_GET(SW0_NODE, gpios); static struct gpio_callback button_cb_data; static bool is_blinking = true; void button_pressed(const struct device *dev, struct gpio_callback *cb, uint32_t pins) { is_blinking = !is_blinking; if (!is_blinking) { /* 点滅オフ時はLEDを点灯させた状態にする */ gpio_pin_set_dt(&led, 1); } } #endif //CONFIG_ENABLE_BUTTON_TOGGLE int main(void) { int ret; /* Kconfigで設定されたボード名を出力 */ printf("Starting application on %s\n", CONFIG_BOARD_NAME_STRING); /* デバイスの準備確認 */ if (!gpio_is_ready_dt(&led)) { return -1; } /* ピンの設定 (Devicetreeで定義された初期状態などを考慮して設定) */ ret = gpio_pin_configure_dt(&led, GPIO_OUTPUT_ACTIVE); if (ret < 0) { return -1; } #ifdef CONFIG_ENABLE_BUTTON_TOGGLE if (!gpio_is_ready_dt(&sw)) { return -1; } ret = gpio_pin_configure_dt(&sw, GPIO_INPUT); if (ret < 0) { return -1; } ret = gpio_pin_interrupt_configure_dt(&sw, GPIO_INT_EDGE_TO_ACTIVE); if (ret < 0) { return -1; } gpio_init_callback(&button_cb_data, button_pressed, BIT(sw.pin)); gpio_add_callback(sw.port, &button_cb_data); #endif //CONFIG_ENABLE_BUTTON_TOGGLE while (1) { #ifdef CONFIG_ENABLE_BUTTON_TOGGLE if (is_blinking) { ret = gpio_pin_toggle_dt(&led); } #else /* ピンの状態を反転 (ボタン機能が無効な場合は常に点滅) */ ret = gpio_pin_toggle_dt(&led); #endif //CONFIG_ENABLE_BUTTON_TOGGLE /* Kconfigで設定された点滅間隔で待機 */ k_msleep(CONFIG_CUSTOM_BLINK_RATE_MS); } return 0; }     6. Build and run Now, let's actually test its functionality. Please refer to the previous article for instructions on setting up the build environment and enabling the west command. First, navigate to the directory of your installed zephyrproject repository as shown in the command instructions below, enable west, and then proceed. Operation confirmed with FRDM-MCXA153 (main) Build using the following command and write it to the FRDM-MCXA153.   ## ホームディレクトリからZephyrprojectディレクトリに移動 cd ~/zephyrproject ## west環境を有効化 source .venv/bin/activate ## zephyr v4.3をチェックアウトしていない場合は、前回(第3回 初めてのLチカとソフトウェアの再利用性)を参考にv4.3をチェックアウトしてください。 west build -b frdm_mcxa153 my_hello west flash     Execution result   コンソール出力Console output   LED点滅、点灯モード切り替えLED flashing and steady light mode switching   The message "Starting application on FRDM-MCXA153 Board" will appear in the terminal. The LED blinks at 500ms intervals ("prj.conf"). (Settings). Pressing SW2 ("custom-sw") will turn it on, and pressing it again will return it to blinking. Operation confirmed with FRDM-MCXN947 We'll build the project using the exact same C source code, only changing the board specification.   # -pオプションを使用し、frdm_mcxa153のビルド情報をクリーンしてビルドします。 west build -p -b frdm_mcxn947//cpu0 my_hello west flash   Execution result   The contents of "boards/frdm_mcxn947_cpu0.conf" will be automatically applied, and the terminal will display "Starting application on FRDM-MCXN947 Board". The LED blinks rapidly at 250ms intervals (configured in "prj.conf"). Pressing SW3 (the button mapped to "user_button_3" on the MCXN947) will similarly switch between LED illumination and blinking. While the FRDM-MCXA153 and FRDM-MCXN947 use different GPIOs for controlling LEDs and switch buttons, the device tree effectively absorbs these differences, demonstrating how cleanly the application program and hardware are separated.   summary     In this session, we learned the basics of Kconfig and device trees in Zephyr, and practiced techniques to separate hardware-dependent parts from C code by utilizing them.   I believe you've experienced a powerful mechanism for reusing the same source code across multiple different boards, where hardware settings are absorbed by the device tree overlay (".overlay"), application parameters can be flexibly changed and features can be easily enabled or disabled using board-specific Kconfig files (".conf").   ========================== We are currently unable to respond to comments left in the "Comment" section of this post. We apologize for the inconvenience, but please refer to "Technical Questions to NXP - How to Contact Us (Japanese Blog)" when making inquiries. (If you are already an NXP distributor or have a relationship with NXP, you may ask your representative directly.) This document provides an overview of the device tree and Kconfig, features designed to enhance Zephyr's software reusability. It then outlines the steps required to utilize these features in practice. After reading through this Zephyr series, from the first installment to the fourth, you will be able to write programs using the Zephyr RTOS. General Purpose Microcontrollers MCX Japanese Blog
View full article
2026年十大免费立即获得Adopt Me宠物的方法 如果你玩过 Roblox 的 Adopt Me 游戏,你肯定知道收集稀有、传奇和超稀有宠物是多么令人兴奋。从龙和独角兽到独特的活动宠物,打造强大的宠物收藏是游戏中最令人愉悦的部分之一。然而,并非所有人都愿意花费 Robux 来扩充存货。好消息是,有很多合法途径可以免费获得 Adopt Me 宠物,而无需花费真金白银。 ➤➤ 点击此处 在本指南中,我们将探讨获得免费 Adopt Me 宠物的 10 种最佳方法,并帮助您安全有效地扩充您的宠物收藏。 1. 完成每日登录奖励 获得免费 Adopt Me 宠物最简单的方法之一就是每天登录游戏。Adopt Me 会奖励活跃玩家每日连胜奖励,包括游戏币、物品,以及偶尔获得蛋的机会。 保持连续登录的时间越长,获得的奖励就越多。坚持不懈是关键,随着时间的推移,这些奖励可以帮助你购买能孵化出珍贵宠物的蛋。 2.孵化免费蛋 在《Adopt Me》游戏中,鸡蛋是宠物的主要来源。玩家可以使用游戏过程中获得的金币购买各种彩蛋。最受欢迎的选择包括裂纹蛋、宠物蛋和皇家蛋。 通过参与日常活动并积累 Robux,您可以不断购买鸡蛋而无需花费 Robux。每个蛋都有机会免费孵化出稀有和传说级宠物。 3. 参与季节性活动 Adopt Me 经常在节假日和重大庆典期间举办特别活动。这些活动通常会推出限时宠物,这些宠物可以通过游戏挑战获得,而不是用 Robux 购买。 万圣节、圣诞节、复活节和夏季活动尤其受到希望获得免费 Adopt Me 宠物的玩家的欢迎。完成活动任务并收集活动货币,即可在活动结束前解锁专属宠物。 4. 与其他玩家进行明智的交易 交换宠物是扩充宠物收藏的最佳途径之一。即使你没有传奇宠物,你也可以通过策略性地交易普通和不常见的宠物来逐步提升。 寻找愿意交换重复宠物或需要你拥有的特定物品的玩家。随着时间的推移,明智的交易可以帮助你获得原本难以获得的宠物。 务必使用官方游戏内交易系统,避免参与任何承诺在游戏外免费赠送宠物的骗局。 5. 完成任务赚取金币 Adopt Me 提供多种活动,玩家可以通过这些活动获得游戏币奖励。喂养宠物、上学、露营、洗澡以及完成其他日常任务都能产生收入,这些收入可以用来购买鸡蛋。 你越活跃,积累积分的速度就越快。许多经验丰富的玩家只需定期完成任务就能赚取数千美元,从而每周可以孵化多个蛋。 6. 参加赠品活动 许多 Adopt Me 内容创作者会在 YouTube、Discord 和社交媒体等平台上举办赠送活动。这些赠品通常包括传奇宠物、稀有蛋和珍贵物品。 参加任何抽奖活动之前,请务必确认该活动是由信誉良好的主办方举办的。正规的赠送活动绝不会要求您提供密码或帐户信息。参与信誉良好的赠送活动是获得免费 Adopt Me 宠物的绝佳途径。 7. 提升宠物等级和年龄 玩家通常更看重已经长大的宠物,而不是刚出生的宠物。通过花时间完成各种任务来加速宠物的成长,可以显著提高它们的交易价值。 一只成年宠物在交易中可能值多只幼年宠物。这种策略可以让你把普通宠物变成更好的机会,最终无需花费 Robux 就能获得更稀有的宠物。 8. 加入活跃的 Adopt Me 社区 对于想要免费获得宠物的玩家来说,Adopt Me 社区可以成为宝贵的资源。Roblox 群组、Discord 服务器和社交媒体社区经常组织交易活动、比赛和社区赠送活动。 活跃的社区还会提供有关市场价值、即将发生的事件和安全交易方式的有用建议。参与这些社群活动可以为你带来一些你原本可能会错过的机会。 9. 充分利用最新更新 《Adopt Me》的每一次重大更新都会带来新的内容和机会。新的彩蛋、宠物、活动和游戏功能通常会让活跃玩家更容易获得丰厚的奖励。 请留意更新公告,并在新内容发布后立即参与。尽早参与有时可以帮助你在宠物变得稀有且备受追捧之前就获得它们。 10. 运用宠物管理策略 有效管理宠物可以增加你随着时间的推移获得更好宠物的机会。专注于同时培养多只宠物,高效完成任务,并尽可能节省金币。 许多成功的玩家会采用其他策略,例如同时照顾多只宠物或结合家庭游戏功能来最大化收益。更好的资源管理可以带来更多的蛋、更多的孵化,最终带来更多的免费宠物。 如何避免免费宠物骗局 在寻找免费的 Adopt Me 宠物时,你很可能会遇到声称可以提供即时传奇宠物的网站、视频或个人。请注意功能安全并遵守以下功能安全提示: 千万不要泄露你的 Roblox 密码。 避免访问声称可以免费获得宠物的网站。 请仅使用官方的Adopt Me交易系统。 参与抽奖活动前,请先核实主办方信息。 在您的 Roblox 帐户上启用双重身份验证。 请记住,合法的免费宠物只能通过游戏、交易、活动和可信的社区活动获得。 结束语 免费获得 Adopt Me 宠物不需要花费 Robux。通过每日登录、完成任务、参与活动、孵化蛋、参加赠送活动以及明智地进行交易,您可以稳步建立起令人印象深刻的宠物收藏。 最成功的玩家会将这些方法中的几种结合起来,并保持活跃在游戏中。随着时间的推移,耐心和坚持不懈可以帮助你解锁稀有、超稀有甚至传奇宠物,而无需花费真金白银。 无论你是正在寻找第一只宠物的新手,还是想要扩充收藏的老玩家,这 10 种免费获得 Adopt Me 宠物的方法都能帮助你享受 Adopt Me 的一切乐趣,同时还能省钱。
View full article
S32K39-37-36 – eFlexPWM/TRGMUX/BCTU/SAR-ADC/DMA – [RTD600] 摘要 本示例基于 RTD 低级 API,在 S32K39-37-36 系列上使用 eFlexPWM、TRGMUX、BCTU、SAR-ADC 和 DMA 模块,展示了一个带有死区插入和硬件 ADC 触发的互补 PWM 输出的用例,以支持多样化的应用需求。 连接: S32K396-BGA-DC1 -> 引脚 -> 信号 -> 标签 J62-1 -> PTC30 -> siul2_gpio_94 -> GPIO1_GPT J62-5 -> PTD2 -> pwm_0_a, 2 -> PWM1 J62-6 -> PTD3 -> pwm_0_b, 2 -> PWM2 J62-30 -> PTD24 -> pwm_0_a, 0 -> PWMT J62-2 -> PTC31 -> siul2_gpio_95 -> GPIO3_BTCU_Trigger J62-4 -> PTD6 -> siul2_gpio_102 -> GPIO4_BTCU_Watermark J62-24 -> PTB14 -> adc1_s21 -> ADC1 *要连接 S32X-MB 的电位器: J62-24(在 S32K396-BGA-DC1 中)连接到P26-1(在 S32X-MB 中) 注意: 每次在配置工具中更新代码时,应在项目 /generate/src/Bctu_Ip_PBcfg.c 中添加以下行: #define DMA_LOGIC_CH_0 ((uint8)0U) 详细说明: GPT eMIOS 0 通道 0 的比较值生成一个超时周期。达到超时时间后,其 eMIOS 通知会切换 GPIO1。这使我们能够在示波器中观察到两个事件,这两个事件描述了信号序列的开始和结束。 eFlexPWM0 模块用于生成 PWM 和硬件 ADC 触发。 eFlexPWM0子模块2用于生成中心对齐的互补PWM输出(PWM1和PWM2),并插入死区时间。 eFlexPWM0 子模块 0 生成另一个独立的 PWM 输出 (PWMT),并用于在同一个 PWM 周期内生成模拟数据捕获的触发信号——在本例中,该触发信号在 PWM 高电平持续时间的一半时发生——使用 VAL0 寄存器。 BCTU 使用 ADC0 和 ADC1 实现并行转换列表。该列表由 eMIOS 通道触发,所得数据存储在 FIFO1 中,具体如下: • ADC0: VREFH_ChanNum51 -> BANDGAP_ChanNum48 • ADC1: VREFL_ChanNum50 -> S21_ChanNum45 为了调试,每次 BCTU 触发通知时都会切换 GPIO3。此外,每次 FIFO 中有效条目数超过水位线水平时,都会发生 BCTU 水位线通知,此时会切换 GPIO4,因此数据可供读取。 详见 图 1的完整信号序列: 图 1 示例项目的信号 当您暂停调试会话时,在“表达式”选项卡(图 2)中可以观察到结果:g_fifo1Result 对应 BCTU 列表测量值,而 g_fifo1Volts 对应以伏特为单位的转换值。 图 2. 示例项目的“表达式”选项卡 参考文献 S32 Design Studio for S32 Platform 实时驱动(RTD) S32K39、S32K37和S32K36数据手册[S32K39-S32K37-DS] S32K39、S32K37和S32K36参考手册 [S32K396RM] S32K344 到 S32K39/S32K37 迁移指南 [AN14301] S32K39/37/36电气化微控制器评估板[S32K396-BGA-DC1] 用于实时域控制和驱动的 S32X-MB I/O 扩展评估板 [S32X-MB] S32K39-37-36 – eMIOS/BTCU/SAR-ADC/DMA – [RTD600] [S32K 知识库] 应用软件: - S32K396_RTD600_eFlexPWM_TRGMUX_BCTU_SARADC_DMA 示例通过以下 IDE 和驱动程序版本构建和测试: - S32 Design Studio for S32 Platform 版本 3.6.3 - S32K3_S32M27x 实时驱动程序 ASR R21-11 版本 6.0.0
View full article
emiOS GPT 中断未触发(EDGE COUNTER + GPT 配置) 您好, 我正在使用 RTD 6.0.0 处理 S32K344。 我的要求是测量输入 PWM 频率(0 Hz 至 ~10 kHz),以便计算速度。 为此,我在 EDGE COUNTER 模式下使用 eMIOS ICU,以避免每个边沿中断并减少 CPU 负载,并将 eMIOS GPT 作为周期性定时器(100 毫秒或 1 秒),在 GPT 回调中读取边沿计数并计算频率,目的是只使用一个中断(GPT)。   但是,尽管 GPT 计时器似乎配置正确,但中断并未触发 —— emios0_0_irqHandler () 从未被调用,也没有执行 gpt_emiosNotification () 回调。 我附上我的配置以供参考。 能否请您帮忙找出可能遗漏或不正确的地方?   此外,如果能就如何在 S32K3 上精确测量 0-10 kHz 范围内的 PWM 频率(尤其是包括极低频)的最佳方法提出建议,我将不胜感激。 我已经尝试过其他模式,如 ICU_MODE_SIGNAL_MEASUREMENT、ICU_MODE_SIGNAL_EDGE_DETECT 和时间戳模式,但仍面临计数器溢出(16 位限制 ~65535)和极低频率下读数不准确等问题。 预先致谢 Re: eMIOS GPT interrupt not triggering (EDGE COUNTER + GPT configuration) 你好@kapidlitap 关于您的配置,我有几点看法: 您正在将 eMIOS0 通道 0 配置为 GPT。但是,在中断控制器 (intCtrl_IP) 中,你启用了 emios0_0_IRQN 并分配了处理程序 emios0_0_IRQHandler。这与配置通道相关的中断不一致。 根据 S32K344_COMMON.h 中定义的 Interrupt_vector_numbers,映射如下: EMIOS0_0_IRQn = 61, /**< Interrupt request 23,22,21,20 */ EMIOS0_1_IRQn = 62, /**< Interrupt request 19,18,17,16 */ EMIOS0_2_IRQn = 63, /**< Interrupt request 15,14,13,12 */ EMIOS0_3_IRQn = 64, /**< Interrupt request 11,10,9,8 */ EMIOS0_4_IRQn = 65, /**< Interrupt request 7,6,5,4 */ EMIOS0_5_IRQn = 66, /**< Interrupt request 3,2,1,0 */ 根据这一映射,eMIOS0 通道 0 属于中断组 EMIOS0_5_IRQn,而不是 EMIOS0_0_IRQn。因此,应使用正确的中断配置: IRQn:EMIOS0_5_IRQn 处理程序:EMIOS0_5_IRQHandler(请参阅 Emios_Mcl_Ip_Irq.c)。 关于输入捕获,有几个可用的示例。请查看并选择最符合您预期功能的选项。 使用 EMIOS DS3.5 RTD300 的 IP S32K312 PWM ICU 示例 示例:S32K312 EMIO PWM 生成及使用中断捕获占空比 (DS3.5 RTD300) 示例 IP S32K312 EMIO PWM Generation & 使用轮询进行占空捕获 DS3.5 RTD300 带 DMA S32DS 3.6.2 的 S32K344 eMIOS Icu 示例RTD 6.0.0 BR、VaneB
View full article
S32K312 – PTB2 の外部割り込み (EIRQ_10) がトリガーされない NXPコミュニティの皆様、こんにちは。 RTD 4.0.0 (AUTOSAR 4.7)、S32 Design Studio 3.6.6 を使用して、S32K312 (100ピン HDQFP) に外部割り込みを実装しています。PTB2 (ピン 48) をターゲットに → EIRQ_10。私は、PTB26 → EIRQ_13を使用するNXPコミュニティのサンプル(S32K312_EIRQ_interrupt)を参照し、それをPTB2向けに改変しました。しかし、割り込みコールバックは決してトリガーされません。 IOMUXテーブル(S32K312_IOMUX.xlsx)を確認しました。そして、PTB2がSIUL_IMCR538(インデックス26)、SSS=0001(ALT1)を介してEIRQ[10]に正しくマッピングされていることを確認しました。したがって、ピンルーティングの値は正しいようです。 100ピンS32K312でPTB2(EIRQ_10)を使用する際のガイダンスや動作例があれば、大変ありがたいです。 よろしくお願いします。 Re: S32K312 – External Interrupt (EIRQ_10) on PTB2 Not Triggering こんにちは、 以下のThreadで返信しました。 https://community.nxp.com/t5/S32K/S32K312-External-Interrupt-EIRQ-10-on-PTB2-Not-Triggering/td-p/2376810 よろしくお願いいたします。 ピーター Re: S32K312 – External Interrupt (EIRQ_10) on PTB2 Not Triggering こんにちは、ピーターさん。 ご提案ありがとうございます。 推奨レジスタを確認したところ、以下の実行時値が得られました。 DISR0 = 0 DIRER0 = 1024 (0x00000400)、ビット10有効 IREER0 = 1024 (0x00000400)、ビット10有効 IFEER0 = 0(立ち上がりエッジ構成) IMCR[26] = 1 (ALT1) NVIC ISER1 = 4194304 (0x00400000)、IRQ54 (SIUL_IRQ1) に対応、ビット22有効 ハードウェア入力パスも確認しました。 PTB2はEIRQ10として設定されています。 PTB2の入力状態の読み取りは正しく動作します。 PTB2に外部信号が印加されると、ピンは論理「1」を読み取ります。 信号が除去されると、ピンは論理「0」を読み取ります。 しかし、入力状態は正しく変化しているにもかかわらず、 DISR0のビット10は決してセットされない。 SIUL_IRQ1 ISRは実行されません。 登録されたコールバック関数は実行されません。 これらの観察結果から、以下のことが明らかになった。 物理的な入力信号はPTB2に正しく到達します。 IMCRルーティングは想定どおりに設定されています。 割り込みイネーブルレジスタは正しく設定されています。 NVICのイネーブルビットが設定されています。 しかし、EIRQ10イベントはSIUL2割り込みステータスフラグを生成しないため(DISR0ビット10は0のまま)、ISRは呼び出されません。 次に確認すべきSIUL2/EIRQレジスタはどれか、あるいはS32K312のPTB2→EIRQ10に関して、ピン入力状態が正しく変化しているにもかかわらずDISR0がアサートされない原因となる既知の要件があるかどうか、ご教示いただけますでしょうか? さらに、 RTD 4.0.0 (AUTOSAR 4.7)、S32 Design Studio 3.6.6 を使用して S32K312 (100 ピン HDQFP)を使用しています。PTB2 → EIRQ10に関して、検証すべきデバイス固有の制限事項、SIUL2ルーティング要件、パッド特性、パッケージ固有の考慮事項、またはRTD構成の依存関係があるかどうか確認していただけますでしょうか? ピンの入力状態は正しく変化しているにもかかわらず、DISR0のビット10がセットされず、ISRが実行されないため、標準的なポート、ICU、NVICの設定以外に、S32K312固有のチェック方法についてご教示いただければ幸いです。 よろしくお願いします、 エサッキ
View full article
Is Fatal Blackout Worth Trying in 2026 My Honest Fatal Blackout Review After Researching It Fatal Blackout is gaining major attention in 2026 as more families search for practical ways to prepare for power outages, grid failures, and emergency situations without relying on extreme survival tactics. Created by combat veteran Teddy Daniels, the program focuses on realistic blackout preparedness strategies using simple step-by-step guidance designed for everyday households. Check the official Fatal Blackout guide and latest details here: What makes Fatal Blackout stand out is its beginner-friendly approach. Rather than promoting expensive bunkers or extreme “doomsday prepper” tactics, the guide focuses on affordable preparedness methods like backup power planning, water storage, food security, EMP protection, and home readiness. Many people appreciate that the information is broken down into simple actions that can realistically be implemented over time. See how Fatal Blackout works and what’s included in the system: In 2026, concerns around grid instability, cyber attacks, inflation, and supply chain disruptions have pushed preparedness into the mainstream. Fatal Blackout taps into this growing interest by offering a structured survival roadmap for people who want to feel more prepared without completely changing their lifestyle. So, is Fatal Blackout worth trying? For people looking for a practical preparedness blueprint with a realistic focus, the program may provide useful insights and organization. However, like any survival system, its value depends entirely on whether users actually apply the strategies consistently in real life.   Re: Is Fatal Blackout Worth Trying in 2026 My Honest Fatal Blackout Review After Researching It Fatal Blackout has been attracting considerable attention in 2026 as more households look for realistic ways to prepare for emergencies such as power outages, grid disruptions, and unexpected crisis situations without adopting extreme survivalist methods. Created by combat veteran Teddy Daniels, the program is built around practical blackout preparedness strategies presented in a clear, step-by-step format intended for everyday families. Explore the official Fatal Blackout website and view the latest details here: One of the main reasons Fatal Blackout stands out is its beginner-friendly structure. Instead of encouraging expensive bunkers or intense “doomsday prepper” lifestyles, the guide emphasizes affordable and achievable preparedness steps. These include backup power planning, water storage solutions, food security basics, EMP awareness, and general home readiness measures. Users often value how the information is broken down into simple, manageable actions that can be implemented gradually over time. Discover how Fatal Blackout works and what the system includes:  In 2026, preparedness has become a mainstream topic due to growing concerns about grid reliability, cyber threats, rising living costs, and ongoing supply chain uncertainties. Fatal Blackout aligns with this shift by offering a structured framework that helps individuals and families feel more confident about handling potential disruptions while still maintaining a normal lifestyle. Yes, Fatal Blackout can be a useful option for those looking for a straightforward, well-structured preparedness guide focused on real-world scenarios. It offers clear direction and practical insights, and its value is best realized through consistent use of the strategies in everyday life, helping users gradually build stronger home readiness and preparedness confidence over time.
View full article
GD3160がSPI経由でレジスタに書き込み、ゲート出力が歪む おはようございます。NXPのGD3160をSPI経由で設定するのに苦労しています。データシートを長い間読み込んできましたが、GD3160のSPIと制御の動作をまだ理解できていません。私の主な問題は次の2つにまとめられます。1つ目は、2つのGDのデイジーチェーンから(少なくとも私が思うに)正常に読み取ることができるのですが、何も書き込むことができません。特にMODE2レジスタのCONFIG_ENビットに書き込むことができません。私はArduino Unoを使用しています。私は自分のコードに対して様々なアプローチとテストを試しましたが、最もシンプルでクリーンなテストコードでも失敗するものを添付します。何が間違っているのか教えていただけますか?計算を二重チェックしたのですが、CRCの問題でしょうか?それともSPIの設定の問題でしょうか?仕様通り、MSBが先です。2- また、ゲートのGD PWM信号は、MOSFETが接続されていないデフォルト構成で、デューティサイクルが約50%のときにのみクリーンです。デューティサイクルを上下に変更すると、オシロスコープで測定されるデューティサイクル信号が位相シフトし、はるかに小さくなります。どこから探し始めればいいか、何かアイデアはありますか? Hブリッジドライバ HS|LS 設定可能ドライバー 絶縁型ゲートドライバ Re: GD3160 writing registers through SPI and distorted Gate output マフムード様、 電圧レベルと部品値が記載された回路図を共有してください。 SPIが正しく設定されていることを確認するために、オシロスコープのプローブをCS、MISO、MOSI、SCLKピンに接続し、オシロスコープの波形を共有してください。SPIタイミング要件については、GD3160のフルデータシートの図35を参照してください。アイドル時はクロックはローレベル(CPOL=0)である必要があり、データはSCLKの立ち下がりエッジで切り替えられ、SCLKの立ち上がりエッジでサンプリングされる必要がある(CPHA=0)。その結果、SPIモード0になります。 AN13167もダウンロードしてご参照ください。そこには、GD3160のSPIインターフェースに関するヒントがいくつか掲載されています。 敬具、 ヨゼフ Re: GD3160 writing registers through SPI and distorted Gate output ご返信ありがとうございます。返信するのをすっかり忘れていました。ハードウェアチームに回路図を依頼する必要があるが、いずれにせよ、仕様通りに動作するようにすることはできた。問題は、書き込み時に高電圧側の電源が失われた場合やラッチ障害が発生した場合にロックされることを知らなかったことだ。私が今懸念しているのはCONFIG_ENビットについてです。単に書き込みや読み出しを行うだけでは設定モードをアクティブ化できません。いろいろ試してみましたが、唯一うまくいったのはconfig_bitとRESETビットに同時に書き込むことでした。なぜ私はこのような経験をしているのでしょうか?なぜconfig_bitとreset bitの両方を書き込む必要があるのですか?仕様によると、reset bitだけに書き込んでもINTBをローに駆動する効果はありませんが、両方のビットに書き込むと効果があります。SPI通信が正しく行われていること、および書き込む値がずれていないことを確認しました(ビットインデックスとオフセットについては間違いありません)。どう思いますか? Re: GD3160 writing registers through SPI and distorted Gate output マフムード様、 リセットビットは、障害をクリアし、レジスタをデフォルトの状態にリセットするだけです。設定モードへの移行を妨げる障害が発生しているようです。これは、GD3160をリセットすると、障害が解消され、設定モードに入ることができるようになることを示唆しています。 STATUSレジスタに異常がないか確認してください。STATUS1、STATUS2、STATUS3レジスタ。 敬具、 ヨゼフ
View full article
PFE MCAL driver receiver processing may have reentrancy issue Hi Team From PFE MCAL driver 1.6.0, the receiver processing may have reentrancy issue. The call relationship of function pfe_hif_drv_process_rx_frames() is shown as the following figure.  The _Receive, TxConfirmation and MainFunction will call pfe_hif_drv_process_rx_frames when driver works in polling mode. If the callers are in different tasks, pfe_hif_drv_process_rx_frames has a risk of reentrancy. Should we add exclusive protection for pfe_hif_drv_process_rx_frames ? Regards, Ryder PFE PFE MCAL Re: PFE MCAL driver receiver processing may have reentrancy issue Hello @Ryder_Gong, The PFE team has picked up the case, also who is the customer that reported this? Best regards,  Radu Re: PFE MCAL driver receiver processing may have reentrancy issue Hi, The original issue is from Mobileye, actually software team has involved by a debug call. Re: PFE MCAL driver receiver processing may have reentrancy issue Hello Ryder.  Thank you for finding the race condition. It was confirmed as cause of the "Rx stops working" issue and bug ticket ANET-1032 was created to fix it. It will be fixed by adding an exclusive area protection as you have proposed. The bug affects all versions of the PFE MCAL driver, in polling mode, and it will be fixed in version 1.8.0.
View full article
Changing CAN interface configuration on KW47-EVK while using serial terminal Most available example applications use UART as the serial interface for terminal communication. This approach is commonly chosen because a terminal provides a simple and efficient method for interacting with the application during development and debugging. The KW47-EVK supports two CAN/CAN-FD interface; as well as two UART interfaces accessible through the onboard USB-to-UART bridge.  The corresponding SoC peripheral instances are CAN0 and CAN1 for the CAN/CAN‑FD interfaces, and LPUART0 and LPUART1 for the UART interfaces. Since the LPUART1 serial interface and the CAN1 interface are routed to the same pins (PTC2 and PTC3) at the board level, and both functions can be enabled through header configuration, external isolation is required to ensure correct operation and prevent interference from other onboard components. If CAN1 must be enabled and your application also requires a serial terminal interface, then LPUART0 must be used as the serial interface.To enable both CAN1 and LPUART0 on the KW47‑EVK, follow the steps below: Changes required on hardware CAN Node A CAN Node B Pin name Board jumper Pin name Board jumper CANH J21 - 1 CANH J21 - 1 CANL J21 - 2 CANL J21 - 2 GND J21 - 4 GND J21 - 4 P12V J21 - 3 P12V J21 - 3  Note: Plug in the 12V power supply on J9 to supply the P5V_CAN. LPUART0 interface connection Functionality Board jumper Connection configuration LIN_RX JP11 2 - 3 LIN_TX JP12 2 - 3 UART_RX_USB selector JP16 2 - 3 UART_TX_USB selector JP17 2 - 3 CAN_RX_1 selector JP56 1 - 2 CAN_TX_1 selector JP57 1 - 2   Changes required on software Note: These steps assume you are using a FlexCAN SDK example application. If your application requires enabling CAN1 instead of the default CAN0, update the following configuration in your project’s source code: 1. In board.c, modify the LPUART instance, kCLOCK_Lpuart1 -> kCLOCK_Lpuart0: /* Initialize debug console. */ void BOARD_InitDebugConsole(void) { uint32_t uartClkSrcFreq = 0U; /* Set LPUART0 clock source */ CLOCK_SetIpSrc(kCLOCK_Lpuart0, kCLOCK_IpSrcFro192M); uartClkSrcFreq = CLOCK_GetIpFreq(kCLOCK_Lpuart0); DbgConsole_Init(BOARD_DEBUG_UART_INSTANCE, BOARD_DEBUG_UART_BAUDRATE, BOARD_DEBUG_UART_TYPE, uartClkSrcFreq); } 2. In board.h, modify the LPUART instance definitions: BOARD_DEBUG_UART_BASEADDR LPUART1 -> LPUART0 BOARD_DEBUG_UART_INSTANCE 1U -> 0U BOARD_DEBUG_UART_CLK_FREQ kCLOCK_Lpuart1 -> kCLOCK_Lpuart0 /* The UART to use for debug messages. */ #define BOARD_USE_LPUART #define BOARD_DEBUG_UART_TYPE kSerialPort_Uart #define BOARD_DEBUG_UART_BASEADDR (uint32_t) LPUART0 #define BOARD_DEBUG_UART_INSTANCE 0U #define BOARD_DEBUG_UART_CLK_FREQ (CLOCK_GetIpFreq(kCLOCK_Lpuart0)) 3. In hardware_init.c, modify the CAN instance to CAN1 at FlexCAN functional clock configuration: void BOARD_InitHardware(void) { BOARD_InitPins(); BOARD_BootClockRUN(); BOARD_InitDebugConsole(); /* FRO192M is configured as CAN1 functional clock in this example but other clock options may be available */ CLOCK_SetIpSrc(kCLOCK_Can1, kCLOCK_IpSrcFro192M); CLOCK_SetIpSrcDiv(kCLOCK_Can1, kSCG_SysClkDivBy1); } 4. In app.h, modify the EXAMPLE_CAN definition to CAN1: #define EXAMPLE_CAN CAN1 #define USE_CANFD (1) #define RX_MESSAGE_BUFFER_NUM (0) #define TX_MESSAGE_BUFFER_NUM (1) 5. In pin_mux.c, modify pin multiplexing configuration to enable CAN1 and LPUART0 pins respectively. You can copy and paste the below code to replace BOARD_InitPins function: void BOARD_InitPins(void) { /* Clock Config: Peripheral clocks are enabled; module does not stall low power mode entry */ CLOCK_EnableClock(kCLOCK_PortA); CLOCK_EnableClock(kCLOCK_PortC); const port_pin_config_t porta16_pin11_config = {/* Internal pull-up/down resistor is disabled */ (uint16_t)kPORT_PullDisable, /* Low internal pull resistor value is selected. */ (uint16_t)kPORT_LowPullResistor, /* Fast slew rate is configured */ (uint16_t)kPORT_FastSlewRate, /* Passive input filter is disabled */ (uint16_t)kPORT_PassiveFilterDisable, /* Open drain output is disabled */ (uint16_t)kPORT_OpenDrainDisable, /* Low drive strength is configured */ (uint16_t)kPORT_LowDriveStrength, /* Normal drive strength is configured */ (uint16_t)kPORT_NormalDriveStrength, /* Pin is configured as LPUART0_RX */ (uint16_t)kPORT_MuxAlt6, /* Does not invert */ (uint16_t)kPORT_InputNormal, /* Pin Control Register fields [15:0] are not locked */ (uint16_t)kPORT_UnlockRegister}; /* PORTA16 (pin 11) is configured as LPUART0_RX */ PORT_SetPinConfig(PORTA, 16U, &porta16_pin11_config); const port_pin_config_t porta17_pin12_config = {/* Internal pull-up/down resistor is disabled */ (uint16_t)kPORT_PullDisable, /* Low internal pull resistor value is selected. */ (uint16_t)kPORT_LowPullResistor, /* Fast slew rate is configured */ (uint16_t)kPORT_FastSlewRate, /* Passive input filter is disabled */ (uint16_t)kPORT_PassiveFilterDisable, /* Open drain output is disabled */ (uint16_t)kPORT_OpenDrainDisable, /* Low drive strength is configured */ (uint16_t)kPORT_LowDriveStrength, /* Normal drive strength is configured */ (uint16_t)kPORT_NormalDriveStrength, /* Pin is configured as LPUART0_TX */ (uint16_t)kPORT_MuxAlt6, /* Does not invert */ (uint16_t)kPORT_InputNormal, /* Pin Control Register fields [15:0] are not locked */ (uint16_t)kPORT_UnlockRegister}; /* PORTA17 (pin 12) is configured as LPUART0_TX */ PORT_SetPinConfig(PORTA, 17U, &porta17_pin12_config); const port_pin_config_t portc2_pin39_config = {/* Internal pull-up/down resistor is disabled */ (uint16_t)kPORT_PullDisable, /* Low internal pull resistor value is selected. */ (uint16_t)kPORT_LowPullResistor, /* Fast slew rate is configured */ (uint16_t)kPORT_FastSlewRate, /* Passive input filter is disabled */ (uint16_t)kPORT_PassiveFilterDisable, /* Open drain output is disabled */ (uint16_t)kPORT_OpenDrainDisable, /* Low drive strength is configured */ (uint16_t)kPORT_LowDriveStrength, /* Normal drive strength is configured */ (uint16_t)kPORT_NormalDriveStrength, /* Pin is configured as CAN1_RX */ (uint16_t)kPORT_MuxAlt11, /* Does not invert */ (uint16_t)kPORT_InputNormal, /* Pin Control Register fields [15:0] are not locked */ (uint16_t)kPORT_UnlockRegister}; /* PORTC2 (pin 39) is configured as CAN1_RX */ PORT_SetPinConfig(PORTC, 2U, &portc2_pin39_config); const port_pin_config_t portc3_pin40_config = {/* Internal pull-up/down resistor is disabled */ (uint16_t)kPORT_PullDisable, /* Low internal pull resistor value is selected. */ (uint16_t)kPORT_LowPullResistor, /* Fast slew rate is configured */ (uint16_t)kPORT_FastSlewRate, /* Passive input filter is disabled */ (uint16_t)kPORT_PassiveFilterDisable, /* Open drain output is disabled */ (uint16_t)kPORT_OpenDrainDisable, /* Low drive strength is configured */ (uint16_t)kPORT_LowDriveStrength, /* Normal drive strength is configured */ (uint16_t)kPORT_NormalDriveStrength, /* Pin is configured as CAN1_TX */ (uint16_t)kPORT_MuxAlt11, /* Does not invert */ (uint16_t)kPORT_InputNormal, /* Pin Control Register fields [15:0] are not locked */ (uint16_t)kPORT_UnlockRegister}; /* PORTC3 (pin 43) is configured as CAN1_TX */ PORT_SetPinConfig(PORTC, 3U, &portc3_pin40_config); } Run your demo application Connect a USB cable between the host PC and the KW47-EVK board J14. Open a serial terminal on PC for each board with the following settings: 115200 baud rate 8 data bits No parity One stop bit No flow control Download the program to the target board Either press the reset button on your board or launch the debugger in your IDE to begin running the demo.
View full article
Zephyr SDK install error in Windows: setup.cmd Toolchain download failed Recently some Windows users started reporting issues installing the Zephyr SDK, required for building Zephyr applications.  Users first ran into this issue using NXP's MCUXpresso Installer, but had the same issue trying to manually install the Zephyr SDK. The root cause is that setup.cmd and these other tools use wget to download the individual toolchain packages.  And apparently recent changes in Windows or security settings interpret this wget download as unsecure, and wget is blocked. Context The Zephyr SDK is a package of multiple toolchains that support all the hardware platforms and CPU architectures available in Zephyr.  The binary bundle releases for download are available in two options: Minimal and Full.  For example, these bundles can be downloaded here for v0.17.4, currently the latest release. The Full bundle is a large download and includes all the toolchains and other tools in that download package.  The Minimal bundle is much smaller and does not contain any toolchains and allows users to choose the toolchains to download and install.  Minimal has an extra step after download to run the setup script and the user selects the tools to download.  In Windows, this script is setup.cmd. If installing the Minimal bundle and wget downloads are blocked for setup.cmd, then the Zephyr SDK install fails.  MCUXpresso Installer v25.12 and other install options use the Minimal bundle, and can be blocked by this issue. Workaround NXP is working on improving the MCUXpresso Installer to address this issue.  But in the meantime, downloading and installing the Full bundle avoids using wget and avoids this issue.   Download the Full bundle, here for v0.17.4, and extract the bundle in your user folder.  After extracting, the full Windows path will be  C:\Users\ \zephyr-sdk-0.17.4 .  West and other build tools will find this folder during the build.  The Zephyr SDK can also be installed elsewhere using an environment variable, see the Zephyr SDK documentation.  After extracting, run the setup.cmd to finish setup.  But with the Full install, setup.cmd will not need to download with wget. Be aware, this article was written when v0.17.4 was the latest release of the Zephyr SDK.  Check here for the latest release. Return to Zephyr Knowledge Hub
View full article
S32K3 FLEXIO data exception I am using S32K314 RTD400 SAI0 (host) and FLEXIO analog I2S (slave) communication, SAI only use d0, MUX_DISABLE, word width of 16, found that the data received by the slave is the host's data cycle to move one bit left to get the data, such as sending 0x8002, in the code inside the slave get the data is 0x5, change a lot of configuration is useless, finally check the Enable User Mode Support in the figure below, the data is normal. For example, if you send 0x8002, the data received by the slave in the code is 0x5. After changing a lot of configurations, the data is normal after checking Enable User Mode Support in the following figure. The SAI configuration is as follows Re: S32K3 FLEXIO数据异常 Hi@Jason22 I checked the compilation results, this option you check or uncheck does not affect the results of the run at all. According to the project you provided, the compilation I got with Enable User Mode Support checked and unchecked is exactly the same, which means it doesn't cause the problem you described. Re: S32K3 FLEXIO数据异常 Compile no problem, there is no "Mcal.h" file, if so, clear the project, compile again and there will be no problem (I do not know if this is the IDE version of the problem, S32DS 3.6 does not seem to have this error). If it's not this error, can you tell me what's wrong with the compilation? Re: S32K3 FLEXIO数据异常 Hi@Jason22 Sorry, I read it wrong, it's not the IDE version, it's that I read Enable User Mode Support as Enable Flexio Common Support Can you double check the project you provided, I can't get it to compile successfully. Re: S32K3 FLEXIO数据异常 没有勾选“Enable User Mode Support”,配置还是有效 不勾选"Enable Flexio Common Support",配置才无效,我使用的是S32DS 3.5.14,这和S32DS版本有关嘛 Re: S32K3 FLEXIO数据异常 Hi@Jason22 你不勾选“Enable User Mode Support”下面的配置不是不生效了嘛 Re: S32K3 FLEXIO数据异常 Hi@Jason22 Logic analyzer yourself to test if the data you're sending out is correct or not Re: S32K3 FLEXIO数据异常 I also compared it and found the same thing, re-ran the program and found that after checking the box, the data looped left again, but the first time I checked the box, the data did go normal, and repeated the run a few times and it was normal, so I don't know what factors are causing this. Then I would like to ask, is it my configuration or the code has a problem, why the data received by the slave is just the result of the data sent by the host cyclic left shift? Thanks for your help. Data sent by the host Data received from the slave
View full article
如何安装"S32ZE_R52_NXP_RTOS_4_7_181_RTM_1_1_0_D2412_DesignStudio_updatesite.zip" 您好, 我从 GreenVIP 安装了"S32ZE_R52_NXP_RTOS_4_7_181_RTM_1_1_0_D2412_DesignStudio_updatesite" ,但在下面的截图中找不到它。 如果我再次安装,就会出现错误提示。 请帮帮我。 谢谢! Re: How to install "S32ZE_R52_NXP_RTOS_4_7_181_RTM_1_1_0_D2412_DesignStudio_updatesite.zip" 你好,Lvyang508 感谢您的回复。 您是否安装了 SW32ZE_RTD_R21-11_2.0.1_D2505_? 在 S32DS IDE 中使用 DesignStudio_updatesite.zip? BR 乔伊 Re: How to install "S32ZE_R52_NXP_RTOS_4_7_181_RTM_1_1_0_D2412_DesignStudio_updatesite.zip" S32DS IDE:S32DS for Platform 3.6.5 我下载了相应的软件包并根据 UG_S32ZE_GreenVIP.pdf 进行了安装 Re: How to install "S32ZE_R52_NXP_RTOS_4_7_181_RTM_1_1_0_D2412_DesignStudio_updatesite.zip" 你好,Lvyang508 请检查您的 RTD 版本,RTD 和 RTOS 软件包之间似乎存在冲突。 另外,您使用的是什么版本的 S32DS 集成开发环境? BR 乔伊 Re: How to install "S32ZE_R52_NXP_RTOS_4_7_181_RTM_1_1_0_D2412_DesignStudio_updatesite.zip&&&& 嗨,乔伊、 我已经安装了 SW32ZE_RTD_R21-11_2.0.1_D2505_。 S32DS 集成开发环境中的 DesignStudio_updatesite.zip 文件。 谢谢您! Re: How to install "S32ZE_R52_NXP_RTOS_4_7_181_RTM_1_1_0_D2412_DesignStudio_updatesite.zip&&&& 你好,Lvyang508 感谢您的回复。 这个问题可能是由版本冲突引起的。请尝试使用 S32DS IDE 3.6.1 参考 UG_S32ZE_GreenVIP.pdf。 BR 乔伊 Re: How to install "S32ZE_R52_NXP_RTOS_4_7_181_RTM_1_1_0_D2412_DesignStudio_updatesite.zip&&&& 嗨,乔伊、    感谢您的回复。 我已经安装了 S32IDE 3.6.1、但问题依然存在。 BR、
View full article
CSEc Error I'm using CSEc with S32K144, when does it return KEY_INVAILD error at BOOT_DEFINE? I hope to get answers and have a happy day! Re: CSEc Error Hi @xiaozhi  I can't see a reason for such error when calling BOOT_DEFINE function. This function can be called even if BOOT_MAC_KEY is not provisioned yet, so it does not require a key.  Regards, Lukas
View full article
S32N55:充当 GM 时 gPTP 桥接设备中的序列 ID 队员们好 我正在测试gpTP示例中的网桥设备行为。我使用的是 GrayVIP_1_0_22_0。 根据《用户手册》,如果网桥在 启动超时则应开始作为 GM 运行。但我观察到,在这种情况下,同步和同步跟进帧中的序列 ID 都保持在 1024,不会增加。 检查相关代码后,我发现当网桥转换到 GM 模式时,用于生成同步信息的序列 ID 取自 prSyncMachines[prDomain->u8SlaveMachineId].u16SequenceId 从端口的序列号。 如果从端口没有收到任何同步报文,则该值永不更新,这将导致主端口发送的同步报文中的序列 ID 保持不变。 这种行为表明,在这种机制下,桥梁无法正常发挥全球机制的作用。 能否请您解释一下,为什么大桥的设计会出现这种情况? BR, Bridget GPTP_STACK Re: S32N55: sequence ID in gPTP bridge device when acting as a GM 你好,@Bridget、 我们的团队已经受理了一个案件,并将尽快提供答复 ,致以最崇高的敬意, Radu Re: S32N55: sequence ID in gPTP bridge device when acting as a GM 嗨,@Bridget、 我们正在努力重现该问题,并将在团队中讨论进一步的步骤。我会再联系你的。 谢谢, Lukas Re: S32N55: sequence ID in gPTP bridge device when acting as a GM @Bridget、 事实证明,gPTP 网桥的这种行为是有意为之,符合 802.1as 标准。 网桥应转发主端口上接收到的序列 ID。如果Grand Master丢失,序列ID确实会停止更新——这是下游设备能够分辨GM何时丢失的方式之一。 对于本来就没有总经理的桥梁,序列 ID 按标准是随机的。我们对 "随机"的解释是,序列 ID 的任何内容都不能保证,也不应假设。硬编码的 1024 被认为符合这一要求(可以是任何其他数字)。 序列 ID 是否会导致应用程序出现问题?正如您所观察到的,无论序列 ID 如何,端点都完全能够与网桥同步。 抱歉花了这么长时间。如果有不清楚的地方,请告诉我。 BR, Lukas
View full article
LS1046A RDB:用于测试 linux gpio 中断处理性能的 GPIO 您好, 我正在使用 LS1046ARDB,想测量中断延迟。我的目标是通过外部信号发生器(输入 GPIO)触发信号中断,然后切换另一个引脚(输出 GPIO)作为响应,用示波器测量延迟。 我正在寻找板接头上可以混合为 GPIO 的可访问引脚。 我的想法是使用 IEEE-1588 接头 (J11),但不确定这是否可行,也不知道需要做些什么。 参考手册指出,可以通过 RCW(EC2=1)将 EC2 引脚配置为 GPIO3。 如果我在 RCW 中设置 EC2=1,这些信号是否会路由到 J11? LS1046A RDB 上是否有其他易于访问的引脚可供使用? 感谢您的帮助 QorIQ LS1设备 Re: LS1046A RDB: GPIOs for testing gpio interrupt handling performance of linux 谢谢您的帮助!这应该行得通。我发现GPIO_2[1]、GPIO_2[2]、GPIO_2[3] 与 TP14、TP13 和 TP11 相对应。 Re: LS1046A RDB: GPIOs for testing gpio interrupt handling performance of linux 您可以使用与 SPI 信号复用的GPIO。 GPIO_2[1]、GPIO_2[2]、GPIO_2[3] SPI 接口在 RDB 上未使用,并终止到测试点。 请参阅"表 3-8。详情请参阅 LS1046ARM 中的 SPI 信号配置" 。
View full article
在挂起期间将 GPIO 状态保持在 RAM 中 您好,NXP团队: 我们使用 s32g399ardb3 作为定制设计板的参考并使用 BSP35。 我有一个低电平有效的 GPIO (PB_12),默认情况下使用 P3_3V_IO3P3 拉高。 我关注了 电路板支持包 UM 第 " 23.3 章挂起到 RAM " 让板暂停到 RAM 中。 但 P3_3V_IO3P3 会在 PB_12 变为低电平时关闭。 目前,我们通过 Linux 内核驱动程序来控制 GPIO 的动态,但在添加挂起相关功能后,我仍将 GPIO 状态保持为高电平失败。 我应该在 ATF 中移动 GPIO 动态控制吗? 谢谢! Re: Keeping GPIO status during suspend to RAM hi,GG0712 感谢您的回复。 S32G 使用 I2C 控制 PMIC,一般来说,您可以在 A 核中操作 PMIC,但我们不提供相关代码和文档。 另外,PB_12 是 VDD_IO_B 功能域,如果你想拉出引脚,你应该是 VDD_IO_B 的电压。设置 VDD_IO_B 电压时,可以尝试对引脚 PB_12 进行内部上拉。 有关电源的更多信息,请参见 AN14063。 希望能帮到你。 BR 乔伊 Re: Keeping GPIO status during suspend to RAM 你好@Joey_z、 如果我们目前没有使用 M 内核,这种方法是否可行? 谢谢! Re: Keeping GPIO status during suspend to RAM hi,GG0712 感谢您的回复。 这是 M 核 PMIC 模块设置方法,使用 S32DS IDE,如下图所示。 它可以在待机模式下设置 LDO3 和其他 vr5510 输出电压。 此设置适用于 M Core,S32G 使用 I2C4 与 vr5510 连接。这就是使用 12C4 作为 A 核来保持 LDO3_3v3 的方法。 希望能帮到你。 BR 乔伊 Re: Keeping GPIO status during suspend to RAM 你好@Joey_z、 如何通过您的图片设置LDO3_3v3? 谢谢! Re: Keeping GPIO status during suspend to RAM hi、GG0712 感谢您的回复。 请参阅 RMS32G3.pdf 和附件 S32G_IOMUX.xlsx,在待机期间,PB_12 的焊盘状态被设置为掉电模式。 因此,我认为可以在待机阶段将引脚设置为高电平电压。 您可以尝试将 LDO3_3v3 设置为该引脚上拉,并将 vr5510 设置为保持 LDO3_3v3 的电压。 此外,您还可以尝试在待机阶段将唤醒引脚选择为高电平电压。 希望能帮到你。 BR 乔伊 Re: Keeping GPIO status during suspend to RAM 你好,Joey_z、 我们使用我们的设计板并使用 PB_12 作为 GPIO。 谢谢! Re: Keeping GPIO status during suspend to RAM hi,GG0712 感谢您与我们联系。 你使用 RDB3 板吗?您想使用 GPIO (PB_12) 作为 FLEX_LIN2_RX 的功能吗? BR 乔伊
View full article
NHS3152 上的 DAC 产生三角信号的 ADC 采集问题 我正在使用NHS3152设备通过 DAC 生成三角波形,并使用 ADC 测量该信号。配置如下 使用带有参数 ADCDAC_IO_ANA0_5 的函数 Chip_ADCDAC_SetMuxDAC 在引脚ANA0_5上配置 DAC 输出。 使用 Chip_ADCDAC_SetMuxADC 和参数 ADCDAC_IO_ANA0_3 在引脚ANA0_3上配置 ADC 输入。 一根电缆将 ANA0_5 物理连接到 ANA0_3,以使信号循环。 技术细节: 两个引脚的 IOCON 配置均设置为模拟模式 (IOCON_FUNC_1)。 DAC 在SINGLE_SHOT模式下运行,以在每次写入时更新输出,但切换到CONTINUOUS模式并不能解决问题 - 它只会稍微影响信号质量。 ADC 以连续模式运行,检测阈值设置为1500 (LOW_THRESHOLD)和2000 (HIGH_THRESHOLD)。 代码为三角波形(范围从 DAC_MIN_VALUE 到 DAC_MAX_VALUE)生成查找表 (LUT),并且 16 位计时器定期触发 DAC 更新。 尽管输出上可以清晰地观察到三角信号,但没有触发 ADC 中断,也没有记录 ADC 转换结果。 采取的故障排除步骤: 我已验证 MUX 选择功能(Chip_ADCDAC_SetMuxADC 和 Chip_ADCDAC_SetMuxDAC)使用正确的通道(ADC 为通道 3,DAC 为通道 5),如文档中所述(UM10876 手册第 9.4 章,图 90)。 我确认两个引脚的 IOCON 设置都正确设置为模拟模式(IOCON_FUNC_1),并且连接 ANA0_5 和 ANA0_3 的电缆已正确安装并具有公共接地。 我测试了修改 ADC 中断例程中 ADC 转换就绪标志(ADCDAC_INT_CONVERSION_RDY_ADC)的检查,但这并没有改变行为。 除了信号质量略有变化外,在 SINGLE_SHOT 和 CONTINUOUS 之间更改 DAC 模式对问题没有显著影响。 请求协助: 我希望您能帮助我了解: 考虑到它采用循环调度程序运行,通过模拟多路复用器使用两个不同引脚的当前配置对于 NHS3152 上的共享 ADCDAC 块是正确的。 还有一些其他限制(例如时序或配置序列问题)可能会阻止在此设置中触发 ADC 中断。 其他修改方法(例如以单次模式测试 ADC 或对 ADC 和 DAC 使用相同通道)可以解决该问题。 请参阅附件中用于此配置的完整代码。提前感谢您的帮助和建议。 问候, 托马斯 回复:NHS3152 上 DAC 生成三角信号的 ADC 采集问题 我想向您更新我所提交的票的情况。主要问题如下: DAC 产生的三角波形太快。这个快速信号没有给 ADC 足够的时间来正确捕获值。 我错误地使用了中断处理程序的错误名称。它必须命名为ADC_IRQHandler(void)而不是ADCDAC_IRQHandler(void) 。 降低频率(或增加每个周期的样本数)并重命名中断例程后,ADC 开始按预期工作。
View full article
KW45B41Z RTC not running during power off (Power backup given by super capacitor) The RTC is retaining its value in the KW45B41Z-EVK during power off when power back up is provided by Coin cell battery, but in i am using KW45B41Z for my project where i am using a super capacitor(25F/3.8V) to power RTC during power off. Here RTC is not retaining its value. So do I need to enable any Low power mode through SPC or is there any special configuration that i should do? I have also verified the voltage across the super capacitor that is enough to power the RTC during power off. Any low power mode configurations are there for RTC? Regards Kaif Re: KW45B41Z RTC not running during power off (Power backup given by super capacitor) According to the EVK schematics, the VDD_DCDC pin powers the RTC when JP5 pins 2 and 3 are connected. With this configuration, the RTC functions correctly on the EVK. We observed that the RTC draws approximately 1 mA in this setup. When we replicate this arrangement on our custom board using a supercapacitor, the supercapacitor discharges very quickly. We specifically chose a supercapacitor because we required a rechargeable power source capable of maintaining RTC operation for at least 1–2 months, which is typical for RTC applications. However, a coin cell was not considered suitable since it is not rechargeable. Re: KW45B41Z RTC not running during power off (Power backup given by super capacitor) Hello What values are you getting from voltage across the capacitor? As if goes to a very low voltage (from the capacitor discharging) or approximates to minimal values according to Datasheet, it may cause abnormal functionality such as loss of RTC Functionality: The most immediate consequence is that the RTC will likely stop operating reliably. The timekeeping accuracy will be compromised, and any data stored in the RTC's backup registers may be lost. A coin cell offers a stable and nearly constant voltage over most of its lifespan, which ensures that the RTC always receives a voltage above its minimum operating threshold. Best Regards Luis Re: KW45B41Z RTC not running during power off (Power backup given by super capacitor) I am using kw45b41zevk_rtc demo (not rtc_func or power mode switch as in AN14122). Instead of Coin Cell (as in KW45B41Z EVK) I am using a super capacitor for RTC Power Backup. During power on RTC will be powered by VDD_SWITCH but during power off, super capacitor will supply power to RTC.  During power off Super capacitor is discharging (tested) but RTC is not retaining its register value. I have attached the schematics of RTC supply configuration i am using.  Why in the KW45B41Z EVK coin cell backup is given for RTC why there is no rechargeable source like super capacitor or battery? Re: KW45B41Z RTC not running during power off (Power backup given by super capacitor) Hello Kaif, As shown in the KW45B41Z-EVK, the coin cell or lithium battery will be the preferred methods, this to achieve long battery life and voltage stability. Regarding the RTC not retaining values, Could you please kindly describe what is the procedure you are using for the configuration and test? By any chance, are you using the demo called "rtc_func" or power_mode_switch as in AN14122? Also please consider the recommendations mentioned in the AN14122 to start the RTC from a low-power mode. Best Regards Luis Re: KW45B41Z RTC not running during power off (Power backup given by super capacitor) I am using KW45B41Z in custom board with back up power using super capacitor. Can we use super capacitor to power RTC during power off? or Lithium battery is the only way? I would really appreciate your support on this. Regards  Kaif Re: KW45B41Z RTC not running during power off (Power backup given by super capacitor) Hello, Could you help us confirm if you are using a custom board with the KW45B41Z or the KW45-EVK? The Application note 14122 describes how to integrate the RTC feature to a low-power application with the KW45 and explains the file modifications needed to implement it. AN14122: How to use RTC on KW45-EVK | NXP Semiconductors Best Regards Luis Re: KW45B41Z RTC not running during power off (Power backup given by super capacitor) We have attached schematics of super capacitor going to VDD_SWITCH line, do we need to enable any specific bits through software in rtc or power section? Best Regards Kaif
View full article
imx-smw ele バックエンドを複数のプロセスで同時に使用する プラットフォーム: iMX8ULP imx-smw: lf-6.6.52-2.2.0 imx-セキュア・エンクレーブ: lf-6.6.52-2.2.0 mbedts の暗号ドライバとして、imx-smw ライブラリによって公開されている PSA 暗号 API を使用しています。HSM ELE で秘密鍵を生成します。私たちのアプリケーションは、mbedtls で秘密鍵を不透明鍵としてロードして使用します。異なるプロセスで実行されている複数のアプリケーションは、同時に同じキーを使用できる必要があります。一例として、HSM でラップされたキーを秘密キーとして使用する Web サーバーが挙げられます。 私たちの知る限り、2 つの異なるプロセスが imx-smw ライブラリを使用して同時に同じキーを使用することはCANません。これは、各プロセスがキーにアクセスするために同じ (ele) キーストア サービスを開く必要があり、HSM ドキュメントに記載されているように、同じキーストアを同時に開くことができないためです。複数のプロセスが同じキーを同時に使用するCASEはサポートされていないようです。 この問題をどうしたら克服CANでしょうか? 考えられる解決策としては、imx-smw ライブラリの上にデーモンを作成し、キーにアクセスするための単一のエントリ ポイントを作成することです。しかし、もしかしたら私たちは何かを見逃しているのかもしれませんし、それに対処する別の方法があるかもしれません。 i.MX8ULP Security Re: use imx-smw ele backend in multiple processes simultaneously こんにちは@GiacomoDS このCASEについては社内チームと相談させていただきますが、その前にNXPについて名を教えていただけますか?プライバシーに関するCASEは、内部チケットを発行することもCAN。ここからアクセスして、NXP サポート プロフェッショナルによる機密のサポートを受けてください。 よろしくお願いします。 Harvey
View full article
AN4581 的最新版本 您好, 从 2020 年起有 AN4581(在支持 HABv4 的设备上进行 i.MX 安全启动)修订版 4: https://de.scribd.com/document/811030804/AN4581 然而,如果我搜索贵公司的网站或互联网,我只能找到 2012 年或 2018 年的过时版本。 能否告诉我在哪里可以找到AN4581 的最新修订版? 谢谢! Re: Latest version of AN4581 感谢您的支持。 我可以在这里下载 2020 年版本: https://www.readkong.com/page/an4581-i-mx-secure-boot-on-habv4-supported-devices-2622907 旧版本可在此处获取,无需 NDA : https://community.nxp.com/pwmxy87654/attachments/pwmxy87654/imx-processors/225997/1/AN4581.pdf(2012) https://community.nxp.com/pwmxy87654/attachments/pwmxy87654/imx-processors/194321/1/AN4581_2018.pdf(2018) Re: Latest version of AN4581 这个用于安全启动的AN是机密的,您需要与恩智浦签署保密协议。 最好从https://support.nxp.com/s/?language=en_US创建内部票据
View full article