Multi Source Translation Content

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

Multi Source Translation Content

讨论

排序依据:
如何使用 PeMicro 调试器在 S32K3x4EVB-T172 (S32K344) 上安装 S32K344 A/B 交换 HSE 固件。 您好, 我想在 S32K344 上测试 OTA A/B 替换演示。 为此,我需要在我的 S32K344 芯片上安装 HSE (A/B) 固件,该芯片上没有任何 HSE 固件。 我携带了以下硬件: 1. S32K3x4EVB-T172 (S32K344) 2. PeMicro 调试器。 (注:我没有 Lauterbach TRACE32 工具) 因此,我请求您提供一个正确的步骤,以便借助 S32 设计工作室,使用 PE 微调试器在 s32k344 上安装 HSE (A/B) 固件。 请尽量提供一个完整的操作流程,其中应包含所有必要信息,例如要使用的 DS 版本、RTD、HSE 粉色文件等。 谢谢。 Re: How to install S32K344 A/B swap HSE FW using PeMicro debugger on S32K3x4EVB-T172 (S32K344). HSE DEMO 代码(可随 HSE FW 下载)使用 Lauterbach TRACE32。虽然没有使用不同调试器的专门示例,但有 HSE 示例包: https://www.nxp.com/webapp/Download?colCode=S32K3_HSE_DemoExamples 它基本上是将 HSE DEMO 的功能移植到与调试器无关的代码中。例如,如果您使用 S32K344_HSE_FW_INSTALL,则可以使用任何调试器安装 HSE 固件。
查看全文
RT1176 PWM startup failed I am using PWM + fault + QTimer to implement motor pulse control, but the PWM3 submodule 0 PWM_A channel occasionally fails to start, where after the first high level it remains constant and subsequent pulses do not appear.After the inspection, it was found that the "run" bit of the pwm was not correctly set. Even though repeated startup operations were added in the program later, this anomaly still occurred. Re: RT1176 PWM startup failed Hi @liu626, Are you using a custom board or an EVK? If you are using the EVK, did you make any rework to it? Could you share the configuration you are using for PWM3? Are you using an example as a reference? If so, which one? If you try to replicate the issue using a project with only PWM3, does the problem persist? Does this only happen with PWM3 submodule 0 PWM_A channel? Has this occurred on other PWM modules or submodules? Is there any other task or interrupt that manipulates PWM3 registers and could affect or overwrite the run bit? Best Regards, Pablo Re: RT1176 PWM startup failed hi,I used a custom circuit board. I didn't refer to any examples. This was a problem that was discovered during the official development of the project. I configured six PWM channels for pulse control. Only this channel had problems, while no such issue occurred on the other sub-modules. I checked and found that only this channel was using the PWM3 module. No other interfering factors were detected. Below is my configuration. static axis_ctrl_t g_axes[AXIS_NUM] = { { .id = AXIS_X1, .name = "X1", .pwmBase = PWM1, .pwmModule = kPWM_Module_0, .pwmChannel = kPWM_PwmA, .tmrBase = TMR3, .lowCh = kQTMR_Channel_2, .highCh = kQTMR_Channel_3, .tmrInputsrc=kQTMR_ClockCounter2InputPin, .cascadePcs = 6U, .faultNum = 0U, .hwExactSupported = true, .outTrigMask = kPWM_ValueRegisterMask_3, }, { .id = AXIS_X2, .name = "X2", .pwmBase = PWM2, .pwmModule = kPWM_Module_0, .pwmChannel = kPWM_PwmA, .tmrBase = TMR2, .lowCh = kQTMR_Channel_0, .highCh = kQTMR_Channel_1, .tmrInputsrc=kQTMR_ClockCounter0InputPin, .cascadePcs = 4U, .faultNum = 0U, .hwExactSupported = true, .outTrigMask = kPWM_ValueRegisterMask_3, }, { .id = AXIS_Y, .name = "Y", .pwmBase = PWM3, .pwmModule = kPWM_Module_0, .pwmChannel = kPWM_PwmA, .tmrBase = TMR3, .lowCh = kQTMR_Channel_0, .highCh = kQTMR_Channel_1, .tmrInputsrc=kQTMR_ClockCounter0InputPin, .cascadePcs = 4U, .faultNum = 0U, .hwExactSupported = true, .outTrigMask = kPWM_ValueRegisterMask_3, }, { .id = AXIS_Z, .name = "Z", .pwmBase = PWM4, .pwmModule = kPWM_Module_0, .pwmChannel = kPWM_PwmA, .tmrBase = TMR1, .lowCh = kQTMR_Channel_0, .highCh = kQTMR_Channel_1, .tmrInputsrc=kQTMR_ClockCounter0InputPin, .cascadePcs = 4U, .faultNum = 0U, .hwExactSupported = true, .outTrigMask = kPWM_ValueRegisterMask_3, }, { .id = AXIS_EX1, .name = "EX1", .pwmBase = PWM1, .pwmModule = kPWM_Module_1, .pwmChannel = kPWM_PwmA, .tmrBase = TMR1, .lowCh = kQTMR_Channel_2, .highCh = kQTMR_Channel_3, .tmrInputsrc=kQTMR_ClockCounter2InputPin, .cascadePcs = 6U, .faultNum = 1U, .hwExactSupported = true, .outTrigMask = kPWM_ValueRegisterMask_3, }, { .id = AXIS_EX2, .name = "EX2", .pwmBase = PWM2, .pwmModule = kPWM_Module_1, .pwmChannel = kPWM_PwmA, .tmrBase = TMR2, .lowCh = kQTMR_Channel_2, .highCh = kQTMR_Channel_3, .tmrInputsrc=kQTMR_ClockCounter2InputPin, .cascadePcs = 6U, .faultNum = 1U, .hwExactSupported = true, .outTrigMask = kPWM_ValueRegisterMask_3, }, };static void APP_Init_PWM_QTMR(void) { pwm_config_t pwmConfig; pwm_fault_param_t faultConfig; qtmr_config_t qtmrConfig; PWM_GetDefaultConfig(&pwmConfig); pwmConfig.pairOperation = kPWM_Independent; pwmConfig.reloadLogic = kPWM_ReloadImmediate; PWM_FaultDefaultConfig(&faultConfig); faultConfig.faultLevel = true; faultConfig.enableCombinationalPath = false; faultConfig.faultClearingMode = kPWM_ManualSafety; faultConfig.recoverMode = kPWM_NoRecovery; QTMR_GetDefaultConfig(&qtmrConfig); CLOCK_EnableClock(kCLOCK_Qtimer1); CLOCK_EnableClock(kCLOCK_Qtimer2); CLOCK_EnableClock(kCLOCK_Qtimer3); PWM_StopTimer(PWM1, 0x0FU); PWM_StopTimer(PWM2, 0x0FU); PWM_StopTimer(PWM3, 0x0FU); PWM_StopTimer(PWM4, 0x0FU); pwm_fault_input_filter_param_t faultFilter; faultFilter.faultFilterPeriod = 255U; faultFilter.faultFilterCount = 7U; faultFilter.faultGlitchStretch = false; /* 记录每个 PWM 实例上已配置的 fault channel,避免重复设置 */ uint16_t pwm1FaultDone = 0U, pwm2FaultDone = 0U, pwm3FaultDone = 0U, pwm4FaultDone = 0U; for (uint8_t i = 0U; i < AXIS_NUM; i++) { axis_ctrl_t *ax = &g_axes[i]; PWM_Init(ax->pwmBase, ax->pwmModule, &pwmConfig); PWM_SetupFaults(ax->pwmBase, (pwm_fault_input_t)ax->faultNum, &faultConfig); /* 故障滤波(每个 PWM 实例的每个 fault channel 只设一次) */ { uint16_t *faultDone; if (ax->pwmBase == PWM1) faultDone = &pwm1FaultDone; else if (ax->pwmBase == PWM2) faultDone = &pwm2FaultDone; else if (ax->pwmBase == PWM3) faultDone = &pwm3FaultDone; else faultDone = &pwm4FaultDone; uint16_t faultBit = (uint16_t)(1U << ax->faultNum); if ((*faultDone & faultBit) == 0U) { PWM_SetupFaultInputFilterExt(ax->pwmBase, (pwm_fault_channels_t)ax->faultNum, &faultFilter); *faultDone |= faultBit; } } /* Fault 时输出低电平 */ ax->pwmBase->SM[ax->pwmModule].OCTRL &= ~(PWM_OCTRL_PWMAFS_MASK | PWM_OCTRL_PWMBFS_MASK); APP_PWM_Unmap_Selected_Fault(ax); APP_PWM_ClearFault_Safe(ax); ax->pwmBase->SM[ax->pwmModule].INIT = 0U; ax->pwmBase->SM[ax->pwmModule].VAL0 = 0U; ax->pwmBase->SM[ax->pwmModule].VAL1 = 1U; ax->pwmBase->SM[ax->pwmModule].VAL2 = 0U; ax->pwmBase->SM[ax->pwmModule].VAL3 = 0U; ax->pwmBase->SM[ax->pwmModule].VAL4 = 0U; ax->pwmBase->SM[ax->pwmModule].VAL5 = 0U; ax->pwmBase->SM[ax->pwmModule].TCTRL = PWM_TCTRL_OUT_TRIG_EN(ax->outTrigMask); APP_PWM_Disable_Output(ax); if (ax->hwExactSupported) { qtmrConfig.primarySource = ax->tmrInputSrc; QTMR_Init(ax->tmrBase, ax->lowCh, &qtmrConfig); QTMR_Init(ax->tmrBase, ax->highCh, &qtmrConfig); ax->tmrBase->CHANNEL[ax->lowCh].CTRL = TMR_CTRL_CM(kQTMR_PriSrcRiseEdge) | TMR_CTRL_PCS(ax->tmrInputSrc); ax->tmrBase->CHANNEL[ax->highCh].CTRL = TMR_CTRL_CM(kQTMR_CascadeCount) | TMR_CTRL_PCS(ax->cascadePcs); APP_QTMR_Disable_Low_OFLAG_Output(ax); QTMR_DisableInterrupts(ax->tmrBase, ax->lowCh, 0xFFU); QTMR_DisableInterrupts(ax->tmrBase, ax->highCh, 0xFFU); QTMR_ClearStatusFlags(ax->tmrBase, ax->lowCh, 0xFFU); QTMR_ClearStatusFlags(ax->tmrBase, ax->highCh, 0xFFU); } ax->phase = kAxisIdle; ax->armed = false; ax->running = false; ax->done = true; #if HARD_PWM_STATE_GUARD_ENABLE APP_StateGuard_Reset(ax); #endif } /* 使能 QTMR 中断 */ NVIC_SetPriority(TMR1_IRQn, 2U); NVIC_SetPriority(TMR2_IRQn, 2U); NVIC_SetPriority(TMR3_IRQn, 2U); EnableIRQ(TMR1_IRQn); EnableIRQ(TMR2_IRQn); EnableIRQ(TMR3_IRQn); }static bool APP_PWM_Config_Pulse(axis_ctrl_t *axis, uint32_t highCnt400M, uint32_t lowCnt400M) { pwm_clock_prescale_t prescale; uint16_t periodTicks; uint32_t totalCnt400M = highCnt400M + lowCnt400M; if ((axis == NULL) || (totalCnt400M == 0U)) return false; if (!APP_PWM_SelectPrescaler_FromPeriodCnt400M(totalCnt400M, &prescale, &periodTicks)) return false; uint32_t highTicks32 = (uint32_t)(((uint64_t)periodTicks * (uint64_t)highCnt400M + ((uint64_t)totalCnt400M / 2ULL)) / (uint64_t)totalCnt400M); if (highTicks32 == 0U) highTicks32 = 1U; if (highTicks32 >= periodTicks) highTicks32 = (uint32_t)periodTicks - 1U; uint32_t riseTicks32 = 0U; uint32_t fallTicks32 = highTicks32; #if HARD_PWM_LOW_START_PHASE_ENABLE uint32_t lowTicks32 = (uint32_t)periodTicks - highTicks32; if (lowTicks32 >= (2U * HARD_PWM_LOW_START_PHASE_MIN_TICKS)) { uint32_t desiredLeadCnt400M = highCnt400M; uint32_t minLeadCnt400M = (uint32_t)HARD_PWM_LOW_START_PHASE_MIN_US * 400U; if (desiredLeadCnt400M < minLeadCnt400M) desiredLeadCnt400M = minLeadCnt400M; uint32_t desiredLeadTicks32 = (uint32_t)(((uint64_t)periodTicks * (uint64_t)desiredLeadCnt400M + ((uint64_t)totalCnt400M / 2ULL)) / (uint64_t)totalCnt400M); if (desiredLeadTicks32 < HARD_PWM_LOW_START_PHASE_MIN_TICKS) desiredLeadTicks32 = HARD_PWM_LOW_START_PHASE_MIN_TICKS; uint32_t maxRiseByHalfTicks32 = lowTicks32 / 2U; uint32_t postGuardTicks32 = (uint32_t)(((uint64_t)periodTicks * (uint64_t)(HARD_PWM_VAL3_POST_LOW_GUARD_US * 400U) + ((uint64_t)totalCnt400M / 2ULL)) / (uint64_t)totalCnt400M); if (postGuardTicks32 < HARD_PWM_VAL3_POST_LOW_GUARD_MIN_TICKS) postGuardTicks32 = HARD_PWM_VAL3_POST_LOW_GUARD_MIN_TICKS; uint32_t maxRiseByPostGuardTicks32 = (lowTicks32 > postGuardTicks32) ? (lowTicks32 - postGuardTicks32) : 0U; uint32_t selectedRiseTicks32; if (maxRiseByHalfTicks32 >= desiredLeadTicks32) { selectedRiseTicks32 = desiredLeadTicks32; if (selectedRiseTicks32 > maxRiseByHalfTicks32) selectedRiseTicks32 = maxRiseByHalfTicks32; } else if (maxRiseByPostGuardTicks32 >= desiredLeadTicks32) { selectedRiseTicks32 = desiredLeadTicks32; if (selectedRiseTicks32 > maxRiseByPostGuardTicks32) selectedRiseTicks32 = maxRiseByPostGuardTicks32; } else { selectedRiseTicks32 = maxRiseByPostGuardTicks32; } if (selectedRiseTicks32 >= HARD_PWM_LOW_START_PHASE_MIN_TICKS) { riseTicks32 = selectedRiseTicks32; fallTicks32 = riseTicks32 + highTicks32; } } #endif if (fallTicks32 >= (uint32_t)periodTicks) fallTicks32 = (uint32_t)periodTicks - 1U; uint16_t riseTicks = (uint16_t)riseTicks32; uint16_t fallTicks = (uint16_t)fallTicks32; PWM_SetPwmLdok(axis->pwmBase, APP_PwmModuleMask(axis), false); uint16_t ctrl = axis->pwmBase->SM[axis->pwmModule].CTRL; ctrl &= (uint16_t)(~PWM_CTRL_PRSC_MASK); ctrl |= PWM_CTRL_PRSC(prescale); axis->pwmBase->SM[axis->pwmModule].CTRL = ctrl; axis->pwmBase->SM[axis->pwmModule].INIT = 0U; axis->pwmBase->SM[axis->pwmModule].VAL0 = 0U; axis->pwmBase->SM[axis->pwmModule].VAL1 = (uint16_t)(periodTicks - 1U); if (axis->pwmChannel == kPWM_PwmA) { axis->pwmBase->SM[axis->pwmModule].VAL2 = riseTicks; axis->pwmBase->SM[axis->pwmModule].VAL3 = fallTicks; } else if (axis->pwmChannel == kPWM_PwmB) { axis->pwmBase->SM[axis->pwmModule].VAL4 = riseTicks; axis->pwmBase->SM[axis->pwmModule].VAL5 = fallTicks; } axis->pwmBase->SM[axis->pwmModule].TCTRL = PWM_TCTRL_OUT_TRIG_EN(axis->outTrigMask); PWM_SetPwmLdok(axis->pwmBase, APP_PwmModuleMask(axis), true); PWM_SetPwmLdok(axis->pwmBase, APP_PwmModuleMask(axis), true); axis->pwmConfigValid = true; axis->cachedHighCnt400M = highCnt400M; axis->cachedLowCnt400M = lowCnt400M; return true; } Re: RT1176 PWM startup failed Hi @liu626, Could you help me isolate the configuration and test whether the issue persists when only PWM3 is initialized? After reviewing the configuration, you shared and in order to try to replicate the behavior, I have the following questions: What is the definition of axis_ctrl_t? Are HARD_PWM_LOW_START_PHASE_ENABLE and HARD_PWM_STATE_GUARD_ENABLE enabled in your application? What do the following APP functions do? APP_PWM_Unmap_Selected_Fault APP_PWM_ClearFault_Safe APP_PWM_Disable_Output APP_QTMR_Disable_Low_OFLAG_Output APP_StateGuard_Reset APP_PWM_SelectPrescaler_FromPeriodCnt400M APP_PwmModuleMask Best Regards, Pablo Re: RT1176 PWM startup failed Thank you for your reply. The GPIO pin I'm using is GPIO_EMC_B1_29 of the rt1176."axis_ctrl_t" is the definition related to the motor shaft. * PWM output pulse -> Trigger XBAR signal -> Falling edge of pulse drives the external clock input of QTMR -> * QTMR 32-bit cascaded counter decrements by 1 -> When it reaches 0, triggers QTMR comparison interrupt -> Interrupt internally turns off PWM * At the same time, QTMR triggers the hardware Fault, directly pulling down the physical output pin of PWM. .id = AXIS_Y, .name = "Y", /* Used for serial port logging or breakpoint debugging to identify the Y-axis */ /* ================= PWM Output Resource Allocation ================= */ .pwmBase = PWM3, /* The Y-axis uses the FlexPWM3 module */ .pwmModule = kPWM_Module_0, /* Uses the sub-module 0 of PWM3 (each PWM has 4 sub-modules from 0 to 3) */ .pwmChannel = kPWM_PwmA, /* Uses the output pin of phase A of sub-module 0, corresponding to the physical pin GPIO_EMC_B1_29 */ /* ================= 32-bit QTMR cascaded count resource allocation ================= */ .tmrBase = TMR3, /* The Y-axis uses the QTMR3 peripheral (corresponding to IRQ interrupt number TMR3_IRQn) */ .lowCh = kQTMR_Channel_0, /* 16-bit low counter: uses channel 0 of TMR3 */ .highCh = kQTMR_Channel_1,/* 16-bit high counter: uses channel 1 of TMR3 */ /* 👉 .lowCh and .highCh are paired, and in the hardware level, they are automatically combined into a 32-bit counter */ /* ================= Configuration of Hardware Cascaded Clock Sources (Core Critical) ================= */ .tmrInputsrc=kQTMR_ClockCounter0InputPin, /* The clock source for Channel 0: Set to "External Pin Input 0". In the XBAR configuration, the falling edge of the pulse from PWM3 is connected to the input pin of Channel 0 of TMR3 through the XBAR. Therefore, every time a pulse is output by PWM, Channel 0 (16-bit) will perform a decrement operation once. */ .cascadePcs = 4U, /* Configuration of the clock source (PCS) for the high 16-bit channel (Channel 1). In the QTMR register of i.MX RT, the PCS value corresponds as follows: 0-3 = External pin input; 4 = Overflow/Termination event of Channel 0; 5 = Overflow/Termination event of Channel 1; 6 = Overflow/Termination event of Channel 2; 7 = Overflow/Termination event of Channel 3. Here, it is configured as 4U, meaning: Let "Channel 1 of TMR3" monitor the "Overflow event of Channel 0 of TMR3". HARD_PWM_LOW_START_PHASE_ENABLE and HARD_PWM_STATE_GUARD_ENABLE have been enabled. APP_PWM_Unmap_Selected_Fault Function: Remove the Fault pin mapping corresponding to the current axis. Call the underlying PWM_SetupFaultDisableMap function to disable the Fault. The purpose is: When the hardware Fault is not needed, prevent accidental external interference from causing the PWM to be turned off, facilitating the underlying debugging process. APP_PWM_ClearFault (original code function) Function: Clear the Fault status flag (axis->pwmBase->FSTS) of the PWM module. After triggering a hardware Fault, you must first clear this flag before the PWM can be allowed to restart. APP_PWM_Disable_Output Function: Immediately stop the PWM timer, force the pin to output a low level (PWM_SetPwmForceOutputToZero), and enable the output. Its purpose is to ensure that the pin does not output a high level due to being left floating or in the default state before the motor starts, which could cause the motor to move erratically. APP_QTMR_Disable_Low_OFLAG_Output Function: Disable the OFLAG (status flag) output of QTMR and force the OFLAG to be at a low level. In conjunction with the XBAR hardware, its role is to cut off the path from the QTMR output to the PWM Fault pin, preventing accidental triggering of Fault before startup. APP_StateGuard_Reset Function: Clears the counters and flags of the state guard (watchdog). This function is used to reset these protection variables before stopping or restarting the system if it encounters a long period of no pulse change or a deadlock when HARD_PWM_STATE_GUARD_ENABLE is enabled. APP_PWM_SelectPrescaler_FromPeriodCnt400M Function: This is a very core underlying frequency calculation function. It receives the total 400MHz count value of High + Low, and calculates how many prescalers (PRSC) and PWM periods (PERIOD) should be set in order to fit into the 16-bit PWM register. Please note: If the calculated period exceeds 65535 and the division coefficient is out of range, this function will return false, causing the motor to fail to start. APP_PwmModuleMask Function: Convert the index number of the PWM sub-module (for example, kPWM_Module_0 with the value 0) into a bit mask shifted left by N bits. Many of NXP's PWM registers (such as OUTEN, MCTRL) are controlled bit by bit. This function is responsible for generating the correct binary mask. Re: RT1176 PWM startup failed I have found the cause. It is because the internal load of the PIT interrupt in the cm4 core is too heavy, which has affected the PWM operation of the cm7 core. After I reduced the load of the PIT interrupt, the failure of PWM startup disappeared.
查看全文
RT1176 PWM启动失败 我使用PWM+故障+QTimer来实现电机脉冲控制,但PWM3子模块0的PWM_A通道偶尔无法启动,在第一个高电平之后就一直保持高电平,后续脉冲不再出现。检查后发现,PWM的“运行”位没有正确设置。即使后来在程序中添加了重复启动操作,这种异常情况仍然发生。 Re: RT1176 PWM startup failed 你好@liu626 , 你用的是定制板还是EVK板?如果你使用的是 EVK,你对它进行过任何修改吗? 能否分享一下您使用的PWM3配置? 您是使用示例作为参考吗?如果是,是哪一个? 如果尝试使用仅包含 PWM3 的项目来重现该问题,问题是否仍然存在? 这种情况是否只发生在 PWM3 子模块 0 PWM_A 通道上?其他PWM模块或子模块是否也出现过这种情况? 是否还有其他任务或中断会操作 PWM3 寄存器,从而影响或覆盖运行位? 此致, 巴勃罗 Re: RT1176 PWM startup failed 您好,我使用的是定制电路板。我没有举任何例子。这是在项目正式开发过程中发现的问题。我配置了六个PWM通道用于脉冲控制。只有这个通道出现了问题,其他子模块都没有出现此类问题。我检查后发现,只有这个通道使用了 PWM3 模块。未检测到其他干扰因素。以下是我的配置。 静态 axis_ctrl_t g_axes[AXIS_NUM] = { { 。ID= AXIS_X1,.name= "X1", .pwmBase= PWM1,.pwmModule= kPWM_Module_0,.pwmChannel= kPWM_PwmA, .tmrBase= TMR3,.lowCh= kQTMR_Channel_2,.highCh= kQTMR_Channel_3, .tmrInputsrc=kQTMR_ClockCounter2InputPin,.cascadePcs= 6U, 故障编号= 0U,.hwExactSupported= true,.outTrigMask= kPWM_ValueRegisterMask_3, }, { 。ID= AXIS_X2,.name= "X2", .pwmBase= PWM2,.pwmModule= kPWM_Module_0,.pwmChannel= kPWM_PwmA, .tmrBase= TMR2,.lowCh= kQTMR_Channel_0, .highCh= kQTMR_Channel_1, .tmrInputsrc=kQTMR_ClockCounter0InputPin,.cascadePcs= 4U, 故障编号= 0U,.hwExactSupported= true,.outTrigMask= kPWM_ValueRegisterMask_3, }, { 。ID= AXIS_Y,.name= "Y", .pwmBase= PWM3,.pwmModule= kPWM_Module_0,.pwmChannel= kPWM_PwmA, .tmrBase= TMR3,.lowCh= kQTMR_Channel_0, .highCh= kQTMR_Channel_1, .tmrInputsrc=kQTMR_ClockCounter0InputPin,.cascadePcs= 4U, 故障编号= 0U,.hwExactSupported= true,.outTrigMask= kPWM_ValueRegisterMask_3, }, { 。ID= AXIS_Z,.name= "Z", .pwmBase= PWM4,.pwmModule= kPWM_Module_0,.pwmChannel= kPWM_PwmA, .tmrBase= TMR1,.lowCh= kQTMR_Channel_0, .highCh= kQTMR_Channel_1, .tmrInputsrc=kQTMR_ClockCounter0InputPin,.cascadePcs= 4U, 故障编号= 0U,.hwExactSupported= true,.outTrigMask= kPWM_ValueRegisterMask_3, }, { 。ID= AXIS_EX1,.name= "EX1", .pwmBase= PWM1,.pwmModule= kPWM_Module_1,.pwmChannel= kPWM_PwmA, .tmrBase= TMR1,.lowCh= kQTMR_Channel_2,.highCh= kQTMR_Channel_3, .tmrInputsrc=kQTMR_ClockCounter2InputPin,.cascadePcs= 6U, 故障编号= 1U,.hwExactSupported= true,.outTrigMask= kPWM_ValueRegisterMask_3, }, { 。ID= AXIS_EX2,.name= "EX2", .pwmBase= PWM2,.pwmModule= kPWM_Module_1,.pwmChannel= kPWM_PwmA, .tmrBase= TMR2,.lowCh= kQTMR_Channel_2,.highCh= kQTMR_Channel_3, .tmrInputsrc=kQTMR_ClockCounter2InputPin,.cascadePcs= 6U, 故障编号= 1U,.hwExactSupported= true,.outTrigMask= kPWM_ValueRegisterMask_3, }, };static void APP_Init_PWM_QTMR(void) { pwm_config_t pwmConfig; pwm_fault_param_t faultConfig; qtmr_config_t qtmrConfig; PWM_GetDefaultConfig(&pwmConfig); pwmConfig.pairOperation= kPWM_Independent; pwmConfig.reloadLogic = kPWM_ReloadImmediate; PWM_FaultDefaultConfig(&faultConfig); faultConfig.faultLevel = true; faultConfig.enableCombinationPath= false; faultConfig.faultClearingMode= kPWM_手动安全; faultConfig.recoverMode = kPWM_NoRecovery; QTMR_GetDefaultConfig(&qtmrConfig); CLOCK_EnableClock(kCLOCK_Qtimer1); CLOCK_EnableClock(kCLOCK_Qtimer2); CLOCK_EnableClock(kCLOCK_Qtimer3); PWM_StopTimer(PWM1, 0x0FU); PWM_StopTimer(PWM2, 0x0FU); PWM_StopTimer(PWM3, 0x0FU); PWM_StopTimer(PWM4, 0x0FU); pwm_fault_input_filter_param_t faultFilter; 故障过滤器.故障过滤器周期= 255U; faultFilter.faultFilterCount= 7U; faultFilter.faultGlitchStretch= false; /* 记录每个PWM实例上已配置的故障通道,避免重复设置 */ uint16_t pwm1FaultDone = 0U, pwm2FaultDone = 0U, pwm3FaultDone = 0U, pwm4FaultDone = 0U; for (uint8_t i = 0U; i < AXIS_NUM; i++) { axis_ctrl_t *ax = &g_axes[i]; PWM_Init(ax->pwmBase, ax->pwmModule, &pwmConfig); PWM_SetupFaults(ax->pwmBase, (pwm_fault_input_t)ax->faultNum, &faultConfig); /* 故障提示(每个 PWM 实例的每个故障通道只设置一次) */ { uint16_t *faultDone; 如果 (ax->pwmBase == PWM1) faultDone = &pwm1FaultDone; 否则如果 (ax->pwmBase == PWM2) faultDone = &pwm2FaultDone; 否则如果 (ax->pwmBase == PWM3) faultDone = &pwm3FaultDone; 否则 faultDone = &pwm4FaultDone; uint16_t faultBit = (uint16_t)(1U << ax->faultNum); 如果 ((*faultDone & faultBit) == 0U) { PWM_SetupFaultInputFilterExt(ax->pwmBase, (pwm_fault_channels_t)ax->faultNum, &faultFilter); *faultDone |= faultBit; } } /* 故障时输出低电平 */ ax->pwmBase->SM[ax->pwmModule].OCTRL &= ~(PWM_OCTRL_PWMAFS_MASK | PWM_OCTRL_PWMBFS_MASK); APP_PWM_Unmap_Selected_Fault(ax); APP_PWM_ClearFault_Safe(ax); ax->pwmBase->SM[ax->pwmModule].INIT = 0U; ax->pwmBase->SM[ax->pwmModule].VAL0 = 0U; ax->pwmBase->SM[ax->pwmModule].VAL1 = 1U; ax->pwmBase->SM[ax->pwmModule].VAL2 = 0U; ax->pwmBase->SM[ax->pwmModule].VAL3 = 0U; ax->pwmBase->SM[ax->pwmModule].VAL4 = 0U; ax->pwmBase->SM[ax->pwmModule].VAL5 = 0U; ax->pwmBase->SM[ax->pwmModule].TCTRL = PWM_TCTRL_OUT_TRIG_EN(ax->outTrigMask); APP_PWM_Disable_Output(ax); 如果 (ax->hwExactSupported) { qtmrConfig.primarySource= ax->tmrInputSrc; QTMR_Init(ax->tmrBase, ax->lowCh, &qtmrConfig); QTMR_Init(ax->tmrBase, ax->highCh, &qtmrConfig); ax->tmrBase->CHANNEL[ax->lowCh].CTRL = TMR_CTRL_CM(kQTMR_PriSrcRiseEdge) | TMR_CTRL_PCS(ax->tmrInputSrc); ax->tmrBase->CHANNEL[ax->highCh].CTRL = TMR_CTRL_CM(kQTMR_CascadeCount) | TMR_CTRL_PCS(ax->cascadePcs); APP_QTMR_Disable_Low_OFLAG_Output(ax); QTMR_DisableInterrupts(ax->tmrBase, ax->lowCh, 0xFFU); QTMR_DisableInterrupts(ax->tmrBase, ax->highCh, 0xFFU); QTMR_ClearStatusFlags(ax->tmrBase, ax->lowCh, 0xFFU); QTMR_ClearStatusFlags(ax->tmrBase, ax->highCh, 0xFFU); } ax->phase = kAxisIdle; ax->armed = false; ax->running = false; ax->done = true; #if HARD_PWM_STATE_GUARD_ENABLE APP_StateGuard_Reset(ax); #endif } /* 使能 QTMR 中断 */ NVIC_SetPriority(TMR1_IRQn, 2U); NVIC_SetPriority(TMR2_IRQn, 2U); NVIC_SetPriority(TMR3_IRQn, 2U); 启用IRQ(TMR1_IRQn); 启用IRQ(TMR2_IRQn); 启用IRQ(TMR3_IRQn); }static bool APP_PWM_Config_Pulse(axis_ctrl_t *axis, uint32_t highCnt400M, uint32_t lowCnt400M) { pwm_clock_prescale_t 预分频; uint16_t periodTicks; uint32_t totalCnt400M = highCnt400M + lowCnt400M; 如果 ((axis == NULL) || (totalCnt400M == 0U)) 返回 false; 如果 (!APP_PWM_SelectPrescaler_FromPeriodCnt400M(totalCnt400M, &prescale, &periodTicks)) 返回 false; uint32_t highTicks32 = (uint32_t)(((uint64_t)periodTicks * (uint64_t)highCnt400M + ((uint64_t)totalCnt400M / 2ULL)) / (uint64_t)totalCnt400M); 如果 (highTicks32 == 0U) highTicks32 = 1U; 如果 (highTicks32 >= periodTicks) highTicks32 = (uint32_t)periodTicks - 1U; uint32_t riseTicks32 = 0U; uint32_t fallTicks32 = highTicks32; #if HARD_PWM_LOW_START_PHASE_ENABLE uint32_t lowTicks32 = (uint32_t)periodTicks - highTicks32; 如果 (lowTicks32 >= (2U * HARD_PWM_LOW_START_PHASE_MIN_TICKS)) { uint32_t desiredLeadCnt400M = highCnt400M; uint32_t minLeadCnt400M = (uint32_t)HARD_PWM_LOW_START_PHASE_MIN_US * 400U; 如果 (desiredLeadCnt400M < minLeadCnt400M) desiredLeadCnt400M = minLeadCnt400M; uint32_t desiredLeadTicks32 = (uint32_t)(((uint64_t)periodTicks * (uint64_t)desiredLeadCnt400M + ((uint64_t)totalCnt400M / 2ULL)) / (uint64_t)totalCnt400M); 如果 (desiredLeadTicks32 < HARD_PWM_LOW_START_PHASE_MIN_TICKS) desiredLeadTicks32 = HARD_PWM_LOW_START_PHASE_MIN_TICKS; uint32_t maxRiseByHalfTicks32 = lowTicks32 / 2U; uint32_t postGuardTicks32 = (uint32_t)(((uint64_t)periodTicks * (uint64_t)(HARD_PWM_VAL3_POST_LOW_GUARD_US * 400U) + ((uint64_t)totalCnt400M / 2ULL)) / (uint64_t)totalCnt400M); 如果 (postGuardTicks32 < HARD_PWM_VAL3_POST_LOW_GUARD_MIN_TICKS) postGuardTicks32 = HARD_PWM_VAL3_POST_LOW_GUARD_MIN_TICKS; uint32_t maxRiseByPostGuardTicks32 = (lowTicks32 > postGuardTicks32) ? (lowTicks32 - postGuardTicks32):0U; uint32_t selectedRiseTicks32; 如果 (maxRiseByHalfTicks32 >= desiredLeadTicks32) { selectedRiseTicks32 = desiredLeadTicks32; 如果 (selectedRiseTicks32 > maxRiseByHalfTicks32) selectedRiseTicks32 = maxRiseByHalfTicks32; } 否则如果(maxRiseByPostGuardTicks32 >= desiredLeadTicks32) { selectedRiseTicks32 = desiredLeadTicks32; 如果 (selectedRiseTicks32 > maxRiseByPostGuardTicks32) selectedRiseTicks32 = maxRiseByPostGuardTicks32; } 别的 { selectedRiseTicks32 = maxRiseByPostGuardTicks32; } 如果 (selectedRiseTicks32 >= HARD_PWM_LOW_START_PHASE_MIN_TICKS) { riseTicks32 = selectedRiseTicks32; fallTicks32 = riseTicks32 + highTicks32; } } #endif 如果 (fallTicks32 >= (uint32_t)periodTicks) fallTicks32 = (uint32_t)periodTicks - 1U; uint16_t riseTicks = (uint16_t)riseTicks32; uint16_t fallTicks = (uint16_t)fallTicks32; PWM_SetPwmLdok(axis->pwmBase, APP_PwmModuleMask(axis), false); uint16_t ctrl = axis->pwmBase->SM[axis->pwmModule].CTRL; ctrl &= (uint16_t)(~PWM_CTRL_PRSC_MASK); ctrl |= PWM_CTRL_PRSC(预分频); axis->pwmBase->SM[axis->pwmModule].CTRL = ctrl; axis->pwmBase->SM[axis->pwmModule].INIT = 0U; axis->pwmBase->SM[axis->pwmModule].VAL0 = 0U; axis->pwmBase->SM[axis->pwmModule].VAL1 = (uint16_t)(periodTicks - 1U); 如果 (axis->pwmChannel == kPWM_PwmA) { axis->pwmBase->SM[axis->pwmModule].VAL2 = riseTicks; axis->pwmBase->SM[axis->pwmModule].VAL3 = fallTicks; } 否则如果 (axis->pwmChannel == kPWM_PwmB) { axis->pwmBase->SM[axis->pwmModule]。VAL4 = riseTicks; axis->pwmBase->SM[axis->pwmModule].VAL5 = fallTicks; } axis->pwmBase->SM[axis->pwmModule].TCTRL = PWM_TCTRL_OUT_TRIG_EN(axis->outTrigMask); PWM_SetPwmLdok(axis->pwmBase, APP_PwmModuleMask(axis), true); PWM_SetPwmLdok(axis->pwmBase, APP_PwmModuleMask(axis), true); axis->pwmConfigValid = true; axis->cachedHighCnt400M = highCnt400M; axis->cachedLowCnt400M = lowCnt400M; 返回 true; } Re: RT1176 PWM startup failed 你好@liu626 , 您能否帮我找出配置问题,并测试一下仅初始化 PWM3 时问题是否仍然存在? 在查看了您分享的配置后,为了尝试重现该行为,我有以下问题: axis_ctrl_t 的定义是什么? 您的应用程序中是否启用了 HARD_PWM_LOW_START_PHASE_ENABLE 和 HARD_PWM_STATE_GUARD_ENABLE? 以下APP功能是做什么用的? APP_PWM_Unmap_Selected_Fault APP_PWM_ClearFault_Safe APP_PWM_禁用输出 APP_QTMR_Disable_Low_OFLAG_Output APP_StateGuard_Reset APP_PWM_SelectPrescaler_FromPeriodCnt400M APP_PwmModuleMask 此致, 巴勃罗 Re: RT1176 PWM startup failed 感谢你的回复。我使用的 GPIO 引脚是 rt1176 的 GPIO_EMC_B1_29。“axis_ctrl_t”是与电机轴相关的定义。 * PWM 输出脉冲 -> 触发 XBAR 信号 -> 脉冲下降沿驱动 QTMR 的外部时钟输入 -> * QTMR 32 位级联计数器递减 1 -> 当计数器达到 0 时,触发 QTMR 比较中断 -> 中断内部关闭 PWM * 同时,QTMR 触发硬件故障,直接拉低 PWM 的物理输出引脚。。ID= AXIS_Y, 。姓名= "Y", /* 用于串口日志记录或断点调试,以识别 Y 轴 */ /* ================= PWM 输出资源分配 ================= */ .pwmBase= PWM3, /* Y轴使用FlexPWM3模块 */ .pwm模块= kPWM_Module_0, /* 使用 PWM3 的子模块 0(每个 PWM 有 4 个子模块,编号从 0 到 3) */ .pwm通道= kPWM_PwmA, /* 使用子模块 0 的 A 相输出引脚,对应于物理引脚 GPIO_EMC_B1_29 */ /* ================= 32 位 QTMR 级联计数资源分配 ================= */ .tmrBase= TMR3, /* Y轴使用QTMR3外设(对应于IRQ中断号TMR3_IRQn) */ 低= kQTMR_Channel_0, /* 16 位低计数器:使用 TMR3 的通道 0 */ .highCh= kQTMR_Channel_1,/* 16 位高位计数器:使用 TMR3 的通道 1 */ /* 👉 .lowCh 和 .highCh它们成对出现,在硬件层面上,它们会自动组合成一个 32 位计数器。 /* ================= 硬件级联时钟源配置(核心关键) ================= */ .tmrInputsrc=kQTMR_ClockCounter0InputPin, /* 通道 0 的时钟源:设置为“外部引脚输入 0”。 在 XBAR 配置中,PWM3 脉冲的下降沿通过 XBAR 连接到 TMR3 通道 0 的输入引脚。 因此,每次 PWM 输出脉冲时,通道 0(16 位)将执行一次减量操作。*/ .cascadePcs = 4U, /* 高 16 位通道(通道 1)的时钟源 (PCS) 配置。 在 i.MX RT 的 QTMR 寄存器中,PCS 值对应如下: 0-3 = 外部引脚输入; 4 = 通道 0 的溢出/终止事件; 5 = 通道 1 的溢出/终止事件; 6 = 通道 2 的溢出/终止事件; 7 = 通道 3 的溢出/终止事件。 这里配置为 4U,意思是:让“TMR3 的通道 1”监测“TMR3 的通道 0 的溢出事件”。 已启用 HARD_PWM_LOW_START_PHASE_ENABLE 和 HARD_PWM_STATE_GUARD_ENABLE。APP_PWM_Unmap_Selected_Fault 功能:移除与当前轴对应的故障引脚映射。调用底层 PWM_SetupFaultDisableMap 函数来禁用故障。目的是为了:在不需要硬件故障的情况下,防止意外的外部干扰导致 PWM 关闭,从而方便底层调试过程。 APP_PWM_ClearFault(原始代码函数) 功能:清除 PWM 模块的故障状态标志(axis->pwmBase->FSTS)。触发硬件故障后,必须先清除此标志,然后才能允许 PWM 重新启动。 APP_PWM_禁用输出 功能:立即停止 PWM 定时器,强制引脚输出低电平(PWM_SetPwmForceOutputToZero),并启用输出。它的目的是确保在电机启动之前,引脚不会因为浮空或处于默认状态而输出高电平,这可能会导致电机运动不规则。 APP_QTMR_Disable_Low_OFLAG_Output 功能:禁用 QTMR 的 OFLAG(状态标志)输出,并强制 OFLAG 处于低电平。它与 XBAR 硬件配合使用,其作用是切断 QTMR 输出到 PWM 故障引脚的路径,防止在启动前意外触发故障。 APP_StateGuard_Reset 功能:清除国家卫队(看门狗)的计数器和旗帜。如果启用 HARD_PWM_STATE_GUARD_ENABLE 时系统遇到长时间无脉冲变化或死锁,则此功能用于在停止或重新启动系统之前重置这些保护变量。 APP_PWM_SelectPrescaler_FromPeriodCnt400M 功能:这是一个非常核心的底层频率计算函数。它接收高电平 + 低电平的总 400MHz 计数值,并计算应设置多少个预分频器 (PRSC) 和 PWM 周期 (PERIOD) 才能放入 16 位 PWM 寄存器中。请注意:如果计算出的周期超过 65535 且除法系数超出范围,则此函数将返回 false,导致电机无法启动。 APP_PwmModuleMask 功能:将 PWM 子模块的索引号(例如,值为 0 的 kPWM_Module_0)转换为左移 N 位的位掩码。NXP 的许多 PWM 寄存器(例如 OUTEN、MCTRL)都是逐位控制的。该函数负责生成正确的二进制掩码。 Re: RT1176 PWM startup failed 我找到了原因。这是因为 cm4 内核中 PIT 中断的内部负载过重,影响了 cm7 内核的 PWM 操作。降低 PIT 中断的负载后,PWM 启动失败的问题就消失了。
查看全文
[S32K324 / Custom Board] HSE FW Installed (0x4039C028=1) but Init Failed (0x4038C107=0) Hi everyone, I am seeking advice regarding an issue where the HSE Firmware initialization fails to complete on an S32K324 custom board. 1. Development Environment MCU: S32K324 (Custom Board) HSE FW: s32k3x4_hse_fw_1.5.0_2.55.0_pb250130.bin.pink Debugger: S32DS + T32 (Trace32) 2. Progress and Status Registers Successfully programmed the HSE FW Usage Flag in the UTEST region (0x1B000000). Downloaded the Pink Image binary into flash memory. After performing a Power-On Reset (POR), the status registers are as follows: 0x4039C028 (HSE GPR): 0x01 (Installation confirmed) 0x4038C107 (HSE_STATUS_INIT_OK): 0x00 (Halted during boot) 3. Questions I would like to ask the experts the following: What is the very first thing I should check? Since the installation succeeded but initialization failed, are there any specific registers (e.g., Fault status) I should dump or hardware signals to inspect to pinpoint the exact cause? Can the Custom Board environment affect the initialization failure? Since I am using a custom board, I suspect hardware differences (e.g., initial XTAL frequency) or the early clock (PLL) configuration code of the main core (M7) might be interfering with the HSE boot sequence. If this is a known issue, could you guide me on the recommended boot sequence (e.g., polling the INIT_OK flag before any clock setup) or potential solutions? Any clues would be a great help. Thank you in advance for your support! Re: [S32K324 / Custom Board] HSE FW Installed (0x4039C028=1) but Init Failed (0x4038C107=0) Hi there, Thank you so much for the clear guidance. First, I proceeded with the firmware installation using the demo app, and then dumped the MU and HSE GPR register values while in the system.up state. Please let me know if any of these register addresses are incorrect. The results are as follows: 1. MU0 Registers (Base Address: 0x4038C000)     2. HSE GPR Registers (Base Address: 0x4039C000)   Could you please review these values? I would highly appreciate your expert opinion on whether these indicate a specific error cause, such as a clock configuration conflict or a firmware authentication failure. Thank you again for your time and support! Re: [S32K324 / Custom Board] HSE FW Installed (0x4039C028=1) but Init Failed (0x4038C107=0) Could you provide following information? MU registers, FSR, GSR, etc: HSE GPR3: Re: [S32K324 / Custom Board] HSE FW Installed (0x4039C028=1) but Init Failed (0x4038C107=0) Thanks. But I would need to see this screenshot when HSE core is in WFI state, not directly after reset.
查看全文
RW610/RW612 支持TLS 1.2及以上版本么 RW610/RW612 支持TLS 1.2及以上版本么 Re: RW610/RW612 支持TLS 1.2及以上版本么 Hi, @Cherlyn  Yes, RW610/RW612 支持TLS 1.2. For TLS 3.0, 我们有提供相关的example:frdmrw612_mbedtls3x_selftest 以及frdmrw612_mbedtls3x_psatest 等,您可以参考看一下是否可以满足您的要求。 如果还有其他具体的诉求,也可以提出来,我们一起讨论。 Best regards, Christine.
查看全文
Do RW610/RW612 support TLS 1.2 and above? Do RW610/RW612 support TLS 1.2 and above? Re: RW610/RW612 支持TLS 1.2及以上版本么 Hi, @Cherlyn Yes, RW610/RW612 supports TLS 1.2. For TLS 3.0, we have provided relevant examples: frdmrw612_mbedtls3x_selftest and frdmrw612_mbedtls3x_psatest, etc. You can refer to them to see if they meet your requirements. If you have any other specific requests, please feel free to bring them up, and we can discuss them together. Best regards, Christine.
查看全文
[S32K324 / カスタムボード] HSEファームウェアがインストールされましたが(0x4039C028=1)、初期化に失敗しました(0x4038C107=0) こんにちは、皆さん S32K324カスタムボード上でHSEファームウェアの初期化が完了しない問題について、アドバイスを求めています。 1. 開発環境 MCU:S32K324(カスタムボード) HSE FW: s32k3x4_hse_fw_1.5.0_2.55.0_pb250130.bin.pink デバッガ: S32DS + T32 (Trace32) 2. 進捗状況およびステータス記録簿 UTEST領域(0x1B000000)にHSE FW使用フラグを正常にプログラムしました。 ピンクイメージのバイナリファイルをフラッシュメモリにダウンロードしました。 電源投入リセット(POR)を実行した後、ステータスレジスタは次のようになります。 0x4039C028 (HSE GPR): 0x01 (インストール確認済み) 0x4038C107 (HSE_STATUS_INIT_OK): 0x00 (起動中に停止) 3. 質問 専門家の方々に以下の点についてお伺いしたいと思います。 最初に確認すべきことは何ですか? インストールは成功したが初期化が失敗した場合、正確な原因を特定するために、ダンプすべき特定のレジスタ(例:障害ステータス)や検査すべきハードウェア信号はありますか? カスタムボード環境は初期化の失敗に影響を与えることがありますか? カスタムボードを使用しているため、ハードウェアの違い(例えば、初期水晶発振周波数)やメインコア(M7)の初期クロック(PLL)構成コードがHSEブートシーケンスに干渉している可能性があると考えています。もしこれが既知の問題であれば、推奨される起動手順(例えば、クロック設定前にINIT_OKフラグをポーリングする方法)や解決策について教えていただけませんか? どんな手がかりでも大変助かります。事前にサポートありがとうございます! Re: [S32K324 / Custom Board] HSE FW Installed (0x4039C028=1) but Init Failed (0x4038C107=0) こんにちは、 明確なご案内をありがとうございます。 まず、デモアプリを使用してファームウェアのインストールを進め、その後、system.up状態中にMUおよびHSE GPRレジスタの値をダンプしました。これらの登録住所に誤りがある場合はお知らせください。 結果は以下のとおりです。 1. MU0レジスタ(ベースアドレス:0x4038C000)     2. HSE GPRレジスタ(ベースアドレス:0x4039C000)   これらの数値を確認していただけますか?これらがクロック設定の競合やファームウェア認証の失敗など、特定のエラー原因を示しているのか、専門家のご意見をいただけると大変ありがたいです。 改めてお時間をいただき、サポートありがとうございます! Re: [S32K324 / Custom Board] HSE FW Installed (0x4039C028=1) but Init Failed (0x4038C107=0) 以下の情報を教えていただけますか? MUレジスタ、FSR、GSRなど: HSE GPR3: Re: [S32K324 / Custom Board] HSE FW Installed (0x4039C028=1) but Init Failed (0x4038C107=0) ありがとう。ただし、このスクリーンショットは、リセット直後ではなく、HSEコアがWFI状態にあるときに確認する必要があります。
查看全文
How to install S32K344 A/B swap HSE FW using PeMicro debugger on S32K3x4EVB-T172 (S32K344). Hi, I want to test an OTA A/B swap demo on S32K344.  For that i'll have to install HSE (A/B) firmware on my S32K344 chip which is not having any HSE FW on it.  I have following hardware with me 1. S32K3x4EVB-T172 (S32K344) 2. PeMicro Debugger. (Note - I dont have Lauterbach TRACE32 tool ) So i request you to please provide me a proper procedure to install HSE (A/B) firmware on s32k344 using PE micro debugger with the help of S32 design studio. Please try to provide me a proper procedure where everything is mentioned like which DS version, RTD, HSE pink file etc to be used. Thanks. Re: How to install S32K344 A/B swap HSE FW using PeMicro debugger on S32K3x4EVB-T172 (S32K344). HSE DEMO code (that can be downloaded with HSE FW) use Lauterbach TRACE32. There is not dedicated examples using different debugger, but there is HSE examples package: https://www.nxp.com/webapp/Download?colCode=S32K3_HSE_DemoExamples It is basically the same functionality as HSE DEMO ported to the code which is debugger independent. For instance if you use S32K344_HSE_FW_INSTALL, you may install HSE FW with using of any debugger.
查看全文
S32K3x4EVB-T172 (S32K344) に PeMicro デバッガを使用して S32K344 A/B スワップ HSE FW をインストールする方法。 こんにちは、 S32K344でOTA A/Bスワップのデモをテストしたい。 そのためには、HSEファームウェアがインストールされていないS32K344チップにHSE(A/B)ファームウェアをインストールする必要があります。 私は以下のハードウェアを所有しています 1. S32K3x4EVB-T172 (S32K344) 2. PeMicroデバッガー。 (注:私はLauterbach TRACE32ツールを持っていません) そこで、S32 design studioの助けを借りてPEマイクロデバッガーを使ってs32k344にHSE(A/B)ファームウェアをインストールする適切な手順を教えていただけるようお願いします。 使用するDSバージョン、RTD、HSEピンクファイルなど、すべてが記載された適切な手順書を提供してください。 ありがとうございます。 Re: How to install S32K344 A/B swap HSE FW using PeMicro debugger on S32K3x4EVB-T172 (S32K344). HSE DEMOコード(HSE FWでダウンロード可能)はLauterbach TRACE32を使用しています。異なるデバッガを使った専用の例はありませんが、HSE例パッケージがあります: https://www.nxp.com/webapp/Download?colCode=S32K3_HSE_DemoExamples これは基本的に、HSE DEMOと同じ機能をデバッガに依存しないコードに移植したものです。例えば、S32K344_HSE_FW_INSTALL を使用すると、任意のデバッガを使用して HSE FW をインストールできます。
查看全文
LPI2C 从机位错误问题 我使用的是S32K146,手册上说当从设备发送1但总线为0时会触发位错误。然而,在实际测试中,当从设备发送0但总线为1时也会触发位错误。我想知道这种现象是否正确? Re: An issue regarding slave bit errors in LPI2C 嗨@GXY , 是的,没错。当从机驱动 SDA 时,位错误标志会被触发,但采样结果却不同。 值比预期值大,不一定只在发送 1 而读取 0 时才如此。 我的猜测是,寄存器描述只是给出了一个位错误标志置位时的示例。 此致, 朱利安
查看全文
PCA9959 异常行为 我实现了一个电路,其中我使用一个控制器(MCU1)向 PCA9959 写入数据,然后使用 SN74CBTLV3257 多路复用器切换 SPI 总线,并使用第二个控制器(MCU2)读取这些值。MCU 之间不进行通信,但实现了轮流进行读写操作的仲裁机制。 只用 MCU1 写入数据而不切换开关时,一切正常。当我在 MCU1 和 MCU2 之间来回切换时,就会出现问题。 在这种情况下,LED驱动器会随机打开/关闭随机排列的LED。奇怪的是,当我使用 MCU1 写入值然后再读取时,寄存器内容似乎没问题。 有什么提示吗?未发现勘误。 开关上的信号: - SDI - 时钟 - SDO - nCS 来自MCU1的其他信号: - nEN - nRESET 非常感谢您的帮助!PCA9959 Re: PCA9959 strange behavior 你好 goepe 再会! 我不是 SN74CBTLV3257 的专家,但根据我能找到的信息,SN74CBTLV3257 是一个无源 FET 开关,而不是缓冲器。 切换通道时,断开的一侧变为高阻抗(浮空),PCA9959 仍然“看到”这些引脚。 尝试在 SCLK、MOSI 和 nCS 上添加上拉/下拉电阻。 希望这些信息对您有所帮助,如果您还需要其他帮助,请告诉我。 祝你今天过得愉快,一切顺利。 Re: PCA9959 strange behavior 谢谢你的建议。我已将 PCA9959 连接到多路复用器的 A 侧连接,而不是 B 侧连接,B 侧连接确实会连接到高阻抗端。我还用高速示波器测量了 PCA9959 的 SPI 信号,但没有发现任何异常。不过我还是会尝试一下,并向你汇报结果。
查看全文
How to Utilize VIT Voice Command Results from DSP in CM33 Hello, I am working with Voice Intelligent Technology (VIT) on the MIMXRT700 EVK using the "mimxrt700evk_dsp_xaf_record_cm33_core0" reference example. The VIT voice commands are being recognized on the DSP, and I would like to use the recognized command results in my CM33 application. Could you please let me know how the VIT results can be accessed from the CM33 core?  If there are any reference examples or documentation that explain the communication flow between the DSP and CM33 cores, please share them. Thanks Re: How to Utilize VIT Voice Command Results from DSP in CM33 Hi @arshtg , We have sdk demo on how to establish communication between CM core and DSP core, please kindly refer to https://github.com/nxp-mcuxpresso/mcuxsdk-examples/tree/release/26.06.00-pvw2/multicore_examples/rpmsg_lite_pingpong_dsp for details. Have a great day, Kan ------------------------------------------------------------------------------- Note: - If this post answers your question, please click the "Mark Correct" button. Thank you! - We are following threads for 7 weeks after the last post, later replies are ignored Please open a new thread and refer to the closed one, if you have a related question at a later point in time. ------------------------------------------------------------------------------- Re: How to Utilize VIT Voice Command Results from DSP in CM33 The mimxrt700evk_dsp_xaf_record_cm33_core0 example already establishes the RPMsg link between the DSP and CM33. As shown in the console logs: [DSP_Main] established RPMsg link When the VIT engine detects a wake word or a voice command, the DSP prints messages such as: [DSP VIT] - WakeWord detected 1 HEY NXP [DSP VIT] - Voice Command detected 6 STOP I would like to use these recognition results in my CM33 application. Specifically, I would like to know where these VIT detection results are generated on the DSP side and how I can access them. I also noticed that the DSP-side implementation has limited accessible source code, so I am unable to determine where the detected wake word and voice command results are obtained. Could you please point me to the relevant source files, APIs, callbacks, or documentation that describe how to obtain the detected wake word and voice command results?
查看全文
LPC55S05-EVKのデフォルトクロック設定 みなさんこんにちは、 私はLPC55シリーズを使い始めたばかりで、現在はLPC55S06-EVKを使用しています。私は、LED D4を点滅させるだけの非常にシンプルなベアメタルプロジェクトを持っています。 混乱しているのは、クロック設定コードがないのにMCUが正常に起動して動作していることです。SystemInit() または ResetISR() のいずれかにデフォルトのクロック設定があるはずだと思っていたのですが、そこには何もありませんでした。 ResetISR()の最初の命令でMCUを停止すると、クロックレジスタはすでに設定されています: MAINCLKSELA = 3 MAINCLKSELB = 0 AHBCLKDIV = 1 しかし、ユーザーマニュアルによると、MAINCLKSELAとAHBCLKDIVのリセット値はどちらも0です。 どうしてそんなことが可能なのか?コードの実行開始前に、これらのレジスタはどこで設定されているのでしょうか? よろしくお願いします、 ニコライ LPC55xx Re: Default clock setting on the LPC55S05-EVK こんにちは、 @Nikolai_Baschinski さん。 ユーザーマニュアルのリセット値はハードウェアリセット値です。 しかし、あなたのアプリケーションResetISR()はLPC55 Boot ROMがすでに実行された後に実行されます。ブートROMはデバイスの起動準備を行い、メインのクロック経路を設定することもあります。例えばResetISR(で停止すると、これらのクロックレジスタは元のリセット値にならない状態になります)。   BR ハリー
查看全文
Sampling issue while streaming for Bayer sensor in iMX95 FRDM Hi Team, We are currently bringing up a Bayer sensor in IMX95 FRDM kit. We initially verified the stream with OS08A20 (reference camera from NXP) we were able to stream. Based on the driver we bringup a driver to support our sensor. It probes fine and media nodes gets generated properly. The media linking is proper which we verified with the media architecture of OS08A20.  We have attached the dmesg log below. Currently we configured the sensor in 8 bit mode (ar0234 sensor) . Current data rate is 800 MBPS per lane .  Data will be out in 4 lane for the sensor . We are able to probe and register. cam -l [0:08:06.049058684] [858]  INFO Camera camera_manager.cpp:340 libcamera v0.0.0+6489-lf-6.18.2-1.0.0 [0:08:06.155690529] [859]  INFO MediaPipeline media_pipeline.cpp:240 Found pipeline: [ar0830 3-0042|0] -> [0|csidev-4ad30000.csi|1] -> [0|4ac10000.syscon:formatter@20|1] -> [2|crossbar] [0:08:06.156726940] [859]  WARN CameraSensorProperties camera_sensor_properties.cpp:586 No static properties available for 'ar0830' [0:08:06.156904446] [859]  WARN CameraSensorProperties camera_sensor_properties.cpp:588 Please consider updating the camera sensor properties database [0:08:06.157054248] [859]  INFO Camera camera_manager.cpp:223 Adding camera '/base/soc/bus@42000000/i2c@42540000/ar0234_mipi@42' for pipeline handler imx8-isi Available cameras: 1: External camera 'ar0234' (/base/soc/bus@42000000/i2c@42540000/ar0234_mipi@42) our camera has been successfully detected , as mentioned above  v4l2-ctl -d 0 -v width=1920,height=1200,pixelformat='GRBG'  --stream-mmap  --verbose VIDIOC_QUERYCAP: ok VIDIOC_G_FMT: ok VIDIOC_S_FMT: ok Format Video Capture Multiplanar:   Width/Height      : 1920/1200   Pixel Format      : 'GRBG' (8-bit Bayer GRGR/BGBG)   Field             : None   Number of planes  : 1   Flags             :    Colorspace        : sRGB   Transfer Function : sRGB   YCbCr/HSV Encoding: ITU-R 601   Quantization      : Limited Range   Plane 0           :      Bytes per Line : 1920      Size Image     : 2304000     VIDIOC_REQBUFS returned 0 (Success)     VIDIOC_CREATE_BUFS returned 0 (Success)     VIDIOC_QUERYBUF returned 0 (Success)     VIDIOC_QUERYBUF returned 0 (Success)     VIDIOC_QUERYBUF returned 0 (Success)     VIDIOC_QUERYBUF returned 0 (Success)     VIDIOC_G_FMT returned 0 (Success)     VIDIOC_QBUF returned 0 (Success)     VIDIOC_QBUF returned 0 (Success)     VIDIOC_QBUF returned 0 (Success)     VIDIOC_QBUF returned 0 (Success)     VIDIOC_STREAMON returned 0 (Success)   We are able to get frames from the camera sensor which we probed with the DSO and verified but the platform is unable to sample it properly. No error comes in the dmesg. Have we missed anything else from the sensor configuration perspective? Also, do the data rate or pixel clock values need to be communicated to the platform through the Device Tree? Specifically, should the following D-PHY parameters be configured in the Device Tree?   cfg-clk-range = <28>; hs-clk-range = <0x2b>;   If these parameters are required, could you clarify on what basis the cfg-clk-range and hs-clk-range values are selected? Are these values derived from the MIPI CSI-2 lane data rate, sensor output resolution, frame rate, or pixel clock? Additionally, what data-rate or pixel-clock range corresponds to the values 28 and 0x2b? Is there a reference table or formula that should be used to determine the correct settings for a given sensor configuration? DMESG LOG [ 104.760033] camera-mipi-clk = 800MHz [ 115.837690] ar0234 3-0042: MIPI Clock = 800, MIPI Lanes = 4 [ 115.837737] ar0234 3-0042: supply avdd not found, using dummy regulator [ 115.837911] ar0234 3-0042: supply dovdd not found, using dummy regulator [ 115.837955] ar0234 3-0042: supply dvdd not found, using dummy regulator [ 115.988087] Current Firmware Version - (11eONO25V6XXX011106014eceGCORAL3) [ 115.988115] Current Firmware Version - (11eONO25V6XXX011106014eceGCORAL3) [ 115.989053] priv->mipi_lane_config is 4 [ 120.297214] SENSOR ID=0x0a56 [ 120.297245] mcu_isp_init [ 125.401238] Detected ar0234 sensor [ 125.453854] ar0234_propagate_fmt is called [ 125.463674] ar0234_propagate_fmt is called [ 125.463959] entering the enum mbus code [ 125.463975] code is 12290 [ 125.463982] entering the enum mbus code [ 125.463989] entering the ar0234_enum_frame_sizes functions [ 125.463995] entering the ar0234_enum_frame_sizes functions [ 125.463999] entering the ar0234_enum_frame_sizes functions [ 125.464004] entering the ar0234_enum_frame_sizes functions [ 125.464033] inside the ar0234_get_selection functions [ 125.464041] inside the ar0234_get_selection functions [ 125.464045] inside the ar0234_get_selection functions [ 126.637118] ar0234_propagate_fmt is called [ 126.637658] entering the enum mbus code [ 126.637681] code is 12290 [ 126.637702] entering the enum mbus code [ 126.637719] entering the ar0234_enum_frame_sizes functions [ 126.637736] entering the ar0234_enum_frame_sizes functions [ 126.637751] entering the ar0234_enum_frame_sizes functions [ 126.637765] entering the ar0234_enum_frame_sizes functions [ 126.637856] inside the ar0234_get_selection functions [ 126.637877] inside the ar0234_get_selection functions [ 126.637892] inside the ar0234_get_selection functions [ 204.157151] audit: type=1006 audit(1782310053.402:28): pid=805 uid=0 old-auid=4294967295 auid=0 tty=(none) old-ses=4294967295 ses=4 res=1 [ 204.157191] audit: type=1300 audit(1782310053.402:28): arch=c00000b7 syscall=64 success=yes exit=1 a0=a a1=ffffc191b2d0 a2=1 a3=0 items=0 ppid=1 pid=805 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4 comm="sshd-session" exe="/usr/libexec/sshd-session" key=(null) [ 204.157211] audit: type=1327 audit(1782310053.402:28): proctitle=737368642D73657373696F6E3A20726F6F74205B707269765D [ 206.826792] ar0234_propagate_fmt is called [ 206.826975] entering the enum mbus code [ 206.826986] code is 12290 [ 206.826994] entering the enum mbus code [ 206.827000] entering the ar0234_enum_frame_sizes functions [ 206.827006] entering the ar0234_enum_frame_sizes functions [ 206.827010] entering the ar0234_enum_frame_sizes functions [ 206.827014] entering the ar0234_enum_frame_sizes functions [ 206.827057] inside the ar0234_get_selection functions [ 206.827065] inside the ar0234_get_selection functions [ 206.827070] inside the ar0234_get_selection functions [ 224.637904] ar0234_propagate_fmt is called [ 224.676405] ar0234_propagate_fmt is called [ 224.676442] entering ar0234_set_fmt [ 224.676447] inside the set format loop if condition [ 224.676451] ar0234->mcu_cam_frmfmt[mode].size.width is 1920 [ 224.676456] ar0234_set_fmt: setting resolution width=1920 height=1200, mode=0 [ 224.680462] priv->mcu_cam_frmfmt[mode].size.width is 1920 [ 224.680476] mc_data[8] = 0x07 (7) [ 224.680480] mc_data[9] = 0x80 (128) [ 224.680484] mc_data[10] = 0x04 (4) [ 224.680487] mc_data[11] = 0xb0 (176) [ 228.270636] ar0234_propagate_fmt is called [ 228.270815] entering the enum mbus code [ 228.270823] code is 12290 [ 228.270832] entering the enum mbus code [ 228.270838] entering the ar0234_enum_frame_sizes functions [ 228.270843] entering the ar0234_enum_frame_sizes functions [ 228.270848] entering the ar0234_enum_frame_sizes functions [ 228.270912] entering the ar0234_enum_frame_sizes functions [ 228.270958] inside the ar0234_get_selection functions [ 228.270965] inside the ar0234_get_selection functions [ 228.270970] inside the ar0234_get_selection functions [ 237.329660] dwc-mipi-csi2 4ad30000.csi: Remote sub-device on pad 1 should implement .get_frame_desc! Forcing VC = 0 and DT = 2a [ 487.004807] ar0234_propagate_fmt is called [ 487.004984] entering the enum mbus code [ 487.005053] code is 12290 [ 487.005065] entering the enum mbus code [ 487.005073] entering the ar0234_enum_frame_sizes functions [ 487.005079] entering the ar0234_enum_frame_sizes functions [ 487.005083] entering the ar0234_enum_frame_sizes functions [ 487.005087] entering the ar0234_enum_frame_sizes functions [ 487.005138] inside the ar0234_get_selection functions [ 487.005146] inside the ar0234_get_selection functions [ 487.005150] inside the ar0234_get_selection functions [ 695.743591] audit: type=1006 audit(1782310544.949:29): pid=869 uid=0 old-auid=4294967295 auid=0 tty=(none) old-ses=4294967295 ses=5 res=1 [ 695.743649] audit: type=1300 audit(1782310544.949:29): arch=c00000b7 syscall=64 success=yes exit=1 a0=a a1=ffffef74ca20 a2=1 a3=0 items=0 ppid=1 pid=869 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=5 comm="sshd-session" exe="/usr/libexec/sshd-session" key=(null) [ 695.743685] audit: type=1327 audit(1782310544.949:29): proctitle=737368642D73657373696F6E3A20726F6F74205B707269765D
查看全文
PT2000 仅用作低侧驱动器 你好, 我使用 PT2000 驱动一个传统的喷油器(12 欧姆),使用一个 PT2000 的一个通道的高侧和低侧输出(喷油器的两根线都连接到 PT2000),一切都按预期工作。 是否可以将喷油器正极线连接到外部持续 +12V 电源,然后仅通过驱动一个低压侧来打开喷油器?我尝试了不修改微代码的这个解决方案,但它不起作用,我需要对微核进行哪些修改才能使其适应这种拓扑结构?更一般地说,我需要以低侧模式驱动电磁阀,但要控制电流,这有可能吗? 感谢您的支持! 此致
查看全文
NXPS32k144へのコード書き込み中に発生する問題 件名:S32K144 EVB - S32 Design Studio 3.5でのデバッグ中のPEmicro接続アシスタントエラー こんにちは、NXPサポートチームの皆さん、 私はS32 Design Studio 3.5を使ってS32K144評価ボード上のアプリケーションのデバッグ中に問題に直面しています。 環境: 基板:S32K144 EVB(必要に応じて、正確な基板部品番号を更新してください) IDE: S32 Design Studio 3.5 デバッグプローブ:搭載OpenSDA(PEmicro) オペレーティングシステム:Windows(バージョンを指定してください) 接続タイプ: OpenSDA USB 問題の説明: デバッグセッションを開始すると、PEmicro接続アシスタントに次のメッセージが表示されます。 「起動設定ダイアログで指定されたインターフェースハードウェアまたはターゲットへの接続中にエラーが発生しました。」 接続アシスタントはOpenSDAプローブを正しく検出します。 USB1上のOpenSDA 名前 = FDC46E50 しかし、デバッガはターゲットのMCUとの通信を確立できません。 観察結果: OpenSDAはPCによって正常に検出されました。 基板の電源LEDが点灯しています。 この問題はデバッグ起動時に発生します。 私は既に以下のことを試しました: デバッグを行う前に、リセットボタンを押してください。 USBケーブルを抜き差しする。 別のUSBケーブルを使用する。 別のノートPC/PCを使っています。 S32 Design Studioの再起動。 同じ問題が依然として続いている。 アプリケーション情報: アプリケーションは以下の通りです: Pins Toolによって生成されたピン構成。 SDKドライバ(PINS_DRV)。 RearWiperControl_Fnモデルコードを生成しました。 main() 関数内で実行されるサンプルコード: PINS_DRV_Init() リアワイパーコントロール_Fn_initialize() リアワイパーコントロール_Fn_step() 質問: ターゲット通信が失敗している間にOpenSDAが検出される原因は何でしょうか? S32DS 3.5と現在のOpenSDAファームウェアの間には、既知の問題はありますか? OpenSDAのファームウェアはアップデートまたは再フラッシュする必要があるでしょうか? S32K144で一括消去または「リセット状態での接続」を行うための推奨手順はありますか? S32K144 EVBには、デバッグのために確認すべきジャンパー設定はありますか? ピンの多重振用設定が間違っていると、プログラム後のSWD通信に干渉する可能性はありますか? 添付: PEmicro接続アシスタントのエラーダイアログのスクリーンショット。 この問題のトラブルシューティングに関するアドバイスをいただければ幸いです。 よろしくお願いします。 Re: Issue facing during flashing code on NXPS32k144 こんにちは、 @Shubham3 さん。 このアプリケーションや例をプログラムする前に、ボードは正しくデバッグされていましたか? アプリケーションがPins Tool / PORTレジスタでPTA4、PTC4、またはPTA5を再設定しているかを確認してください。これらのピンは、S32K144のSWD/リセットに関連しています。 もしそうなら、実際にデバッガの接続を妨げる可能性があります。同様の事例はすでにNXPコミュニティでも報告されています。可能な回復方法や追加の背景については、以下のスレッドを参照してください。 デバイスは安全です、消去から安全でない - NXPコミュニティ 解決済み:S32K144 - PORTA PIN5 CFGとRESET信号の競合 - NXPコミュニティ 解決:S32K118EVB2-Q048でPEmicroデバッガが使えない - NXPコミュニティ よろしくお願いいたします。 パベル Re: Issue facing during flashing code on NXPS32k144 以下の例のコードをフラッシュした後、問題が発生します ADC PALを使って、SWとHWでトリガーされた一連のコンバージョングループを行っています。LPUART上では、各コンバージョングループ実行の平均値を表示します。 その例のドキュメントは、S32 SDKの「Examples and Demos」セクションでご覧いただけます。(/doc/Start_Here.html)
查看全文
NXP Config Tools 26.06 for i.MX not loading saved configuration Hello, While evaluating the new version of the DDR configuration for the i.MX95, I came across what looks like a bug in the configuration tool. Here is exactly what I did, so the behavior can be reproduced: 1. Installed the Linux version of the tool. 2. Created a new configuration. 3. Selected processor MIMX9596xxxxN. 4. Changed the preset to "LPDDR4X EVK / FRDM 15x15 4000MTs Configuration". 5. Saved the configuration, then closed the tool. 6. Reopened the tool and loaded the saved configuration. At that point the DDR configuration is not displayed at all. At least the 26.03 version was starting with MCU unselected (selecting it manually solves the problem), now there is no way to solve the problem. Thank you very much for your help. Best regards, Emanuele Re: NXP Config Tools 26.06 for i.MX not loading saved configuration Also the windows version of the tool shows the same problem. Attached screenshots. Re: NXP Config Tools 26.06 for i.MX not loading saved configuration Hello, Thank you for report this bug in the tool. I was able to see the issue on my side. I will report it with internal team to solve it as soon as possible. Best regards.
查看全文
将FPGA连接到PCA9617A的B端口。 您好: 我的情况如下:MCU 连接到 PCA9617A 的 A 端口,FPGA(作为 I²C 设备)连接到 B 端口。 根据数据手册,端口 B 的电压偏置约为0.55 V。FPGA 的 VIL 规格为0.8 V。这样就只剩下250 mV 的裕量了。 当从MCU向FPGA传输大量数据时,这个裕量会造成问题吗?为了保证可靠运行,建议的VIL裕量是多少? 顺祝商祺! 马可 Re: Connect FPGA to port B of PCA9617A 你好 Marco_MJ 再会! 我认为你已经达到极限了;推荐范围是 >300mV,所以你使用 250mV 的范围存在很大的风险。 希望这些信息对您有所帮助,如果您还需要其他帮助,请告诉我。 祝你今天过得愉快,一切顺利。
查看全文
iMX95 FRDMでのバイエルセンサーのストリーミング中のサンプリング問題 こんにちは、チームのみなさん。 現在、IMX95 FRDMキットでBayerのセンサを導入しています。最初にOS08A20(NXPのリファレンスカメラ)を使用してストリームを検証したところ、ストリーミングが可能でした。ドライバに基づいて、センサをサポートするドライバを呼びます。プローブは問題なく、メディアノードも正しく生成されます。メディア連携は適切であり、OS08A20のメディアアーキテクチャと一致しています。 dmesgログを以下に添付しました。 現在、センサを8ビットモード(ar0234センサ)に設定しています。現在のデータレートは1レーンあたり800 Mbpsです。 センサ用にデータは4レーンに送信されます。私たちは探査と登録が可能です。 cam -l [0:08:06.049058684][858] INFO カメラ camera_manager.cpp:340libcamera v0.0.0+6489-lf-6.18.2-1.0.0 [0:08:06.155690529][859] INFO MediaPipeline media_pipeline.cpp:240パイプラインが見つかりました: [ar0830 3-0042|0] -> [0|csidev-4ad30000.csi|1]-> [0|4ac10000.syscon:formatter@20|1]-> [2|クロスバー] [0:08:06.156726940][859] 警告 CameraSensorProperties camera_sensor_properties.cpp:586'ar0830' には静的プロパティがありません [0:08:06.156904446][859] WARN カメラセンサープロパティ camera_sensor_properties.cpp:588 カメラセンサープロパティデータベースの更新をご検討ください [0:08:06.157054248][859] INFO カメラ camera_manager.cpp:223パイプラインハンドラ imx8-isi にカメラ '/base/soc/bus@42000000/i2c@42540000/ar0234_mipi@42' を追加しています 利用可能なカメラ: 1: 外部カメラ「ar0234」(/base/soc/bus@42000000/i2c@42540000/ar0234_mipi@42) 上記のとおり、カメラは正常に検出されました。 v4l2-ctl -d 0 -v width=1920,height=1200,pixelformat='GRBG' --stream-mmap --verbose VIDIOC_QUERYCAP: OK VIDIOC_G_FMT: OK VIDIOC_S_FMT: OK フォーマット ビデオキャプチャ マルチプレーン: 幅/高さ:1920/1200 ピクセルフォーマット:'GRBG'(8ビットベイヤーGRGR/BGBG) フィールド:なし 飛行機の数:1 旗: カラースペース:sRGB 伝達関数:sRGB YCbCr/HSVエンコーディング:ITU-R 601 量子化:限定範囲 飛行機0: 1行あたりのバイト数:1920 画像サイズ:2304000 VIDIOC_REQBUFS は 0 (成功) を返しました VIDIOC_CREATE_BUFS は 0 (成功) を返しました VIDIOC_QUERYBUF は 0 (成功) を返しました VIDIOC_QUERYBUF は 0 (成功) を返しました VIDIOC_QUERYBUF は 0 (成功) を返しました VIDIOC_QUERYBUF は 0 (成功) を返しました VIDIOC_G_FMT は 0 (成功) を返しました VIDIOC_QBUF は 0 (成功) を返しました VIDIOC_QBUF は 0 (成功) を返しました VIDIOC_QBUF は 0 (成功) を返しました VIDIOC_QBUF は 0 (成功) を返しました VIDIOC_STREAMON は 0 (成功) を返しました   DSOでプローブして確認したカメラセンサーからフレームは取得できますが、プラットフォームは適切にサンプリング できません 。dmesgにはエラーは表示されません。 センサ構成の観点から他に見落としていることはありますか? また、データレートやピクセルクロックの値はデバイスツリーを通じてプラットフォームに伝える必要がありますか? 具体的には、以下のD-PHYパラメータをデバイスツリーに設定する必要がありますか?   cfg-clk-range = <28>; hs-clk-range = <0x2b>;   これらのパラメータが必要な場合、cfg-clk-rangeとhs-clk-rangeの値がどの基準で選ばれるのか、詳しく教えていただけますか? これらの値はMIPI CSI-2レーンデータレート、センサー出力解像度、フレームレート、ピクセルクロックから導き出されるのでしょうか? さらに、28と0x2bという値に対応するデータレートまたはピクセルクロックの範囲はどれですか?特定のセンサー構成に合った適切な設定を決定するための参照表や公式はありますか? DMESGログ [ 104.760033] camera-mipi-clk = 800MHz [ 115.837690 ] ar0234 3-0042: MIPI クロック = 800、MIPI レーン = 4 [ 115.837737] AR0234 3-0042: ダミーレギュレーター使用中の供給AVDDが見つかりません [ 115.837911] AR0234 3-0042: ダミーレギュレーター使用中の供給DOVDDが見つかりません [ 115.837955] AR0234 3-0042: ダミーレギュレーター使用中の供給DVDが見つかりません [ 115.988087 現在のファームウェアバージョン - (11eONO25V6XXX011106014eceGCORAL3) [ 115.988115 現在のファームウェアバージョン - (11eONO25V6XXX011106014eceGCORAL3) [115.989053] priv->mipi_lane_configは4です [ 120.297214 センサーID=0x0a56 [120.297245] mcu_isp_init [ 125.401238 ] ar0234センサーを検出 [ 125.453854 ar0234_propagate_fmt [125.463674] ar0234_propagate_fmtは [ 125.463959] ENUM MBusコードの入力 [125.463975] コードは12290です [ 125.463982] ENUM MBusコードの入力 [ 125.463989] ar0234_enum_frame_sizes関数への入り込み [ 125.463995] ar0234_enum_frame_sizes関数に入力 [ 125.463999] ar0234_enum_frame_sizes関数の入力 [ 125.464004] ar0234_enum_frame_sizes関数の入力 [ 125.464033] ar0234_get_selection関数の内部 [ 125.464041] のar0234_get_selection関数の内部 [ 125.464045] ar0234_get_selection関数の内部 [ 126.637118 ar0234_propagate_fmt [ 126.637658] ENUM MBusコードの入力 [ 126.637681 コードは12290 [126.637702] 入場 ENUM MBusコード [ 126.637719] ar0234_enum_frame_sizes関数への入力 [ 126.637736] ar0234_enum_frame_sizes関数に入る [ 126.637751] ar0234_enum_frame_sizes関数に入ります [ 126.637765] ar0234_enum_frame_sizes関数に入る [ 126.637856] ar0234_get_selection関数の内部 [ 126.637877] ar0234_get_selection関数の内部 [ 126.637892] ar0234_get_selection関数の内部 [ 204.157151] 監査: タイプ=1006 監査(1782310053.402:28):pid=805 uid=0 old-auid=4294967295 auid=0 tty=(none) old-ses=4294967295 ses=4 res=1 [ 204.157191] 監査: タイプ=1300 監査(1782310053.402:28):arch=c00000b7 syscall=64 success=yes exit=1 a0=a a1=ffffc191b2d0 a2=1 a3=0 items=0 ppid=1 pid=805 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=4 comm="sshd-session" exe="/usr/libexec/sshd-session" key=(null) [ 204.157211] 監査: タイプ=1327 監査(1782310053.402:28):proctitle=737368642D73657373696F6E3A20726F6F74205B707269765D [ 206.826792] ar0234_propagate_fmt が呼び出されました [206.826975] enum mbusコードを入力します [206.826986] コードは12290です [206.826994] enum mbusコードを入力します [ 206.827000] ar0234_enum_frame_sizes 関数に入ります [ 206.827006] ar0234_enum_frame_sizes 関数に入ります [ 206.827010] ar0234_enum_frame_sizes 関数に入ります [ 206.827014] ar0234_enum_frame_sizes 関数に入ります [ 206.827057] ar0234_get_selection 関数内 [206.827065] ar0234_get_selection関数内 [ 206.827070] ar0234_get_selection 関数内 [ 224.637904] ar0234_propagate_fmt が呼び出されました [ 224.676405] ar0234_propagate_fmt が呼び出されました [ 224.676442] ar0234_set_fmt に入ります [ 224.676447] セットフォーマットループ内の条件 [ 224.676451] ar0234->mcu_cam_frmfmt[mode].size.width は 1920 です [ 224.676456] ar0234_set_fmt: 解像度を幅=1920、高さ=1200、モード=0に設定 [ 224.680462] priv->mcu_cam_frmfmt[mode].size.width は 1920 です [ 224.680476] mc_data[8] = 0x07 (7) [ 224.680480] mc_data[9] = 0x80 (128) [ 224.680484] mc_data[10] = 0x04 (4) [ 224.680487] mc_data[11] = 0xb0 (176) [ 228.270636] ar0234_propagate_fmt が呼び出されました [228.270815] enum mbusコードを入力します [228.270823] コードは12290です [228.270832] enum mbusコードを入力します [ 228.270838] ar0234_enum_frame_sizes 関数に入ります [ 228.270843] ar0234_enum_frame_sizes 関数に入ります [ 228.270848] ar0234_enum_frame_sizes 関数に入ります [ 228.270912] ar0234_enum_frame_sizes 関数に入ります [228.270958] ar0234_get_selection関数内 [ 228.270965] ar0234_get_selection 関数内 [ 228.270970] ar0234_get_selection 関数内 [ 237.329660] dwc-mipi-csi2 4ad30000.csi:パッド1上のリモートサブデバイスは.get_frame_desc!を実装する必要があります。VC = 0、DT = 2aを強制します。 [ 487.004807] ar0234_propagate_fmt が呼び出されました [487.004984] enum mbusコードを入力します [487.005053] コードは12290です [487.005065] enum mbusコードを入力します [487.005073] ar0234_enum_frame_sizes 関数に入ります [487.005079] ar0234_enum_frame_sizes 関数に入ります [487.005083] ar0234_enum_frame_sizes 関数に入ります [487.005087] ar0234_enum_frame_sizes 関数に入ります [487.005138] ar0234_get_selection関数内 [487.005146] ar0234_get_selection関数内 [487.005150] ar0234_get_selection関数内 [ 695.743591] 監査: タイプ=1006 監査(1782310544.949:29):pid=869 uid=0 old-auid=4294967295 auid=0 tty=(none) old-ses=4294967295 ses=5 res=1 [ 695.743649] 監査: タイプ=1300 監査(1782310544.949:29):Arch=c00000b7 syscall=64 success=yes exit=1 a0=a a1=fffff74ca20 a2=1 a3=0 items=0 ppid=1 pid=869 auid=0 uid=0 gid=0 euid=0 suid=0 fsuid=0 egid=0 sgid=0 fsgid=0 tty=(none) ses=5 comm="sshd-session" exe="/usr/libexec/sshd-session" key=(null) [ 695.743685] 監査: タイプ=1327 監査(1782310544.949:29):proctitle=737368642D73657373696F6E3A20726F6F74205B707269765D
查看全文
CM33でのDSPによるVIT音声コマンド結果の活用方法 こんにちは、 私は音声 Intelligent Technology(VIT)と連携し、「mimxrt700evk_dsp_xaf_record_cm33_core0」リファレンスの例を使ってMIMXRT700 EVKを開発しています。 VITの音声コマンドはDSP上で認識されており、認識されたコマンドの結果をCM33アプリケーションで使いたいと考えています。 CM33コアからVITの結果にどうアクセスできるか教えていただけますか? もしDSPとCM33コア間の通信フローを説明する参考例やドキュメントがあれば、ぜひ共有してください。 ありがとう Re: How to Utilize VIT Voice Command Results from DSP in CM33 こんにちは、 @arshtg さん。 CMコアとDSPコア間の通信確立方法に関するSDKデモがありますので、詳細は https://github.com/nxp-mcuxpresso/mcuxsdk-examples/tree/release/26.06.00-pvw2/multicore_examples/rpmsg_lite_pingpong_dsp をご覧ください。 すてきな一日を、 カン ------------------------------------------------------------------------------- 注記: この投稿があなたの質問への回答になっている場合は、「正解としてマーク」ボタンをクリックしてください。ありがとうございます! - 前回の投稿から7週間Threadをフォローしており、その後の返信は無視しています もし後で関連する質問があれば、新しいThreadを開き、閉じたThreadを参照してください。 ------------------------------------------------------------------------------- Re: How to Utilize VIT Voice Command Results from DSP in CM33 mimxrt700evk_dsp_xaf_record_cm33_core0例はすでにDSPとCM33間のRPMsgリンクを示しています。コンソールログに示されているように: [DSP_Main] RPMsgリンクを確立しました VITエンジンがウェイクワードや音声コマンドを検出すると、DSPは以下のメッセージを出力します。 [DSP VIT] - WakeWordが検出 1 ヘイ NXP [DSP VIT] - 音声コマンド検出 6 停止 これらの認定結果をCM33アプリケーションに活用したいと考えています。具体的には、これらのVIT検出結果がDSP側でどこで生成され、どのようにアクセスできるのか知りたいです。 また、DSP側の実装はアクセス可能なソースコードが限られていることに気づき、検出されたウェイクワードや音声コマンドの結果がどこで得られるのか特定できません。 検出されたウェイクワードや音声コマンドの結果を取得する方法を説明する、関連するソースファイル、API、コールバック、またはドキュメントを教えていただけますか?
查看全文