How to set Lpi2c speed of S32K312 in RTD5.0? Hi NXP: we're developing project with S32K312 and getting I2C speed issue. I set Lpi2c parameters by reference manual and getting correct speed 1Mbit/s by GUI(Lpi2c_setting.png),but I measured I2C speed about clock waveform(LA_I2C_waveform.png) about 2.667Mhz. Is it correct? thanks. attachment: I2C_setting_from_reference_manual.png Lpi2c_setting.png clock_ip_referencepoints.png LA_I2C_waveform.png current environment: MCU:S32K312/100pin S32DS Product:3.5.0.202207261815 RTD S32KXX:RTD5.0.0.202407261948 BR Nelson Re: How to set Lpi2c speed of S32K312 in RTD5.0? Yes, I'm afraid you shouldn't select LPI2C_FASTPLUS_MODE with 1 Mbit/s because the reference manual says so. Re: How to set Lpi2c speed of S32K312 in RTD5.0? Hi Robin: I modified I2C parameters from fast+ mode to fast mode in master mode, and GUI show 400000(Baud rate), but I measured speed about 385Khz. it looks like not accurate about GUI value and LA value, thanks. attachment: 20250306-2-I2C_Test_S32K312.7z BR Nelson Re: How to set Lpi2c speed of S32K312 in RTD5.0? Hi Robin: just now, I saw reference manual as you posted information(LPI2C master mode operation supports up to fast Mode = 400KHz), so S32K312 only supports fast mode in master mode(Up to 400Khz). if I want to adjust more than 400Khz, it is invaild for usage, Is it correct? thanks. BR Nelson Re: How to set Lpi2c speed of S32K312 in RTD5.0? Hi Robin: I always use I2C master mode as LPI2C_FASTPLUS_MODE which support 1 Mbit/s.however, I created simple project by GPIO and I2C function and set I2C parameters as current project, and also tested I2C speed is about 888~914Khz on our PCB board. now you can change MCU package of attachment from 100pin to 172pin for your EVB testing,thanks. attachment: 20250306-I2C_Test_S32K312.7z BR Nelson Re: How to set Lpi2c speed of S32K312 in RTD5.0? Sorry for the inconvenience. It would be best if S32 Design Studio would warn you when you select master mode but exceed 400 kbps data rate. S32K3XXRM mentioned: •LPI2C slave mode operation supports up to high speed mode = 3.4MHz (3.4 Mbps data rate; effective data rate reduces according to I2C protocol). •LPI2C master mode operation supports up to fast Mode = 400KHz (400 kbps data rate; effective data rate reduces according to I2C protocol). Re: How to set Lpi2c speed of S32K312 in RTD5.0? Hi Robin: I tried to change Clock_Ip_ReferencePoints from custom(8Mhz) to AIPS_SLOW_CLK(30Mhz), and also changes I2C timing that it calculated I2C baud rate 1000000. but I measured waveform about 864KHz. now I confuse about calculating result of Lpi2c GUI. please help us, thanks. attachment: clock_ip_referencepoints2.png LA_I2C_waveform2.png Lpi2c_setting2.png BR Nelson Re: How to set Lpi2c speed of S32K312 in RTD5.0? Hi Nelson,
The LPI2C_CLK comes from AIPS_SLOW_CLK. So would you please configure AIPS_SLOW_CLK in clock_ip_referencepoints.png? Otherwise, the S32 Configuration Tool may use the wrong frequency (80MHz CUSTOM) for calculation.
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. -------------------------------------------------------------------------------
查看全文