XMC™ Forum Discussions
Hello,
There is a problem in the XMC_ERU_ETL_Init() function that can cause issues.
The function call uses the union XMC_ERU_ETL_CONFIG_t
union
{
uint32_t input;
struct
{
uint32_t input_a: 2;
uint32_t input_b: 2;
uint32_t : 28;
};
....
}
The function call XMC_ERU_ETL_Init() assumes that the user has zeroed out 28 most significant bits in the input field. This may not be the case if the config is on the stack, i.e.
XMC_ERU_ETL_CONFIG_t etl_config;
etl_config.input_a = 1;
etl_config.input_b = 1;
XMC_ERU_ETL_Init(.., .., &etl_config);
The above call will randomly overwrite the configuration in the EXISEL register... causing issues in previously set-up ERUs.
To fix this the user must explicitly zero initialize the config. So the following code will work fine:
XMC_ERU_ETL_CONFIG_t etl_config = { 0 };
etl_config.input_a = 1;
etl_config.input_b = 1;
XMC_ERU_ETL_Init(.., .., &etl_config);
This is easy to miss and can cause hard to troubleshoot problems.
I suggest that the XMC_ERU_ETL_Init() call is modified to explicitly zero out the 28 most significant bits before assignment to the EXISEL register.
Andriy
Show Less
Dears.
When I click the debug button, the error dialog box will be displayed. I changed the jlink version, but there will still be errors. May I ask why this is, thank you.
Show Less
Dears.
Could you share about the XMC4300 SPI master & slave APP software example?thanks.
I have an XMC-1404 running the I2C_MASTER app connected to a LCD screen with an I2C expander.
If the LCD is not connected or there is an error in the transmission the APP gets stuck at line 1519 in i2c_master.c:
while (I2C_MASTER_GetFlagStatus(handle, (uint32_t)XMC_I2C_CH_STATUS_FLAG_ACK_RECEIVED) == 0U)
{
/* wait for ACK */
}
I am using this command to send data to the LCD:
I2C_MASTER_Transmit(&I2C_MASTER_0,true,I2C_SLAVE_ADDR,lcd_data,6,true);
Is there any way to prevent this?
Thanks,
Nico Show Less
Hi team,
Presently am working on Over current or fault detection using XMC1300 MCU for running our custom BLDC motor, am trying to configure MOTOR0_BLDC_SCALAR_OVER_CURRENT = 5A and detect fault, but am unable to detect, below are my observations and configurations
1) We are using Current Transducer which gives 1.65 V offset (to measure DC Shunt Current) with PWM Freq = 10kHz
2) On what boundary values will ADC peripheral will trigger an protection ISR event ? can you explain me in detail ?
3) I need to test Current limit from 5A to 150A and we are not using any Rshunt resistor, Instead using CT card with offset and Op amp gain was unity.
4) We got 2.45V from CT card for maximum current of 150A measured during load testing, so to measure lower limits there is a diff-cult ? We are getting fault initially (Power ON) when enabling over current limit to 5A and motor stops, so how to come out of this issue
Below are the Images of Phase voltages and Currents please check and let me know
Thanking you
Suraj, N
Show Less
Hi team,
Greetings of the day,
Am presently working on USIC, am trying to set baudrate to 2Mbps
Can you tell me the steps to configure Fractional Divider Register and Baud Rate Generator Registers ?
1) What is the maximum baudrate can I achieve and how to calculate it?
2) What does below function returns either 32Mhz or 64Mhz ?
uint32_t XMC_SCU_CLOCK_GetPeripheralClockFrequency(void)
{
return (SystemCoreClock);
}
Please help me to come out of this issue ..
Thanking you
Suraj,N
Show LessDear Infineon,
Any example to read 32-bit I2S PCM data using XMC4500 using DMA, which is the standard way it is handled in other MCUs like Microchip, Texas Instruments, STM et al ?
With best regards,
Rajiv.
Show LessDears.
There are some problems when using XMC4300 CAN to upgrade the program. When the HEX file is downloaded into PSRAM after the can boot program is started, XMC4300 does not send a reply handshake signal after the download. Through the monitoring of frame data, it is found that even if max. MSG_CNT is greater than 0x2000, XMC4300 has not received Error: 0xADDE response feedback, when testing MSG_CNT=0x4010, there will be Error: 0xADDE response feedback. Could you give me some advice? Thank you.
使用XMC4300 CAN升级程序遇到些问题,将HEX文件 在can引导程序启动之后下载进PSRAM,下载完后XMC4300并没有发应答握手信号, 通过进行帧数据的监测,发现即使max. MSG_CNT 大于0x2000,也没有收到XMC4300的Error: 0xADDE 应答反馈,当测试MSG_CNT=0x4010,会有Error: 0xADDE 应答反馈。能否给些建议, 谢谢,
Show Less
I'm using XMC4700 to build a bootloader run at Normal Boot Mode, application code run at ABM_0 and ABM_1 boot mode. I upload those firmwares into flash according region for 3 boot modes, using DAVE IDE tool. Tested to switch between mode by system reset and it works fine. But in practice, I cannot upload ABM firmware using DAVE IDE tool. I need some serial communication to transmit and write firmware into flash ABM regions when running bootloader and communicate with other MCU.
I don't know how to write new firmware into desire flash region with serial protocol such as UART or SPI. I tried use pointer and loop to store data received from buffer UART to write into flash but it looks like it doesn't work that way. Maybe pointer to modify data doesn't work with flash memory, just work with RAM memory.
I see the USB bootloader example, tested and run OK. But I don't know how to turn it into a UART or SPI communication. The USBD_MS_BOOTLOADER_IAP_XMC47 use file system to store transmitted data and then write to flash. Kind of a lot of stuffs for me to understand. Why they need to use file system to store data? Why don't we just directly write data we receive into desire flash regions? Can we do that?
So I need help to write new firmware into flash at bootloader runtime.
Show Less