XMC™ Forum Discussions
text.format{('custom.tabs.no.results')}
Sort by:
XMC™
Hi there,according to the data sheet, debug should be possible with the USB connector X101.I can't get it to work.What settings do I have to use?The d...
Show More
Hi there,
according to the data sheet, debug should be possible with the USB connector X101.
I can't get it to work.
What settings do I have to use?
The debug led is on with a short flicker.
Any idea?
I am very new to this bard and processor and DAVID 4...
Thanks Show Less
according to the data sheet, debug should be possible with the USB connector X101.
I can't get it to work.
What settings do I have to use?
The debug led is on with a short flicker.
Any idea?
I am very new to this bard and processor and DAVID 4...
Thanks Show Less
XMC™
Dear Infineon community,I just started working with an Infineon controller and, since I am just a beginner, it is taking me very long time to achieve ...
Show More
Dear Infineon community,
I just started working with an Infineon controller and, since I am just a beginner, it is taking me very long time to achieve my task. Therefore, I kindly ask you for a little help.
I want my XMC4500 Relax Kit to read out data from an external Analog Digital Converter (ADC) with a defined sample rate and save it to an Micro SD. I am trying to use the SPI interface to communicate with the ADC. In the following you can find the code I wrote and some details about the hardware and the task.
Details Analog Digital converter:
Model: ADS8684
Channels: 4
Datasheet: http://www.ti.com/lit/ds/symlink/ads8684.pdf
DetailsTask:
Sample rate: 10 kHz
Signals to be measured: 3
ADC Device operation mode: MAN_Ch_n (maybe not the appropriate one, see page 47 Datasheet)
Please help me, i am on the verge of a crisis. Hoping hearing from you soon,
As
Code:
Apps:
Show Less
I just started working with an Infineon controller and, since I am just a beginner, it is taking me very long time to achieve my task. Therefore, I kindly ask you for a little help.
I want my XMC4500 Relax Kit to read out data from an external Analog Digital Converter (ADC) with a defined sample rate and save it to an Micro SD. I am trying to use the SPI interface to communicate with the ADC. In the following you can find the code I wrote and some details about the hardware and the task.
Details Analog Digital converter:
Model: ADS8684
Channels: 4
Datasheet: http://www.ti.com/lit/ds/symlink/ads8684.pdf
DetailsTask:
Sample rate: 10 kHz
Signals to be measured: 3
ADC Device operation mode: MAN_Ch_n (maybe not the appropriate one, see page 47 Datasheet)
Please help me, i am on the verge of a crisis. Hoping hearing from you soon,
As
Code:
#include//Declarations from DAVE Code Generation (includes SFR declaration)
int main(void)
{
DAVE_STATUS_t status;
// bool Test = 0;
uint16_t MAN_Ch_0 = 1100000000000000;
uint16_t MAN_Ch_1 = 1100010000000000;
uint16_t MAN_Ch_2 = 1100100000000000;
uint8_t ReadData[512];
FATFS fs;
FIL fil;
FRESULT res;
UINT bw;
status = DAVE_Init(); /* Initialization of DAVE APPs */
if(status != DAVE_STATUS_SUCCESS)
{
XMC_DEBUG("DAVE APPs initialization failed\n");
while(1U)
{
}
}
SPI_MASTER_Transmit(&SPI_MASTER_0, &MAN_Ch_0, sizeof(MAN_Ch_0));
SPI_MASTER_Transmit(&SPI_MASTER_0, &MAN_Ch_1, sizeof(MAN_Ch_1));
SPI_MASTER_Transmit(&SPI_MASTER_0, &MAN_Ch_2, sizeof(MAN_Ch_2));
SPI_MASTER_EnableSlaveSelectSignal(&SPI_MASTER_0, SPI_MASTER_SS_SIGNAL_1);
SPI_MASTER_ClearFlag(&SPI_MASTER_0, (uint32_t)XMC_SPI_CH_STATUS_FLAG_TRANSMIT_SHIFT_INDICATION);
SPI_MASTER_Receive(&SPI_MASTER_0, ReadData, 512U); //Receives 10 bytes of data from slave
res = f_write(&fil, &ReadData, 512, &bw);
while(1U)
{
}
}
Apps:
Show Less
XMC™
Hi!I'm trying to run the example code for the xmc4800 automation board whit the 6 pin user header. I've set the spi pin as following (only for output ...
Show More
Hi!
I'm trying to run the example code for the xmc4800 automation board whit the 6 pin user header. I've set the spi pin as following (only for output stage):
#define DO_SPI_MISO P3_12
#define DO_SPI_MOSI P3_11
#define DO_SPI_SCLK P3_13
#define DO_SPI_SS P4_3
then, i use the usic2_ch1 for the communication with the external iso module
The ODIS of the external isoface is directly connected to 3.3V, so the outputs are supposed enabled. I'm usign an ISO1H812G
The problem is that the outputs are always off, so i can't communicate with the external module. Am i doing something wrong in the code? Show Less
I'm trying to run the example code for the xmc4800 automation board whit the 6 pin user header. I've set the spi pin as following (only for output stage):
#define DO_SPI_MISO P3_12
#define DO_SPI_MOSI P3_11
#define DO_SPI_SCLK P3_13
#define DO_SPI_SS P4_3
then, i use the usic2_ch1 for the communication with the external iso module
void ISOout_INIT(void)
{
//ISOout_OUT_OFF(&ISOout_ODIS);
/*Initialize and Start SPI*/
XMC_SPI_CH_Init(XMC_SPI2_CH1, &do_spi_config);
XMC_SPI_CH_SetBitOrderMsbFirst(XMC_SPI2_CH1);
XMC_SPI_CH_SetWordLength(XMC_SPI2_CH1, (uint8_t)16);
XMC_SPI_CH_ConfigureShiftClockOutput(XMC_SPI2_CH1,XMC_SPI_CH_BRG_SHIFT_CLOCK_PASSIVE_LEVEL_0_DELAY_ENABLED,XMC_SPI_CH_BRG_SHIFT_CLOCK_OUTPUT_SCLK);
/*Input source selected*/
XMC_SPI_CH_SetInputSource(XMC_SPI2_CH1,XMC_SPI_CH_INPUT_DIN0,USIC2_C1_DX0_P3_12);
XMC_SPI_CH_Start(XMC_SPI2_CH1);
/*GPIO configuration*/
XMC_GPIO_SetMode(DO_SPI_MOSI, XMC_GPIO_MODE_OUTPUT_PUSH_PULL_ALT1);
XMC_GPIO_SetMode(DO_SPI_SS, XMC_GPIO_MODE_OUTPUT_PUSH_PULL_ALT1);
XMC_GPIO_SetMode(DO_SPI_SCLK, XMC_GPIO_MODE_OUTPUT_PUSH_PULL_ALT1);
XMC_GPIO_SetMode(DO_SPI_MISO, XMC_GPIO_MODE_INPUT_TRISTATE);
}
void Set_ISOout(uint16_t value)
{
uint16_t OutData = 0x00 | value;
/*Enable Slave Select line 0*/
XMC_SPI_CH_EnableSlaveSelect(XMC_SPI2_CH1, XMC_SPI_CH_SLAVE_SELECT_2);
/*Sending a byte*/
XMC_SPI_CH_Transmit(XMC_SPI2_CH1, OutData, XMC_SPI_CH_MODE_STANDARD);
/*Wait till the byte has been transmitted*/
while((XMC_SPI_CH_GetStatusFlag(XMC_SPI2_CH1) & XMC_SPI_CH_STATUS_FLAG_TRANSMIT_SHIFT_INDICATION) == 0U);
XMC_SPI_CH_ClearStatusFlag(XMC_SPI2_CH1, XMC_SPI_CH_STATUS_FLAG_TRANSMIT_SHIFT_INDICATION);
/*Disable Slave Select line */
XMC_SPI_CH_DisableSlaveSelect(XMC_SPI2_CH1);
XMC_SPI_CH_GetReceivedData(XMC_SPI2_CH1);
}
The ODIS of the external isoface is directly connected to 3.3V, so the outputs are supposed enabled. I'm usign an ISO1H812G
The problem is that the outputs are always off, so i can't communicate with the external module. Am i doing something wrong in the code? Show Less
XMC™
Hallo All,sorry to underline this, but I have found not so easy to find/understand that the MICROCONTROLLERS of the XMC13xx family come from factory w...
Show More
Hallo All,
sorry to underline this, but I have found not so easy to find/understand that the MICROCONTROLLERS of the XMC13xx family come from factory with the programmin port enabled as following:
The DEBUGGER suggested is the XMC Link. It is very easy to connect and the most important feature is the INSULATION between your PC (your body!) and the board with the Microcontroller and the rest of your circuit.
Many of you suggest to connect at least SC,SD and Ground. I raccomend to connect also VCC (just one wire more) in order to be sure that the HIGH LEVEL of the signal is correctly recognised for both sides: Micro and J-Link.
Hope this can be helpful for someone...
BR
Fabio Show Less
sorry to underline this, but I have found not so easy to find/understand that the MICROCONTROLLERS of the XMC13xx family come from factory with the programmin port enabled as following:
- P0.14: this is the SWIO Pin. To be connected to the PIN 2 of the DEBUGGER called SD (Serial Data)
- P0.15: this is the SWCLK Pin. To be connected to the PIN 1 of the DEBUGGER called SC (Serial Clock)
- GND: Ground pin. To be connected to PIN 4 or PIN 5 of the DEBUGGER
- VCC: this is the Supply Voltage PIN. To be connected to the PIN 3 or PIN 6 of the DEBUGGER.
The DEBUGGER suggested is the XMC Link. It is very easy to connect and the most important feature is the INSULATION between your PC (your body!) and the board with the Microcontroller and the rest of your circuit.
Many of you suggest to connect at least SC,SD and Ground. I raccomend to connect also VCC (just one wire more) in order to be sure that the HIGH LEVEL of the signal is correctly recognised for both sides: Micro and J-Link.
Hope this can be helpful for someone...
BR
Fabio Show Less
XMC™
I need to interface with a 1-Wire EEPROM. I wanted to know if it was possible to use the single wire half duplex UART in the XMC series?Or do I have t...
Show More
I need to interface with a 1-Wire EEPROM. I wanted to know if it was possible to use the single wire half duplex UART in the XMC series?
Or do I have to use the full duplex UART and use two FETs to wire the TX/RX together on the 1-wire bus as documented by Maxim Integrated?
I don't want to waste my time trying the half duplex UART if it can't work for some reason or another. Show Less
Or do I have to use the full duplex UART and use two FETs to wire the TX/RX together on the 1-wire bus as documented by Maxim Integrated?
I don't want to waste my time trying the half duplex UART if it can't work for some reason or another. Show Less
XMC™
Does Infineon have a "Product Longevity" program like other MCU manufacturers do?I refer to a page on which there is written for each XMC model the gu...
Show More
Does Infineon have a "Product Longevity" program like other MCU manufacturers do?
I refer to a page on which there is written for each XMC model the guarantee that it will be produced at least until that date.
Or other producers update this forecast annually. This is useful for choosing the product because it guarantees a longevity of it.
For example you can see this page of STM: https://www.st.com/content/st_com/en/support/resources/product-longevity.html
Best regards
Andrea Show Less
I refer to a page on which there is written for each XMC model the guarantee that it will be produced at least until that date.
Or other producers update this forecast annually. This is useful for choosing the product because it guarantees a longevity of it.
For example you can see this page of STM: https://www.st.com/content/st_com/en/support/resources/product-longevity.html
Best regards
Andrea Show Less
XMC™
Hi,Is it possible to use both, Ethernet and EtherCAT simultaneusly on XMC4300/4800 chips? I see EtherCAT mode controls two ports, I'm wondering if I c...
Show More
Hi,
Is it possible to use both, Ethernet and EtherCAT simultaneusly on XMC4300/4800 chips? I see EtherCAT mode controls two ports, I'm wondering if I could switch one of them into normal Ethernet mode.
Or if anyone got an idea how to have both, please let me know. Thanks!
BR
Tero Show Less
Is it possible to use both, Ethernet and EtherCAT simultaneusly on XMC4300/4800 chips? I see EtherCAT mode controls two ports, I'm wondering if I could switch one of them into normal Ethernet mode.
Or if anyone got an idea how to have both, please let me know. Thanks!
BR
Tero Show Less
XMC™
On the website for the XMC4700 microcontroller the feature "EEPROM Emulation" is mentioned, but looking at the reference manual it would seem this is ...
Show More
On the website for the XMC4700 microcontroller the feature "EEPROM Emulation" is mentioned, but looking at the reference manual it would seem this is only for EtherCAT configuration data.
My question is:
Can the EEPROM emulation be used for other purposes if EtherCAT is not needed? If yes, how large is the storage? Show Less
My question is:
Can the EEPROM emulation be used for other purposes if EtherCAT is not needed? If yes, how large is the storage? Show Less
XMC™
Hi, I have just started to work with infineon xmc 1400 boot kit. After reading through some of its docs and DAVE APP examples, I was able to transmit ...
Show More
Hi,
I have just started to work with infineon xmc 1400 boot kit. After reading through some of its docs and DAVE APP examples,
I was able to transmit and receive packets on the can node connected to the on-board transceiver( pins 4.8 and 4.9).
I am trying to now activate can node on the other pins, like 0.4 and 0.5. However, I dont seem to get any raw signal on the scope from the tx and rx pins (0.4 and 0.5)
and also no packets transmitted when connecting via external transceiver module.
Posting my code below here, which tries to transmit a packet on can node 0 configured to use pins 0.4 and 0.5 to send a packet every second.
Any help would be appreciated. Thanks
I have just started to work with infineon xmc 1400 boot kit. After reading through some of its docs and DAVE APP examples,
I was able to transmit and receive packets on the can node connected to the on-board transceiver( pins 4.8 and 4.9).
I am trying to now activate can node on the other pins, like 0.4 and 0.5. However, I dont seem to get any raw signal on the scope from the tx and rx pins (0.4 and 0.5)
and also no packets transmitted when connecting via external transceiver module.
Posting my code below here, which tries to transmit a packet on can node 0 configured to use pins 0.4 and 0.5 to send a packet every second.
Any help would be appreciated. Thanks
Show Less
#include//Declarations from DAVE Code Generation (includes SFR declaration)
/**
* @brief main() - Application entry point
*
* Details of function
* This routine is the application entry point. It is invoked by the device startup code. It is responsible for
* invoking the APP initialization dispatcher routine - DAVE_Init() and hosting the place-holder for user application
* code.
*/
#define OneSec 1000000U
void LED_Toggle();
int main(void)
{
DAVE_STATUS_t status;
CAN_NODE_STATUS_t txStatus;
uint32_t timerStatus;
status = DAVE_Init(); /* Initialization of DAVE APPs */
if(status != DAVE_STATUS_SUCCESS)
{
/* Placeholder for error handler code. The while loop below can be replaced with an user error handler. */
XMC_DEBUG("DAVE APPs initialization failed\n");
while(1U)
{
}
}
timerStatus = SYSTIMER_CreateTimer(OneSec,SYSTIMER_MODE_PERIODIC,(void*)LED_Toggle,NULL);
if(timerStatus != 0U)
{
//Timer created successfully
//Start the timer
status = SYSTIMER_StartTimer(timerStatus);
}
/* Placeholder for user application code. The while loop below can be replaced with user application code. */
while(1U)
{
}
}
void LED_Toggle()
{
volatile CAN_NODE_STATUS_t txStatus;
volatile uint32_t status = 0x00;
DIGITAL_IO_SetOutputHigh(&DIGITAL_IO_0);
status = CAN_NODE_MO_GetStatus ( (void*)CAN_NODE_0.lmobj_ptr[0]);
txStatus = CAN_NODE_MO_Transmit(CAN_NODE_0.lmobj_ptr[0]);
if(txStatus == CAN_NODE_STATUS_SUCCESS)
DIGITAL_IO_ToggleOutput(&DIGITAL_IO_0); //Tx Success LED P4.2
DIGITAL_IO_ToggleOutput(&DIGITAL_IO_1); //Timer LED P4.0
}
void EventHandler_CanNode_0()
{
uint32_t status = 0x00;
XMC_CAN_MO_t* lmsgobjct_ptr_1 = CAN_NODE_0.lmobj_ptr[0]->mo_ptr; // CAN_NODE_0 transmit message object pointer
status = CAN_NODE_MO_GetStatus((void*)CAN_NODE_0.lmobj_ptr[0]);
if(status & XMC_CAN_MO_STATUS_TX_PENDING){
CAN_NODE_MO_ClearStatus((void*)CAN_NODE_0.lmobj_ptr[0],XMC_CAN_MO_RESET_STATUS_TX_PENDING);
//Clear the flag
DIGITAL_IO_SetOutputHigh(&DIGITAL_IO_0);
}
// Check for Node error
if ( CAN_NODE_GetStatus(&CAN_NODE_0) & XMC_CAN_NODE_STATUS_ALERT_WARNING )
{
//Clear the flag
CAN_NODE_DisableEvent(&CAN_NODE_0,XMC_CAN_NODE_EVENT_ALERT);
}
}