Multi Source Translation Content

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

Multi Source Translation Content

Discussions

Sort by:
Inconsistent CAN reception Issue Subject: Inconsistent CAN Message Reception Issue Hello Team, I am encountering an issue with receiving CAN messages consistently. I have configured 4 message buffers (MBs) to receive 4 Rx messages. Issue: Observation 1: When I send the first message (0x301) from the IG block in the CANOE tool, the MPC5748G micro can receive the message, and the respective ISR hits. However, if I send the same message again, the ISR does not hit at any time. Observation 2: Following observation 1, if I send the second message (0x302), the MPC5748G micro can receive the message, and the respective ISR hits. If I send the first message again, the ISR hits, but subsequent attempts to send the same message do not trigger the ISR. Observation 3: If the same message is sent successively, none of the ISRs will be triggered repeatedly. However, sending four different messages one by one will trigger the respective ISRs. Your help with this issue would be greatly appreciated. Please provide the solution on urgent basis. Thank you. Please review the following functions: 1.CAN Initialization function: void Can_InitCAN0 (void) { uint8_t index; CAN_0.MCR.B.MDIS = 1; /* Disable module before selecting clock source*/ CAN_0.CTRL1.B.CLKsrc=0; /* Clock Source = oscillator clock (40 MHz) */ CAN_0.MCR.B.MDIS = 0; /* Enable module for config. (Sets FRZ, HALT)*/ while (!CAN_0.MCR.B.FRZACK) {}/* Wait for freeze acknowledge to set */ /* Good practice: wait for FRZACK on freeze mode entry/exit */ CAN_0.CTRL1.R = 0x04DB0086; /* CAN bus: 40 MHz clksrc, 500 kbps with 16 tq */ // 0x27590000 /* PRESDIV+1 = Fclksrc/Ftq = 40 MHz/8MHz = 5 */ /* so PRESDIV = 4 */ /* PSEG2 = Phase_Seg2 - 1 = 4 - 1 = 3 */ /* PSEG1 = PSEG2 = 3 */ /* PROPSEG= Prop_Seg - 1 = 7 - 1 = 6 */ /* RJW = Resync Jump Width - 1 = 4 = 1 */ /* SMP = 1: use 3 bits per CAN sample */ /* CLKsrc=0 (unchanged): Fcanclk= Fxtal= 40 MHz*/ CAN_0.MCR.R |= CAN_MCR_FRZ | CAN_MCR_HALT; /* enabled to enter Freeze mode */ while (0 == CAN_0.MCR.B.FRZACK){}; while (0 == CAN_0.MCR.B.NOTRDY){}; /* double check that we are actually in freeze mode */ CAN_0.MCR.B.IRMQ = 1; /* Individual Rx Masking And Queue Enable */ #ifdef CAN_0_LOOP_BACK_ENABLED CAN_0.MCR.B.SRXDIS = 0; /* Self Reception Enable */ #else CAN_0.MCR.B.SRXDIS = 1; /* Self Reception Disable */ #endif CAN_0.MCR.B.RFEN = 0; /* RX FIFO Disabled */ CAN_0.MCR.B.AEN = 1; /* Abort Enabled */ CAN_0.MCR.B.FDEN = 0; /* CAN-FD Enabled */ CAN_0.MCR.B.IDAM = 0; /* ID Acceptance Mode is one full ID */ CAN_0.MCR.B.MAXMB = 0x3F; /* 64 MBs */ CAN_0.CTRL1.B.SMP = 1; /* SMP = 1: use 3 bits per CAN sample */ #ifdef CAN_0_LOOP_BACK_ENABLED CAN_0.CTRL1.B.LPB = 1; /* Loopback Enabled */ #else CAN_0.CTRL1.B.LPB = 0; /* Loopback Disabled */ #endif for (index=0; index<96; index++) { CAN_0.MB[index].CS.R = 0; /* Inactivate all 96 message buffers */ } /****Disable CAN FD****/ #if 0 CAN_0.FDCTRL.B.FDRATE = 1; /* Flexible Data Rate Enabled */ CAN_0.FDCTRL.B.MBDSR0 = 0; /* MB data size for R0 is 8 Bytes */ CAN_0.FDCTRL.B.MBDSR1 = 3; /* MB data size for R1 is 64 Bytes */ CAN_0.FDCTRL.B.MBDSR2 = 3; /* MB data size for R2 is 64 Bytes */ CAN_0.CBT.R = 0x80242844; /* Bit timing parameters */ CAN_0.FDCBT.R = 0x001614C6; /* Bit timing parameters */ #endif for (index=0; index<96; index++) { CAN_0.RXIMR[index].R = 0x1FFFFFFF; /* RX Individual Mask is set to check all bits with MB ID */ } CAN_0.RXIMR[45].R = 0; /* MB 45 used for TX */ /* enable interrupt for MB45 - Transmit complete Interrupt */ CAN_0.IMASK2.R |= 1U << 13U; Can_InitCAN0RxMsgBuffers (); CAN_0.RXMGMASK.R = 0x1FFFFFFF; INTC.PSR[568].B.PRC_SELN = 0x8; INTC.PSR[568].B.PRIN = 12; INTC.PSR[569].B.PRC_SELN = 0x8; INTC.PSR[569].B.PRIN = 12; INTC.PSR[570].B.PRC_SELN = 0x8; INTC.PSR[570].B.PRIN = 12; INTC.PSR[571].B.PRC_SELN = 0x8; INTC.PSR[571].B.PRIN = 12; INTC.PSR[572].B.PRC_SELN = 0x8; INTC.PSR[572].B.PRIN = 12; INTC.PSR[573].B.PRC_SELN = 0x8; INTC.PSR[573].B.PRIN = 12; Can0PortInit (); /*CAN_0.CTRL2.R |= 0x00001000u; // ISOCANFD Enabled*/ CAN_0.IFLAG1.R = 0xFFFFFFFFU; CAN_0.IFLAG2.R = 0xFFFFFFFFU; /* enable the FlexCAN module, reset and freeze */ CAN_0.MCR.R &= ~(CAN_MCR_FRZ | CAN_MCR_HALT); while (CAN_0.MCR.B.FRZACK & CAN_0.MCR.B.NOTRDY) {} /* Wait to clear */ /* Good practice: wait for FRZACK on freeze mode entry/exit */ } 2.CAN ISR for 4 MBs are as below: void Can_MsgBuf0003ISR (void) { uint8 Channel; uint8 ReturnValue = 0U; uint32 RegValue; Channel = 0U; if (0U != (CAN_0.IFLAG1.R & (1U << Can_RxMsgBufConfig[Channel].MB))) { ReturnValue |= Can_RxMsg ( Channel, Can_RxMsgBufConfig[Channel].MsgPtr); } Channel = 1U; if (0U != (CAN_0.IFLAG1.R & (1U << Can_RxMsgBufConfig[Channel].MB))) { ReturnValue |= Can_RxMsg ( Channel, Can_RxMsgBufConfig[Channel].MsgPtr); } Channel = 2U; if (0U != (CAN_0.IFLAG1.R & (1U << Can_RxMsgBufConfig[Channel].MB))) { ReturnValue |= Can_RxMsg ( Channel, Can_RxMsgBufConfig[Channel].MsgPtr); } Channel = 3U; if (0U != (CAN_0.IFLAG1.R & (1U << Can_RxMsgBufConfig[Channel].MB))) { ReturnValue |= Can_RxMsg ( Channel, Can_RxMsgBufConfig[Channel].MsgPtr); } } 3.Message buffers initialization function: void Can_InitCAN0RxMsgBuffers (void) { uint8 MsgIndex; uint32 StandardID; for (MsgIndex=0; MsgIndex < NUM_OF_RX_MSGS; MsgIndex++) { StandardID = Can_RxMsgBufConfig[MsgIndex].StdID; *((uint32 *)(CAN0_BASE_REG_ADDR + Can_RxMsgBufConfig[MsgIndex].MBAddrOffset)) = MB_CS_SET_EDL | MB_CS_SET_BRS | MB_CS_CODE_INACTIVE | MB_CS_STD_IDE; *((uint32 *)(CAN0_BASE_REG_ADDR + Can_RxMsgBufConfig[MsgIndex].MBAddrOffset + 4U)) = MB_STD_ID & (StandardID << 18); *((uint32 *)(CAN0_BASE_REG_ADDR + Can_RxMsgBufConfig[MsgIndex].MBAddrOffset)) |= MB_CS_CODE_EMPTY; if (Can_RxMsgBufConfig[MsgIndex].MB < 32U) { CAN_0.IMASK1.R |= 1 << Can_RxMsgBufConfig[MsgIndex].MB; } else { CAN_0.IMASK2.R |= 1 << (Can_RxMsgBufConfig[MsgIndex].MB - 32U); } } } 4.Receive_Msg() function: uint8 Can_RxMsg (uint8 Channel, Can_MsgType * Msg) { uint32 IFlag; uint8 *P8CAN0RxMBData; uint8 Index; uint8 ReturnValue = 0U; if (Channel < NUM_OF_RX_MSGS) { if (Can_RxMsgBufConfig[Channel].MB < 32U) { IFlag = CAN_0.IFLAG1.R & (1U << Can_RxMsgBufConfig[Channel].MB); } else { IFlag = CAN_0.IFLAG2.R & (1U << (Can_RxMsgBufConfig[Channel].MB - 32U)); } if (0U != IFlag) { Msg->StdID = ((*((uint32 *)(CAN0_BASE_REG_ADDR + Can_RxMsgBufConfig[Channel].MBAddrOffset + 4U))) & MB_STD_ID) >> 18; Msg->DLC = ((*((uint32 *)(CAN0_BASE_REG_ADDR + Can_RxMsgBufConfig[Channel].MBAddrOffset))) & MB_CS_DLC) >> 16; Msg->NoOfBytes = Can_CalcNoOfBytes (Msg->DLC); P8CAN0RxMBData = (uint8 *) (CAN0_BASE_REG_ADDR + Can_RxMsgBufConfig[Channel].MBAddrOffset + 8U); for (Index=0; Index < Msg->NoOfBytes; Index++) { Msg->Payload[Index] = *(P8CAN0RxMBData + Index); /* Load data to be transmitted */ } if (Can_RxMsgBufConfig[Channel].MB < 32U) { CAN_0.IFLAG1.R = (1U << Can_RxMsgBufConfig[Channel].MB); } else { CAN_0.IFLAG2.R = (1U << (Can_RxMsgBufConfig[Channel].MB - 32U)); } LED_DS7 = ~LED_DS7; Msg->MsgRcvd++; ReturnValue = 1U; CAN_0.IFLAG1.R = 0xFFFFFFFFU; CAN_0.IFLAG2.R = 0xFFFFFFFFU; } } return (ReturnValue); } 5.Unmask Interrupt function: void Can_UnMaskInterrupt (uint8 Channel, uint32 RegValue) { uint8 IntrID = Can_RxMsgBufConfig[Channel].IntrID; switch (IntrID) { case 0U : CAN_0.IMASK1.R = RegValue; break; case 1U : CAN_0.IMASK1.R = RegValue; break; case 2U : CAN_0.IMASK1.R = RegValue; break; case 3U : CAN_0.IMASK1.R = RegValue; break; case 4U : CAN_0.IMASK1.R = RegValue; break; case 5U : CAN_0.IMASK2.R = RegValue; break; default : break; } } 6.Mask Interrupt function: uint32 Can_MaskInterrupt (uint8 Channel) { uint32 RegValue; uint8 IntrID = Can_RxMsgBufConfig[Channel].IntrID; switch (IntrID) { case 0U : RegValue = CAN_0.IMASK1.R; CAN_0.IMASK1.R &= 0xFFFFFFF0U; // MB 0-3 break; case 1U : RegValue = CAN_0.IMASK1.R; CAN_0.IMASK1.R &= 0xFFFFFF0FU; // MB 4-7 break; case 2U : RegValue = CAN_0.IMASK1.R; CAN_0.IMASK1.R &= 0xFFFFF0FFU; // MB 8-11 break; case 3U : RegValue = CAN_0.IMASK1.R; CAN_0.IMASK1.R &= 0xFFFF0FFFU; // MB 12-15 break; case 4U : RegValue = CAN_0.IMASK1.R; CAN_0.IMASK1.R &= 0x0000FFFFU; // MB 16 - 31 break; case 5U : RegValue = CAN_0.IMASK2.R; CAN_0.IMASK2.R &= 0x00000000U; // MB 32+ ... including MB 45 used for TX break; default : break; } return RegValue; } Re: Inconsistent CAN reception Issue Thanks for your support. Somewhat working. I will let you know the behavior after the complete testing. Re: Inconsistent CAN reception Issue Hi, try below function uint8 Can_RxMsg (uint8 Channel, Can_MsgType * Msg) { uint32 IFlag, dummy; uint8 *P8CAN0RxMBData; uint8 Index; uint8 ReturnValue = 0U; if (Channel < NUM_OF_RX_MSGS) { if (Can_RxMsgBufConfig[Channel].MB < 32U) { IFlag = CAN_0.IFLAG1.R & (1U << Can_RxMsgBufConfig[Channel].MB); } else { IFlag = CAN_0.IFLAG2.R & (1U << (Can_RxMsgBufConfig[Channel].MB - 32U)); } if (0U != IFlag) { Msg->StdID = ((*((uint32 *)(CAN0_BASE_REG_ADDR + Can_RxMsgBufConfig[Channel].MBAddrOffset + 4U))) & MB_STD_ID) >> 18; Msg->DLC = ((*((uint32 *)(CAN0_BASE_REG_ADDR + Can_RxMsgBufConfig[Channel].MBAddrOffset))) & MB_CS_DLC) >> 16; Msg->NoOfBytes = Can_CalcNoOfBytes (Msg->DLC); P8CAN0RxMBData = (uint8 *) (CAN0_BASE_REG_ADDR + Can_RxMsgBufConfig[Channel].MBAddrOffset + 8U); for (Index=0; Index < Msg->NoOfBytes; Index++) { Msg->Payload[Index] = *(P8CAN0RxMBData + Index); /* Load data to be transmitted */ } if (Can_RxMsgBufConfig[Channel].MB < 32U) { CAN_0.IFLAG1.R = (1U << Can_RxMsgBufConfig[Channel].MB); } else { CAN_0.IFLAG2.R = (1U << (Can_RxMsgBufConfig[Channel].MB - 32U)); } dummy = CAN_0.TIMER.R;  // unlock MB globally LED_DS7 = ~LED_DS7; Msg->MsgRcvd++; ReturnValue = 1U; //CAN_0.IFLAG1.R = 0xFFFFFFFFU; //CAN_0.IFLAG2.R = 0xFFFFFFFFU; } } return (ReturnValue); } BR, Petr Re: Inconsistent CAN reception Issue how to read the CAN_TIMER after MB Re: Inconsistent CAN reception Issue Hello Petr, Thanks for your reply. could you please provide the example code to resolve my issue. Requirement: Each ISR shall hit on successful reception of the respective messages. please its very urgent Re: Inconsistent CAN reception Issue Hi, a behavior is due to way you unlock MB. The MB is locked when reading its Control&Status word, it is unlocked when user read free running timer register or read another MB's CS word. When MB is locked it is not free to receive. Read chapter 43.5.7.3 Mailbox lock mechanism for more info. As you do not unlock MB globally, using CAN_TIMER read, then the MB will get new message once another one is serviced, that is your observation 3. So add reading CAN_TIMER after MB is serviced in your Can_RxMsg function.  And remove CAN_0.IFLAG1.R = 0xFFFFFFFFU;CAN_0.IFLAG2.R = 0xFFFFFFFFU; lines at the end as it can also clear other asserted flags. Clear just flag for serviced MB. BR, Petr 
View full article
如何在 SJA1110 中配置 IEEE802.1CB 帧复制和冗余消除 (FRER) 你好,如何在 SJA1110 中配置 IEEE802.1CB 帧复制和冗余消除 (FRER)?我需要实现端口 1 传入数据的帧复制,并将其反映在端口 2 中。如何禁用端口 1 传入的数据,并将其消除在端口 2 中? 我如何配置 CB --> CB 序列生成和单独恢复表以及 CB 序列恢复表 回复:如何在 SJA11 中配置 IEEE802.1CB 帧复制和冗余消除 (FRER) 你好,Pavel, RTAG_OFFSET = 0xF1C1 SN_NUM_GREATER = 1 FRMREPEN = 1 CB_ON_DEST = 1 CB_SID_ON = 0 MACADDR = 0x112233445566 掩码 = 0x0000FFFFFFFFFFFFFF SRCPORT = 4 目标端口 = 端口 1 & 端口 2 TAGPORTS = 端口 1 和端口 2 GENSEQNUM = 1 我已经在 SJA1110 的 Switch 1 中配置了它 我也尝试在 Switch-2 上进行相同的配置,但没有成功 我改为不同的配置 CB_ON_DEST = 1 CB_SID_ON = 0 & 1 MACADDR = 0x112233445566 掩码 = 0x0000FFFFFFFFFFFFFF SRCPORT = 端口 1 & 端口 2 目标端口 = 端口 4 CB序列生成和个体恢复表 TAG_PORTS = 禁用所有端口 IND_REC_PORTS = 端口 4 启用 SEQ_REC_PORTS = 端口 4 启用 SEQRECOFFSET = 0 IND_REC_TIMEOUT = 0 GENSEQNUM = 0 我已经配置了这个 但通常当我不配置这个时,我将传输一个 CAN 消息,该消息将被转换为 UDP 以太网数据包,并且在另一个交换机中,以太网数据包将返回到 CAN 消息 但是当我配置这个,当我传输一个 CAN 消息时,它不会被转换为 UDP 以太网数据包 EthType 显示 F1C1,这不符合 UDP 以太网数据包的要求,因此被拒绝 那么我需要做什么才能以 UDP 以太网数据包的形式传输 我也尝试将 EthType 更改为 0x0800,但它影响了初始交换机配置,数据包作为损坏的以太网数据包,因此它不显示以太网数据包 如果你能给我一个解决这个问题的建议,那将会很有帮助 问候 阿布拉尔 回复:如何在 SJA11 中配置 IEEE802.1CB 帧复制和冗余消除 (FRER) 你好,帕维尔, 您能否与我分享该文档,因为它显示未找到页面,而且我也无法在安全部分找到 此致, 阿布拉尔
View full article
Installation of S32K396 Development Package and S32K396 RTD AUTOSAR R21-11 Version 3.0.0 I have been trying to install the S32K396 Development Package and S32K396 RTD AUTOSAR R21-11 Version 3.0.0 in both the new version (S32 DS Version 3.6) as well as the old version (S32 DS Version 3.5 Update 14); despite trying multiple times, the installation fails with an error message. In the case of S32 DS Version 3.5, the error message is as follows:  And in the case of S32 DS Version 3.6, it fails with an error message stating that a newer Version of the file has already been installed, but I don't find the file anywhere. Could someone please help me with this. Thank you Re: Installation of S32K396 Development Package and S32K396 RTD AUTOSAR R21-11 Version 3.0.0 Thank you @Robin_Shen for the providing the support! Re: Installation of S32K396 Development Package and S32K396 RTD AUTOSAR R21-11 Version 3.0.0 It seems that you have installed newer versions of the software packages. You did not follow the instructions to install those versions of the packages. https://community.nxp.com/t5/S32-Design-Studio-Knowledge-Base/HOWTO-offline-install-S32K3-RTD-3-0-0-in-S32DS-v3-5/ta-p/1753870 Step 6: Remember to select RTD S32K396 for installation Uninstall and then reinstall the S32DS v3.5 may faster. The failure of S32DS v3.6 installation may be caused by not running with administrator privileges or IT setting up a firewall. If you still cannot install S32DS v3.6, it is recommended to create a new question and upload the log file so that our S32DS experts can help you.  C:\NXP\S32DS.3.6.0\_S32 Design Studio for S32 Platform 3.6.0_installation\Logs If you still cannot install S32DS v3.6, it is recommended to install S32DS v3.5 + S32K3 RTD 5.0.0 first. Please refer to: HOWTO: offline install S32K3 RTD 3.0.0 in S32DS v3.5 1. Install S32Design Studio 3.5: S32DS.3.5_b220726_win32.x86_64.exe 2. Install Update 13 for S32DS: SW32_S32DS_3.5.13_D2407.zip 3. Install development package for S32K3XX: SW32K3_S32DS_3.5.13_D2407 4. Install development package for S32K396: SW32K39x_S32DS_3.5.13_D2407.zip 5. Install development package for S32M276: SW32M2_S32DS_3.5.13_D2407 6. Install updatesite for this release: SW32K3_S32M27x_RTD_R21-11_5.0.0_D2410_DesignStudio_updatesite. zip Re: Installation of S32K396 Development Package and S32K396 RTD AUTOSAR R21-11 Version 3.0.0 @Robin_Shen I have gone through the procedure you have suggested and installed the latest version of the software as well as the RTD for the same via offline zip folder, however I am facing an issue with regard to installing/updating the RTD package files in the "S32 DS Extensions and Updates", where the same issue persists as before while installing the RTD package:  The installation error is reverting to the same issue that a newer version of S32K396 Development Kit is already installed, however any example project with regard to S32K396 is not found in this list: Could you please help me finding the example projects for S32K396 Evaluation board. Thank you Re: Installation of S32K396 Development Package and S32K396 RTD AUTOSAR R21-11 Version 3.0.0 Could you please share the example projects that are visible to you after offline installation Re: Installation of S32K396 Development Package and S32K396 RTD AUTOSAR R21-11 Version 3.0.0 These examples are provided by S32K3 RTD. I just installed SW32K3_S32M27x_RTD_R21-11_5.0.0_D2410_DesignStudio_updatesite.zip offline in S32DS v3.6 and I can see these examples.  SW32K3_S32M27x_RTD_R21-11_5.0.0_D2410_DesignStudio_updatesite.zip can be download by click S32K3 Standard Software -> Automotive SW - S32K3/S32M27x - Real-Time Drivers for Cortex-M -> S32K3_S32M27x Real-Time Drivers ASR R21-11 Version 5.0.0 Re: Installation of S32K396 Development Package and S32K396 RTD AUTOSAR R21-11 Version 3.0.0 I am actually trying to install the IDE version 3.5 from the link you have provided, but the installer is rolling back. I am running an example project from the User guide specified for version 3.5, provided by the vendor https://www.nxp.com/document/guide/getting-started-with-s32k396-bga-dc1-evaluation-board:GS-S32K396-BGA-DC1?section=get-software to blink LED 10 times, is there a similar example project in Version 3.6 as well to test if the board is up and running Re: Installation of S32K396 Development Package and S32K396 RTD AUTOSAR R21-11 Version 3.0.0 Hi Why do you want to install S32K3 RTD 3.0.0? If you want to import the sample project developed based on this version, please refer to: HOWTO: offline install S32K3 RTD 3.0.0 in S32DS v3.5 It is recommended to install the latest S32K3 RTD 5.0.0 + S32DS v3.5.  The S32K3xx Development Package 3.6.0 RFP is installed by default in S32DS v3.6. Best Regards, Robin ------------------------------------------------------------------------------- Note: - If this post answers your question, please click the "ACCEPT AS SOLUTION" 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. -------------------------------------------------------------------------------
View full article
IOC timer0/1 channels overflow flag Hi, Micro: S12ZVCA192 For TIM 0/1 channels timer overflow, TFLG2 TOF flag will get set. If we enable multiple channels of TIM0/1 at a time, How to find TFLG2 TOF flag is set because of which channel timer overflow? Re: IOC timer0/1 channels overflow flag Hi, Table 1-13. Interrupt Vector Locations   (Reference Manual) Vector base + 0x1AC TIM0 timer overflow I bit TIM0TSCR2 (TOF) No Yes Vector base + 0x08C TIM1 timer overflow I bit TIM1TSCR2 (TOF) No Yes As you can see different vector number is used for the channels. Moreover, 0x000F is an offset for the register TFLG2 for each timer. Exact address can be found: For TIM0: chapter: M.11 0x05C0-0x05EF TIM0 TIM1: chapter M.8 0x0400-0x042F TIM1 If you use code warrior you van also check header file to get definition of the registers for given timer. Best regards, Ladislav
View full article
s32k3 how to recover flash? Hi NXP,     i'm working on boot application for updating app program.  when boot program pflash meet some error and trigger a swt reset mcu, then checking plash is partial unaccessible.  as pic below, 1. is this a flash ecc error case? 2. in that situation, jlink cant program the flash,   could you give some advice how to recover the plash to normal state? Re: s32k3 how to recover flash? Hi @victory, The flash must be read first. I would maybe focus on why the flashing gets stuck and why the MCU has to be reset by the WDOG. The flash block that is being programmed must not be accessed by any master on the bus. This might requires disabling interrupts or placing the flash driver into SRAM. Regards, Daniel Re: s32k3 how to recover flash? i am using s32k312 is there any method to detect the error without read the target flash region to get if that area has a ecc error and unaccessible? Re: s32k3 how to recover flash? Hi @victory, Can you specify the S32K3xx part number? If the MCU is reset while the flash operation is in progress, the content of the flash cannot be defined, and ECC error should be expected. If there is an uncorrectable ECC error detected during a read operation, the MCRS[ERR] flag is set. The detection can be suppressed: Regards, Daniel 回复: s32k3 how to recover flash? Append: is it possible to disable flash ecc function?
View full article
CAN communication interruption problem with FRDM-KV11Z When testing the FRDM-KV11Z development board with the SDK provided by the official, it was found that the CAN communication could not enter the interrupt. The SDK routines are used with FreeMASTER software. I don't have this device around, so I ported it myself. The following is my code: static void init_CAN(void) { status_t status; flexcan_config_t flexcanConfig; flexcan_timing_config_t timing_config; uint32_t canSrcClock = CLOCK_GetFreq(kCLOCK_CoreSysClk); /* Init FlexCAN module. */ /* * flexcanConfig.clksrc=kFLEXCAN_ClkSrcOsc; * flexcanConfig.baudRate = 1000000U; * flexcanConfig.baudRateFD = 2000000U; * flexcanConfig.maxMbNum = 16; * flexcanConfig.enableLoopBack = false; * flexcanConfig.enableSelfWakeup = false; * flexcanConfig.enableIndividMask = false; * flexcanConfig.enableDoze = false; */ FLEXCAN_GetDefaultConfig(&flexcanConfig); flexcanConfig.clksrc=kFLEXCAN_ClkSrcPeri; flexcanConfig.baudRate = 100000U; /* Update the improved timing configuration */ if (FLEXCAN_CalculateImprovedTimingValues(CAN0, flexcanConfig.baudRate, canSrcClock, &timing_config)) flexcanConfig.timingConfig = timing_config; FLEXCAN_Init(CAN0, &flexcanConfig, canSrcClock); /* Enable CAN interrupt. */ EnableIRQ(CAN0_IRQn); } void CAN0_IRQHandler(void) { uint32_t isrFlags = FLEXCAN_GetStatusFlags(CAN0); uint32_t isrFlagsMB = FLEXCAN_GetMbStatusFlags(CAN0, 0xFFFFFFFFUL); count++; if (isrFlags != 0U) { FLEXCAN_ClearStatusFlags(CAN0, isrFlags); } if (isrFlagsMB != 0U) { /* Read or Write */ if ((isrFlagsMB & (1UL << (FMSTR_FLEXCAN_RXMB))) != 0U) { /* Is any data received? */ if (FLEXCAN_GetMbStatusFlags(CAN0, 1UL << (FMSTR_FLEXCAN_RXMB)) == 0U) { return; } /* Try to read data, when successful, the MB is acknowledged and set for next receive */ status_t s = FLEXCAN_ReadRxMb(CAN0, FMSTR_FLEXCAN_RXMB, &CAN_Rxmsg); } if ((isrFlagsMB & (1UL << (FMSTR_FLEXCAN_TXMB))) != 0U) { /* Acknowledge frame transmission */ CAN_Txmsg.length = 0U; } /* Clear all interrupt flags */ FLEXCAN_ClearMbStatusFlags(CAN0, isrFlagsMB); } } int main(void) { status_t status_can; /* Init board hardware. */ BOARD_InitBootPins(); BOARD_InitBootClocks(); BOARD_InitDebugConsole(); init_CAN(); PRINTF("SPI DAM Init OK.\r\n"); CAN_Txmsg.format = 1; //扩展帧ID CAN_Txmsg.timestamp = 1000; //超时时间 CAN_Txmsg.type = 0; //数据帧 CAN_Txmsg.length = 8; //数据长度 CAN_Txmsg.id = 0x123; //帧ID /* 8位数据 */ CAN_Txmsg.dataByte0 = 0x0; CAN_Txmsg.dataByte1 = 0x1; CAN_Txmsg.dataByte2 = 0x2; CAN_Txmsg.dataByte3 = 0x3; CAN_Txmsg.dataByte4 = 0x4; CAN_Txmsg.dataByte5 = 0x5; CAN_Txmsg.dataByte6 = 0x6; CAN_Txmsg.dataByte7 = 0x7; /* 发送数据 */ FLEXCAN_WriteTxMb(CAN0, 0, &CAN_Txmsg); while (1) { status_can = FLEXCAN_WriteTxMb(CAN0, 0, &CAN_Txmsg); if(status_can != kStatus_Fail) PRINTF("CAN Write success %d\r\n", count); else PRINTF("CAN Write fail %d\r\n", count); SDK_DelayAtLeastUs(1000000, BOARD_BOOTCLOCKRUN_CORE_CLOCK); //延时1秒 } } The data can now be successfully sent. But there is no interrupt to enter, and there is no interrupt to receive data. Re: CAN communication interruption problem with FRDM-KV11Z hi,HL_G Thank you for your interest in NXP Semiconductor products and the opportunity to serve you, I will gladly help you with this. Please confirm whether the development board CAN connect to FreeMASTER through Freemaster-over-can. Please conduct connection test in the following way. You can then Enable CAN interrupt by modifying the following program in the SDK's frdmkv11z_fmstr_example_can demo. Besides, are you saying you don't have any FreeMaster tools? Below is the download link. FreeMASTER tool 3.2 (includes Lite 1.3) – Windows installer (nxp.com.cn) Wish it helps you. If you still have question about it,please kindly let me know. BR Xu Zhang
View full article
MCU rw610 最大無線 LAN 速度 どなたかMCU RW610の最大Wi-Fi速度を教えてください。また、NXPがNORフラッシュとPSRAMをRW610パッケージに組み込む予定があるかどうかを教えてください。感謝。 ブートROM|ブート|フラッシュ パッケージとIO|GPIOの
View full article
MCU rw610 maximum wifi speed Can anyone please tell me the maximum wifi speed for MCU RW610? and if NXP has any plan to embed NOR Flash and PSRAM with RW610 package? Thanks. Boot ROM|Booting | Flash Package and IO|GPIO Re: MCU rw610 maximum wifi speed Hi, The Wi-Fi performance will depend on several things like the CPU power, tasks, environment, etc. In the SDK release notes (SDK_2_16_100_FRDM-RW612\docs\wireless\Release Notes) you can find some throughput tests with the RW612 under certain circumstances. Please take a look to FRDM-RW612. Regards, Daniel.
View full article
S32K396 - Where can I get RDC Checker SW? Hello. I'm using MPC5777c. I'm trying to apply RDC Checker for MPC5777c. Recently I found out that the RDC Checker from S32k396 can be applied to MPC5777c. So I want to get RDC Checker Source Code for S32K396. How or where can I get RDC Checker for S32K396? Please Let me know about it. It would help me a lot. Thank you. #s32k396 #RDC Checker #resolver #RDC Re: S32K396 - Where can I get RDC Checker SW? Hello, You can find it in your NXP SW account: Best regards, Peter
View full article
LPC54628 usb0 FS HC transfer failed after a USB connection inactive for a long I use LPC54628 controller usb0 FS HC connect to a usb device, and it runs 24/7. I was told USB device is configured never go to sleep or deep-sleep, or Deep power-down mode. The issue is when a USB connection inactive for a long time period, the first usb transfer always failed (kStatus_USB_TransferFailed) after usb reset, communication recovered. Base on user manual, by default, usb0 deep-sleep is sw configured,  and Deep power-down mode is "off" Question: 1. if "deep-sleep" is sw configured, what is by default? 2. could you send me a demo code to explicitly to turn  deep-sleep off? Thank you, LPC546xx LPC54xxx USB Re: LPC54628 usb0 FS HC transfer failed after a USB connection inactive for a long LPC54628 operate as a USB host "By default, it is in active mode." I think this is the answer I need. Thanks Re: LPC54628 usb0 FS HC transfer failed after a USB connection inactive for a long Hello @changlin_ren  LPC54628  operate as a USB device or host?  By default, it is in active mode. We need to check the code to determine the exact configuration. How about first running a USB demo from the SDK? Then I can help you check it. BR Alice Re: LPC54628 usb0 FS HC transfer failed after a USB connection inactive for a long rewrite the issue: The issue is when a USB connection inactive for a long time period, the first usb transfer always failed (kStatus_USB_TransferFailed). After usb reset, communication recovered
View full article
LPC54S016 SPI Slave DMA Repeated first byte I've got an LPC54S016 set up as an SPI slave on Flexcomm 0 using the standard settings on the Peripherals setup page. I'm sending a 512 byte packet of data from the transmitter to the LPC, and simultaneously transmitting a 512 byte packet back from the LPC to the transmitter. The LPC is receiving the packet correctly, but when transmitting, it will occasionally transmit a duplicate of the first byte, and omit the last. The packet transmitted from the LPC consists of the repeated string "fedcba9876543210" This is what I'm receiving. As you can see the first byte is duplicated on the first packet, and not on the second: I've checked the signal with a logic analyzer, and can see the repeated byte going over the wire, so it does seem to be generated by the LPC, and not an artefact of the receiver. I found this problem regarding the K22, and wondered if the LPC54 series had the same problem, and if so what the solution is: https://community.nxp.com/t5/Kinetis-Microcontrollers/K22-DSPI-in-Slave-Mode-Sometimes-Has-Duplicate-TX-Bytes/m-p/754080 I tried clearing the TX and RX FIFOS in the DMA callback, and it didn't seem to do anything. Any ideas? Re: LPC54S016 SPI Slave DMA Repeated first byte Update: I spoke with an FAE who suggested checking CPOL and CPHA. I discovered that in earlier testing I'd flipped the both CPOL=1 and CPHA=1 to get any kind of output from the thing, and had not swapped them back to CPOL=0, CPHA=0 at the end of testing. My controller was sending CPOL=0, CPHA=0 and I was receiving the opposite. I have no idea why this would cause the duplicate first byte in the MISO and why MOSI was printed correctly on the target, but it did. Setting both ends to CPOL=0, CPHA=0 removed the duplicate byte. Problem solved. Re: LPC54S016 SPI Slave DMA Repeated first byte HI @Harry_Zhang  Both ends are custom boards. The target board is the LPC54S016 board. The controller board is an FPGA sending 512 byte packets at 6.25 MHz. I've confirmed with a logic analyzer the controller board is sending the correct 512-byte packet to the target, and the target is printing it correctly on receipt. I've confirmed with a logic analyzer that the target board is sending duplicated first byte every other transmission, and the controller board prints the duplicated byte. I'll try and make a cut-down example to show the issue. Glenn Re: LPC54S016 SPI Slave DMA Repeated first byte Hi @andrewsglenn  I try to verify it on my LPC54018 evk board. I import the SDK spi_dma_transfer examples, In this example, one spi instance as master and another spi instance as slave. Master sends a piece of data to slave, and check if the data slave received is correct. I tested it without any problems. May I ask if you are a custom board or an EVK board. BR Hang Re: LPC54S016 SPI Slave DMA Repeated first byte Interrupt mode gets duplicated first byte. Re: LPC54S016 SPI Slave DMA Repeated first byte Sorry for the typo. 512 bus = 512 bytes. Re: LPC54S016 SPI Slave DMA Repeated first byte Hi Hang, I'm not sure how that applies. 6.25 MHz is less than 14 MHz, so should be fine. My question was if the interrupt service routine could keep up with reading and writing 512 bytes at 6.25 MHz without overflowing. Is 'Transaction Mode' in the peripherals tab DMA or interrupt? I sent 0x200 bytes using both Transaction Mode and DMA mode and both showed duplicate bytes. Glenn Re: LPC54S016 SPI Slave DMA Repeated first byte Hi @andrewsglenn  You can refer to the LPC540xx/LPC54S0xx Product data sheet. BR Hang Re: LPC54S016 SPI Slave DMA Repeated first byte I tried using 'transfer mode' instead of DMA and got the same thing. Can polling keep up with 512 bus at 6.25 MHz? Re: LPC54S016 SPI Slave DMA Repeated first byte Hi @andrewsglenn  As a troubleshooting step, try implementing the transfer without using DMA (in polling or interrupt mode) to see if the problem still occurs. This might help isolate the issue to either the DMA or the SPI driver. BR Hang Re: LPC54S016 SPI Slave DMA Repeated first byte 1 MHz duplicates the first byte the same as 6.25 MHz does. At the transmitter end I have a loop that sends the same packet repeatedly. I put a breakpoint on it so I send a message every time I hit 'go' on the debugger. The length of time between pressing 'go' does not seem to change that every other message sends a duplicate first byte. Re: LPC54S016 SPI Slave DMA Repeated first byte Hi @andrewsglenn  If you try to reduce the SPI clock speed, Will this problem still occur? BR Hang Re: LPC54S016 SPI Slave DMA Repeated first byte Is it expected for the MISO line to tail off like this when you're using it as a slave?
View full article
MPC5777C - Questions about the SRAM access configuration Hello! While reading the "Chapter 24 RAM Controller (PRAMC)" of the MPC5777C Reference Manual, I had the following questions: 1 - What is a 64-bit WRP4 read burst? 2 - What is a 2-1-1-1 response? 3 - What is the purpose of the late-write buffer, since there is the possibility of performing write bursts? Does the late-write buffer merges single beat write transactions into a multi beat bursted transaction? 4 - The PRAMC offers the possibility to add an optional read wait-state to register RAM read data prior to returning it on the system bus. What does "register RAM read data means"? Where this data would be registered? In which scenario adding a wait state to the read accesses would be beneficial? 5 - Does the PRAMC or the SRAM have a row buffer to store the last accessed row in the memory array? DRAMs have this resource, but I am not sure if SRAMs have this as well. 6 - DRAMs follows the JEDEC standard to define its commands, such as the activate command (ACT) and the Column Address Strobe (CAS) command. Does the MPC5777C SRAM follow this standard, and thus, work with the same commands? Best regards, Matheus Re: MPC5777C - Questions about the SRAM access configuration 2) Core cycles 3) No, it is not about speed. Data are putted off to late write buffer when another SRAM write is in progress. Pay attention to section 24.4.2.1 64-bit writes 4) I think it is just generic module description. This option works, but as there is no requirement, I don't see any benefit. Re: MPC5777C - Questions about the SRAM access configuration 2) These cycles refer to the clock cycles of the core or the cycles of the PRAMC? 3) So the late write buffer is a memory faster than SRAM? If so, by which technology is the late-write buffer made? 4) The Reference Manual says that one of the PRAMC features is to have "Configurable read access timing (zero or one wait-state programmable) allowing use in large range of frequency targets". If there is no requirement to use this optional wait state, why does the RM says that the optional wait state allows use in a large range of frequency targets? Re: MPC5777C - Questions about the SRAM access configuration 1) 4-beat wrapping burst. Wrapping mean that firstly wanted data are read first. If you need Word2 for instance, sequence is as follows: Word2 - Word3 - Word0 - Word1 2) First data are read is 2 cycles (Word2 in example above), then 1 cycle per word (Word3 - Word0 - Word1) 3) Late write buffer allows not to wait until end of write cycle. From CPU side data are just written to SRAM and terminated. Physically store to SRAM is performed later. 4) It mean 1 clock cycle is added (there is a buffer there), but I don’t see any benefit. As I know there is no requirement to use it. 5, 6) No it static RAM, not dynamic. It works differently.
View full article
RT1166 PWM同步 当我配置同一个子模块的PWM_A和PWM_B时,PWM_A1和PWMA_2的边沿对齐,PWM_B1和PWM_B2的边沿对齐。但是,PWM_A 与 PWM_B 不对齐。有没有办法对齐所有四个通道的输出?
View full article
The FS23 example only has S32K344, but no S32K312? Hi When I import the example, I only see the K344 version. What should I do if I need to use it on K312? Re: The FS23 example only has S32K344, but no S32K312? Hi Can I use the tool to import the K312 project and automatically adapt it, or do I need to create a new project and configure everything to imitate the K344 routine?
View full article
MCIMX6Q的bsp包 你好,我想请问一下MCIMX6Q的芯片有没有类似于MCIMX6ULL这样的简易bsp包,而不是LINUX环境下的bsp包,我想尝试在MCIMX6Q下运行非LINUX的其他实时操作系统(RT-thread系统),这样的bsp包对于移植来说有很大的帮助。 回复: MCIMX6Q的bsp包 详细信息我通过电子邮件发送给您,请检查。 回复: MCIMX6Q的bsp包 仍然建议您使用Linux BSP,以便您可以轻松使用它。 适用于 i.MX 应用处理器的嵌入式 Linux | NXP 半导体
View full article
MTBF - TJA1051 Hello, I am doing MTBF calculation of my project. I need reliability data of TJA1051 or TJA1057 as it is now recommended Is it possible to have these data? Thanks in advance. Re: MTBF - TJA1051 Hello Alaric, we do not provide this kind of information to the email address you are contacting us from. Please register with your company email address and then you can request this information via support ticket. Thank you for your kindly understanding. Kind Regards Romana
View full article
Unable to get RSTP streaming working imx8mp Using the imx8mp evkit with IMX-OS08A20 accessory card. Bitbake imx-image-full and got the camera working with-in the gopoint demos. Am trying to stream the camera over rtsp and view the stream from PC VLC over the network. On the server imx ran: gst-variable-rtsp-server -p 9001 -u "v4l2src device=/dev/video2 ! video/x-raw,width=640,height=480 ! v4l2h264enc ! rtph264pay name=pay0 pt=96" Shows: Pipeline set to: ( v4l2src device=/dev/video2 ! video/x-raw,width=640,height=480 ! v4l2h264enc ! rtph264pay name=pay0 pt=96 )... Stream ready at rtsp://127.0.0.1:9001/stream Then I tried to retrieve the stream from another device over the network, it does not work, but on the server side i see a new line everytime i tried to connect from the client ====== V4L2ENC: 1.24.7 build on Oct 23 2024 09:43:13. ====== ====== V4L2ENC: 1.24.7 build on Oct 23 2024 09:43:13. ====== ====== V4L2ENC: 1.24.7 build on Oct 23 2024 09:43:13. ====== So I tried to load the stream from the imx system itself with: GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:9001/stream ! queue ! rtph264depay ! v4l2h264dec ! autovideosink and GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://192.168.100.219:9001/stream ! queue ! rtph264depay ! v4l2h264dec ! autovideosink I see the same response as above on the server side. Client side logs : root@imx8mpevk:~# GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:9001/stream ! queue ! rtph264depay ! v4l2h264dec ! autovideosink Setting pipeline to PAUSED ... ====== V4L2DEC: 1.24.7 build on Oct 23 2024 09:43:13. ====== Pipeline is live and does not need PREROLL ... Progress: (open) Opening Stream Pipeline is PREROLLED ... Prerolled, waiting for progress to finish... Progress: (connect) Connecting to rtsp://127.0.0.1:9001/stream Progress: (open) Retrieving server options Progress: (open) Retrieving media info 0:00:00.198607035 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:7097:gst_rtspsrc_send: error: Unhandled error 0:00:00.198669410 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:7097:gst_rtspsrc_send: error: Service Unavailable (503) ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Unhandled error Additional debug info: /usr/src/debug/gstreamer1.0-plugins-good/1.24.7.imx/gst/rtsp/gstrtspsrc.c(7097): gst_rtspsrc_send (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Service Unavailable (503) ERROR: pipeline doesn't want to preroll. Setting pipeline to NULL ... 0:00:00.199138163 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:8584:gst_rtspsrc_open: can't get sdp 0:00:00.199200289 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:6515:gst_rtspsrc_loop: we are not connected Not sure what is happening and how to proceed. Any advice greatly appreciated. Yocto Project Re: Unable to get RSTP streaming working imx8mp Managed to fix this, using v4l2src device=/dev/video3 instead. Re: Unable to get RSTP streaming working imx8mp what bsp version do you test? let me reproduce this
View full article
RT1166 PWM Synchronization When I configure PWM_A and PWM_B of the same submodule, the edges of PWM_A1 and PWMA_2 are aligned, and so are the edges of PWM_B1 and PWM_B2. However, PWM_A is not aligned with PWM_B. Is there a way to align the outputs of all four channels? Re: RT1166 PWM Synchronization Hi @tbonkers , Thanks for your interest in the NXP MIMXRT product, I would like to provide service for you. In IMXRT1160RM refence manual chapter 72.3.2.3 Counter Synchronization. https://www.nxp.com/webapp/Download?colCode=IMXRT1160RM It describe PWM Counter Synchronization, Please refer to this.     Wish it helps you. If you still have question about it, please kindly let me know. Wish you a nice day! Best Regards MayLiu
View full article
无法使 RSTP 流工作 imx8mp 使用带有 IMX-OS08A20 附件卡的 imx8mp 评估套件。Bitbake imx-image-full 并使相机在 gopoint 演示中工作。 我正在尝试通过 rtsp 传输摄像机并通过网络查看来自 PC VLC 的流。 在服务器上 imx 运行: gst-variable-rtsp-server -p 9001 -u "v4l2src device=/dev/video2 ! video/x-raw,width=640,height=480 ! v4l2h264enc ! rtph264pay name=pay0 pt=96" Shows: Pipeline set to: ( v4l2src device=/dev/video2 ! video/x-raw,width=640,height=480 ! v4l2h264enc ! rtph264pay name=pay0 pt=96 )... Stream ready at rtsp://127.0.0.1:9001/stream 然后我尝试通过网络从另一个设备检索流,但它不起作用,但在服务器端,每次我尝试从客户端连接时,我都会看到一条新线 ====== V4L2ENC: 1.24.7 build on Oct 23 2024 09:43:13. ====== ====== V4L2ENC: 1.24.7 build on Oct 23 2024 09:43:13. ====== ====== V4L2ENC: 1.24.7 build on Oct 23 2024 09:43:13. ====== 因此我尝试使用以下命令从 imx 系统本身加载流: GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:9001/stream ! queue ! rtph264depay ! v4l2h264dec ! autovideosink and GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://192.168.100.219:9001/stream ! queue ! rtph264depay ! v4l2h264dec ! autovideosink 我在服务器端看到与上面相同的响应。 客户端日志: root@imx8mpevk:~# GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:9001/stream ! queue ! rtph264depay ! v4l2h264dec ! autovideosink Setting pipeline to PAUSED ... ====== V4L2DEC: 1.24.7 build on Oct 23 2024 09:43:13. ====== Pipeline is live and does not need PREROLL ... Progress: (open) Opening Stream Pipeline is PREROLLED ... Prerolled, waiting for progress to finish... Progress: (connect) Connecting to rtsp://127.0.0.1:9001/stream Progress: (open) Retrieving server options Progress: (open) Retrieving media info 0:00:00.198607035 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:7097:gst_rtspsrc_send: error: Unhandled error 0:00:00.198669410 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:7097:gst_rtspsrc_send: error: Service Unavailable (503) ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Unhandled error Additional debug info: /usr/src/debug/gstreamer1.0-plugins-good/1.24.7.imx/gst/rtsp/gstrtspsrc.c(7097): gst_rtspsrc_send (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Service Unavailable (503) ERROR: pipeline doesn't want to preroll. Setting pipeline to NULL ... 0:00:00.199138163 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:8584:gst_rtspsrc_open: can't get sdp 0:00:00.199200289 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:6515:gst_rtspsrc_loop: we are not connected 不确定发生了什么以及如何进行。非常感谢任何建议。 Yocto Project 回复:无法让 RSTP 流工作 imx8mp 设法修复此问题,改用 v4l2src device=/dev/video3。 回复:无法让 RSTP 流工作 imx8mp 你测试的是哪个 bsp 版本?让我重现一下
View full article
RSTPストリーミングをimx8mpで動作させることができません imx-OS08A20 アクセサリカードと imx8mp evkit の使用。Bitbake imx-image-full を使用して、カメラを gopoint デモで動作させるようにしました。 rtsp経由でカメラをストリーミングし、ネットワーク経由でPCVLCからのストリームを表示しようとしています。 サーバー上で imx は次のように実行しました。 gst-variable-rtsp-server -p 9001 -u "v4l2src device=/dev/video2 ! video/x-raw,width=640,height=480 ! v4l2h264enc ! rtph264pay name=pay0 pt=96" Shows: Pipeline set to: ( v4l2src device=/dev/video2 ! video/x-raw,width=640,height=480 ! v4l2h264enc ! rtph264pay name=pay0 pt=96 )... Stream ready at rtsp://127.0.0.1:9001/stream 次に、ネットワーク経由で別のデバイスからストリームを取得しようとしましたが、機能しませんが、サーバー側では、クライアントから接続しようとするたびに新しい行が表示されます ====== V4L2ENC: 1.24.7 build on Oct 23 2024 09:43:13. ====== ====== V4L2ENC: 1.24.7 build on Oct 23 2024 09:43:13. ====== ====== V4L2ENC: 1.24.7 build on Oct 23 2024 09:43:13. ====== だから私はimxシステム自体からストリームをロードしようとしました: GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:9001/stream ! queue ! rtph264depay ! v4l2h264dec ! autovideosink and GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://192.168.100.219:9001/stream ! queue ! rtph264depay ! v4l2h264dec ! autovideosink サーバー側でも上記と同じ応答が表示されます。 クライアント側のログ: root@imx8mpevk:~# GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:9001/stream ! queue ! rtph264depay ! v4l2h264dec ! autovideosink Setting pipeline to PAUSED ... ====== V4L2DEC: 1.24.7 build on Oct 23 2024 09:43:13. ====== Pipeline is live and does not need PREROLL ... Progress: (open) Opening Stream Pipeline is PREROLLED ... Prerolled, waiting for progress to finish... Progress: (connect) Connecting to rtsp://127.0.0.1:9001/stream Progress: (open) Retrieving server options Progress: (open) Retrieving media info 0:00:00.198607035 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:7097:gst_rtspsrc_send: error: Unhandled error 0:00:00.198669410 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:7097:gst_rtspsrc_send: error: Service Unavailable (503) ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Unhandled error Additional debug info: /usr/src/debug/gstreamer1.0-plugins-good/1.24.7.imx/gst/rtsp/gstrtspsrc.c(7097): gst_rtspsrc_send (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Service Unavailable (503) ERROR: pipeline doesn't want to preroll. Setting pipeline to NULL ... 0:00:00.199138163 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:8584:gst_rtspsrc_open: can't get sdp 0:00:00.199200289 1940 0xffffa0000d20 WARN rtspsrc gstrtspsrc.c:6515:gst_rtspsrc_loop: we are not connected 何が起こっているのか、どのように進めればよいのかわかりません。どんなアドバイスでも大歓迎です。 Yocto Project Re:RSTPストリーミングをimx8mpで動作させることができません 代わりに v4l2src device=/dev/video3 を使用して、これを修正することができました。 Re:RSTPストリーミングをimx8mpで動作させることができません どのBSPバージョンをテストしますか?これを再現させてください
View full article