October 31, 2016, 7:03 am
Hi,
rather than leave this dangling I thought I would add my findings.
In the function PWM_CCU8_start() in my case it was set to external sync start so it wouldn't restart.
Instead you can use
XMC_CCU8_EnableClock(PWM_CCU8_0.ccu8_module_ptr, PWM_CCU8_0.slice_number);
XMC_CCU8_SLICE_StartTimer(PWM_CCU8_0.ccu8_slice_pt r);
PWM_CCU8_0.state = PWM_CCU8_STATE_RUNNING;
Hope this helps.
↧
October 31, 2016, 7:10 am
Hi,
OK found the answer to my question.
I needed to use slice CUU8_3, which I exposed by adding the CCU8_2 slice first.
CCU8_3 slice has the ability to send it's timer_st1 signal to the gating input of the ADC.
Hope this helps.
↧
↧
October 31, 2016, 8:55 am
Hello Gents,
I have the same problem, and Travis answer does not help.
The latest DMA app (Dave 4) does nor have members ctl_l and ctl_h , but rather :
typedef struct XMC_DMA_LLI
{
uint32_t src_addr; /**< Source address */
uint32_t dst_addr; /**< Destination address */
struct XMC_DMA_LLI *llp; /**< Linked list pointer of type XMC_DMA_LLI_t */
union
{
struct
{
uint32_t enable_interrupt: 1; /**< Enable interrupts? */
uint32_t dst_transfer_width: 3; /**< Destination transfer width */
uint32_t src_transfer_width: 3; /**< Source transfer width */
uint32_t dst_address_count_mode: 2; /**< Destination address count mode */
uint32_t src_address_count_mode: 2; /**< Source address count mode */
uint32_t dst_burst_length: 3; /**< Destination burst length */
uint32_t src_burst_length: 3; /**< Source burst length */
uint32_t enable_src_gather: 1; /**< Enable source gather? */
uint32_t enable_dst_scatter: 1; /**< Enable destination scatter? */
uint32_t : 1; /**< Reserved bits */
uint32_t transfer_flow: 3; /**< DMA transfer flow */
uint32_t : 4; /**< Reserved bits */
uint32_t enable_dst_linked_list: 1; /**< Enable destination linked list? */
uint32_t enable_src_linked_list: 1; /**< Enable source linked list? */
uint32_t : 3; /**< Reserved bits */
} cs;
uint32_t control;
} cu;
uint32_t block_size; /**< Transfer block size */
uint32_t src_status; /**< Source status */
uint32_t dst_status; /**< Destination status */
} XMC_DMA_LLI_t;
How shall we set cu.control , block_size, src_status and dst_status members ?
Jorge
Is there any example somewhere ?
↧
November 1, 2016, 2:59 pm
The symbol & footprint is available for free download
here. Just choose OrCad as the download format. Hope that helps.
↧
November 2, 2016, 12:03 am
Hi,
Assuming IIC 10bit master transmit mode and FIFO mode, when the slave receives the slave address bytes, it can generate FIFO receive buffer event interrupt on slave?
↧
↧
November 2, 2016, 3:07 am
Hi,
I'm studying the following code (this is the slave transmitter code)
https://www.infineon.com/cms/en/tool...g/arduino.html
RGB LED Lighting Shield with XMC1202
The code is under Learn more/Documents/Application examples
RGB LED Lighting Shield XMC1202 Source Code
https://www.infineon.com/dgdl/Infine...ae2081ef4&sd=t
My question SRR why not cleared in PSCR? It seems never cleared. Or it cleared by hardware?
I think it should be cleared in USIC0_2_IRQHandler.
Code:
/* I2C Read Request Received Callback Function
*
* This function is the interrupt service routine when the
* shield receives a request for data and when a start
* condition is received.
*
*/
void USIC0_2_IRQHandler(void)
{
byteCount = 0;
uint8_t send = 0x00;
XMC_USIC_CH_TXFIFO_Flush(I2C_CH_NUM);
XMC_USIC_CH_SetTransmitBufferStatus(I2C_CH_NUM, XMC_USIC_CH_TBUF_STATUS_SET_IDLE);
XMC_USIC_CH_TXFIFO_Flush(I2C_CH_NUM);
I2C_CH_NUM->PSCR |= USIC_CH_PSCR_CST5_Msk; /* Clear NACK flag */
I2C_CH_NUM->PSCR |= USIC_CH_PSCR_CST2_Msk; /* Clear Start Condition Received flag */
if(((XMC_I2C_CH_GetStatusFlag(I2C_CH_NUM) & XMC_I2C_CH_STATUS_FLAG_SLAVE_READ_REQUESTED)>>7) == 1U) /* slave read request event occured */
{
...
↧
November 2, 2016, 4:06 am
Hi ctess,
I understand that the DC sync is working but are you able to observe the SYNC0 pulsed signal ? I wanted to know how to probe this signal to verify on scope if all slaves have similar signal.
I tried with the above mentioned method I just get a continuously high signal. So am I observing something wrong or is the DC really working?
How are you verifying this feature?
Best regards,
Dhanashree
↧
November 2, 2016, 7:10 am
Ok, now I think I get it. In the case of the example it's connected to event0 and event0 is mapped as start trigger.
↧
November 2, 2016, 2:32 pm
Hello,
I am using Dave 4, J-Link v610i to program the XMC4500 - relax lite kit. I tried to run the demo easystart program but the debugger does not work properly.
Even if I set breakpoint in the main.c the debugger does not stop at the breakpoint and it gets terminated. Please help me to solve the issue.
Regrads
Suraj
↧
↧
November 2, 2016, 3:37 pm
Hi,
Find attached an example of a very simplistic telnet server, e.g. only help and bye commands available.
Regards,
Jesus
↧
November 2, 2016, 3:46 pm
Hi,
I guess the problem is that the DMA channel 1 and DMA channel3 are competing trying to set the shadow transfer enable of the two PWMs.
Instead just use one DMA channel and set the shadow_transfer_enable to enable shadow transfer on both.
For this to work you should use the period match event to trigger the transfer instead of the compare match, assuming both PWMs has the same period.
Regards,
Jesus
↧
November 3, 2016, 1:27 am
Hi,
Please have a look to the bootstrap loaders (UART and SPI) in the reference manual.
If those are not fitting your needs you can implement your own using the XMCLib support libraries, e.g. xmc_flash.h, xmc_scu.h and ROM functions as XMC1000_BmiInstallationReq(unsigned short requestedBmiValue) found in XMC1000_RomFunctionTable.h
Regards,
Jesus
↧
November 3, 2016, 5:04 am
Hello,
I'm trying to run the iLLD QspiDmaDemo on the TC277 Starter Kit. I already copied the neccassary files into an empty SW_Framework project in eclipse and built the project.
However, after flashing the output, the project didn't work, because the function call
IfxQspi_initSlso(slso, chConfig->sls.output.mode, chConfig->sls.output.driver, slso->select);
in
IfxQspi_SpiMaster_initChannel() (IfxQspi_SpiMaster.c, Line 281)
Code:
...
if (chHandle->slso.port == NULL_PTR)
{
chHandle->activateSlso = NULL_PTR;
chHandle->deactivateSlso = NULL_PTR;
}
else
{
if (!chConfig->base.mode.autoCS)
{
chHandle->activateSlso = &IfxQspi_SpiMaster_activateSlso;
chHandle->deactivateSlso = &IfxQspi_SpiMaster_deactivateSlso;
/** - Override the SLSO manually as general-purpose output */
chHandle->deactivateSlso(chHandle);
IfxQspi_initSlso(slso, chConfig->sls.output.mode, chConfig->sls.output.driver, IfxPort_OutputIdx_general);
}
else
{
chHandle->activateSlso = NULL_PTR;
chHandle->deactivateSlso = NULL_PTR;
IfxQspi_initSlso(slso, chConfig->sls.output.mode, chConfig->sls.output.driver, slso->select);
}
}
...
tries to set the pin-mode of the slso in the function (IfxPort.c)
Code:
void IfxPort_setPinMode(Ifx_P *port, uint8 pinIndex, IfxPort_Mode mode)
{
volatile Ifx_P_IOCR0 *iocr = &(port->IOCR0);
uint8 iocrIndex = (pinIndex / 4);
uint8 shift = (pinIndex & 0x3U) * 8;
uint16 passwd = IfxScuWdt_getCpuWatchdogPassword();
if (port == &MODULE_P40)
{
IfxScuWdt_clearCpuEndinit(passwd);
port->PDISC.U &= ~(1 << pinIndex);
IfxScuWdt_setCpuEndinit(passwd);
}
__ldmst(&iocr[iocrIndex].U, (0xFFUL << shift), (mode << shift));
}
There occures an error in &iocr[iocrIndex].U:
Attachment 2664
what results in:
Attachment 2665
Has anyone an idea what is wrong?
Whenn I comment the function call of IfxQspi_initSlso() everything works fine, however the chipselect is not activated...
Kind regards
Thomas
↧
↧
November 3, 2016, 7:30 am
Hello,
I am currently using the 24GHz automotive radar development kit and have connected my radar kit to CANoe V8.5 via a Vector box VN7600.
I am able to see messages being delivered in the Trace Window but am unable to see any signals in the Data Window. I cannot add any signals to the window either.
Do I have to create a database file (.dbc) before the signals can be read or is there any other way to read the signals?
Any help offered would be appreciated.
Thanks.
↧
November 3, 2016, 8:19 am
Hi,
is there a how to for using DAVE together with an version control? I want to use SVN for version control and now the question is which files have to be added to the version control and which one are generated. Is there a descrition?
Thanks for Help
Fabian
↧
November 3, 2016, 12:43 pm
Hey guys,
I'm trying to read the data coming from the Infineon
3D magnetic sensor in C#/C++.
Currently I'm sucesssfully connecting to the COM Port using the C# SerialPort class but I don't know how to exchange data between the c#-application and the sensor.
Does someone have an example or can guide me into the right direction for the way of achieving this?
Thanks in advance
Tim
↧
November 3, 2016, 12:54 pm
I have presently build a program to run XMC1300 processor. It uses SPI Master.
The SPI Master revision I'm using has a bug in that the byte offset of receiving bytes is off by 1. I have dwelt with this in code.
Now there appears to be a new version of the SPI Master, I assume it will fix the original problem, but now I suspect my fix will fail.
How best to deal with this situation?
Are old versions of these "libraries" available after an update?
Where are they stored? Are they stored with the project?
↧
↧
November 4, 2016, 1:56 am
Hi Frederik,
CCU4 and CCU8 both can generate a period interrupt in capture mode.
As an example see below.
Code:
#include <xmc_gpio.h>
#include <xmc_ccu4.h>
#define INPUT_PIN P1_2
const XMC_GPIO_CONFIG_t gpio_config =
{
.mode = XMC_GPIO_MODE_INPUT_PULL_UP
};
const XMC_CCU4_SLICE_EVENT_CONFIG_t event_config =
{
.mapped_input = CCU40_IN1_P1_2,
.edge = XMC_CCU4_SLICE_EVENT_EDGE_SENSITIVITY_FALLING_EDGE,
};
const XMC_CCU4_SLICE_CAPTURE_CONFIG_t capture_config =
{
.prescaler_initval = XMC_CCU4_SLICE_PRESCALER_32768
};
volatile uint32_t capture_time = 0;
volatile uint16_t overflow = 0;
void CCU40_1_IRQHandler(void)
{
capture_time = (overflow << 16) | (XMC_CCU4_SLICE_GetCaptureRegisterValue(CCU40_CC41, 0) & 0xffffU);
overflow = 0;
}
void CCU40_0_IRQHandler(void)
{
overflow++;
}
int main(void)
{
XMC_GPIO_Init(INPUT_PIN, &gpio_config);
XMC_CCU4_Init(CCU40, XMC_CCU4_SLICE_MCMS_ACTION_TRANSFER_PR_CR);
XMC_CCU4_SLICE_CaptureInit(CCU40_CC41, &capture_config);
XMC_CCU4_SLICE_Capture0Config(CCU40_CC41, XMC_CCU4_SLICE_EVENT_0);
XMC_CCU4_SLICE_ConfigureEvent(CCU40_CC41, XMC_CCU4_SLICE_EVENT_0, &event_config);
XMC_CCU4_EnableClock(CCU40, 1);
XMC_CCU4_SLICE_SetTimerPeriodMatch(CCU40_CC41, 0xffff);
XMC_CCU4_EnableShadowTransfer(CCU40, XMC_CCU4_SHADOW_TRANSFER_SLICE_1);
XMC_CCU4_SLICE_EnableMultipleEvents(CCU40_CC41, XMC_CCU4_SLICE_MULTI_IRQ_ID_PERIOD_MATCH | XMC_CCU4_SLICE_MULTI_IRQ_ID_EVENT0);
XMC_CCU4_SLICE_SetInterruptNode(CCU40_CC41, XMC_CCU4_SLICE_IRQ_ID_PERIOD_MATCH, 0);
XMC_CCU4_SLICE_SetInterruptNode(CCU40_CC41, XMC_CCU4_SLICE_IRQ_ID_EVENT0, 1);
NVIC_SetPriority(CCU40_0_IRQn, NVIC_EncodePriority(NVIC_GetPriorityGrouping(), 63, 0));
NVIC_EnableIRQ(CCU40_0_IRQn);
NVIC_SetPriority(CCU40_1_IRQn, NVIC_EncodePriority(NVIC_GetPriorityGrouping(), 62, 0));
NVIC_EnableIRQ(CCU40_1_IRQn);
XMC_CCU4_SLICE_StartTimer(CCU40_CC41);
/* Placeholder for user application code. The while loop below can be replaced with user application code. */
while(1U)
{
}
}
Please let us know if this solves your problem.
Regards,
Jesus
↧
November 4, 2016, 4:27 am
Hello everyone,
I currently try to setup the SPI flash driver as master on XMC4500 for an external flash device.
Since output data (from flash device) is available from the falling edge of SCK, I am looking for the correct setting for the SPI interface on XMC,
sofar I didn´t find it. Could someone give me a hint about it ?
On Oscilloscope I could see that the read command sent to flash device, and output data from flash device, all are correct...only XMC4500 read it wrong.
If there is a SPI flash driver available as example for the XMC4500, I would be appreciated to know where I can find it.
Thanks in advance.
↧
November 4, 2016, 5:47 am
Quote:
Originally Posted by
Camryn64
I appreciate the Technical Product Specialist. very cooperative.. other than I have faced this problem, you solved quickly
Hi Camryn64,
Thanks very much for saying that. FYI, recently I was doing some tests using Infineon memtool, and I found that it has a "execute initialisation commands on reset" menu item. In addition I noticed that it already contains some commands that start with this comment:
; Workaround for TLE35584 A-Step Bug
So presumably connecting with memtool will disable the watchdog and restore the connection to your board. You'd then somehow need to add that same workaround into the startup code of your application.
The startup code makes a callback to function _call_init() which you may populate for yourself with user initialisation code, for example the above workaround. To make sure the startup code actually calls this function you need to enable preprocessor macro __CALL_INIT. To make sure you timely meet feeding the watchdog, you may need to reposition _call_init() to an earlier point in time; at this point it's called prior to calling the main entry point. This way you should be able to use the TASKING debugger to debug your application.
Of course the hardware workaround still holds as well, with the added advantage that you needn't make changes to your code.
Best regards,
Henk-Piet Glas
Technical Product Specialist
↧