Quantcast
Channel: Infineon Forums
Viewing all 9892 articles
Browse latest View live

[Position2Go Kit] Unable to flash using XMC Flasher

$
0
0
I connected the Position2Go development board via USB to my computer from the debugging side of the board.
Following the very brief flashing guide, I selected the XMC4700-2048 device with a debug clock speed of 100 kHz.
I select the Radar_P2G_FW.hex binary file that is provided in the Position2Go hardware/software kit.
Clicking on connect appears to work properly.

Program fails on error. Log shows "WARNING-com.infineon.XMCFlasher.view.RootLayoutOverviewCon troller-handleProgramEnd: com.infineon.XMCFlasher.DebuggerExceptions: Could not write target memory."

Verify fails on error. Log shows "WARNING-com.infineon.XMCFlasher.view.RootLayoutOverviewCon troller$7-handle: com.infineon.XMCFlasher.DebuggerExceptions: Error while getting core running state."

Erase fails on error. Log shows "WARNING-com.infineon.XMCFlasher.view.RootLayoutOverviewCon troller-handleEraseEnd: com.infineon.XMCFlasher.DebuggerExceptions: Failure during erase. "

Dump Flash works successfully.


Any suggestions to fix these errors?

UART on XMC4200

$
0
0
Hi everyone, I am trying to send out a simple string of "Hello World" using UART on the XMC4200.

Since this is my first project using Infineon chip, I need help on how to start.

Is there a sample UART project for XMC4200 that I can use? or is there any reference that I can follow.

Thanks in advance for your kind responses.

TLE9879 Demo Kits BLDC_BEMF

$
0
0
Hi Fiz,
Thank you for your suggestion. I was able to run the motor reverse after set EMO_RUN to 0.

Regards,
Eugene

iLLd demo missing files

$
0
0
Perhaps a stupid question, but still.
In order to run the demo, you need to "merge" the 0_Src example folder with the 0_Src baseframework folder. Thus, in the src/appsw/tricore folder you will have sample files (cpu0_main etc.) and when building the iLLD files will be picked up from the src/basesw/illd/<your chip> folder.
I have the files you specify added using #include without problems.
UPD:
I checked the files in place.
Try
Code:

#include <Iom/Iom/IfxIom_Iom.h>

How do i do a bit read

$
0
0
could this work?????

void readign5()
{
uint32_t tmp;
uint8_t data = 0;
#define bitRead(value, bit) (((value) >> (bit)) & 0x01)
int datarecieve=0;
uint32_t status1 = 0;
uint32_t status2 = 0;
SPI_MASTER_EnableSlaveSelectSignal(&SPI_MASTER_0, SPI_MASTER_SS_SIGNAL_0);
/* Clear the flags */
SPI_MASTER_ClearFlag(&SPI_MASTER_0,XMC_SPI_CH_STAT US_FLAG_ALTERNATIVE_RECEIVE_INDICATION);
SPI_MASTER_ClearFlag(&SPI_MASTER_0,XMC_SPI_CH_STAT US_FLAG_RECEIVE_INDICATION);
if(status == DAVE_STATUS_SUCCESS)
{
/*Load the command*/
data = IN_STAT_COMP;//bits 31-24
/* Send the read status register command to SPI flash chip */
SPI_MASTER_Transmit(&SPI_MASTER_0, &data, 1);
while(SPI_MASTER_0.runtime->tx_busy);
/* Wait till dummy data is received from chip */
do
{//GET STATUS
status1 = SPI_MASTER_GetFlagStatus(&SPI_MASTER_0,XMC_SPI_CH_ STATUS_FLAG_ALTERNATIVE_RECEIVE_INDICATION);
status2 = SPI_MASTER_GetFlagStatus(&SPI_MASTER_0,XMC_SPI_CH_ STATUS_FLAG_RECEIVE_INDICATION);
}
while(((status1 == 0) && (status2 == 0)));
/* Clear the flags */
SPI_MASTER_ClearFlag(&SPI_MASTER_0,XMC_SPI_CH_STAT US_FLAG_ALTERNATIVE_RECEIVE_INDICATION);
SPI_MASTER_ClearFlag(&SPI_MASTER_0,XMC_SPI_CH_STAT US_FLAG_RECEIVE_INDICATION);
/* Receive the status command from the SPI flash chip */
SPI_MASTER_Receive(&SPI_MASTER_0,&tmp, 1);
while(SPI_MASTER_0.runtime->rx_busy);
datarecieve=bitRead(tmp,4);//READ BIT 4 WHICH IS IGN5 // I ONLY WANT TO READ BIT 4 BACK TO SEE IF ITS A TRUE==1 OR FALSE==0
SPI_MASTER_DisableSlaveSelectSignal(&SPI_MASTER_0) ;
if (datarecieve == 0x01 )
{
pin_ign5=true;
}
else if (datarecieve == 0x00 )
{
pin_ign5=false;
}
}
return pin_ign5;
}

Position2Go coding for measuring and sending data to XMC4800

$
0
0
Hello everyone! I'm new to Infineon Position2Go. I need your help with coding. I want to use Position2Go connect to XMC4800 Relax Kit using RTOS for getting data measurement (from Position2Go). Currently, I can send UART via Position2Go but I don't know how to write program on Position2Go to let it run, measure and sending to XMC4800 yet. Please kindly help me.

Thank you.

.bsdl file for TLE987X family

$
0
0
Hello Allan,

unfortunately our product does not support the boundary scan after IEEE1149.1 JTAG standard.
Normally our costumers use their own code to the test PCB for flashing the device with their application code.
Some do also use ICT to test their board.

Best,
Fiz

VADC FIR filter activation on AURIX TC299 with iLLD

$
0
0
Good morning,
I need to activate on some channels of some VADC groups on an AURIX TC299 the conversion result handling function, e.g. a FIR filter.
I would prefer to do this through the iLLD (and not through a direct manipulation of the GxRCRy registers), but cannot find out how to to that.
Can someone help me further?
Many thanks in advance.

[Distance2Go Kit] Duty Cycle problem

$
0
0
i try to change some values(example: frame_period_ms) i think it relationship to my problem. But the min value of it is 100ms. How i can break it and change to 5ms?. May be it can affect on algo, but i only need the ADC

[SOLVED] TLE9879 Demo Kits BLDC_BEMF

$
0
0
Hi Fiz,
Thank you for your suggestion. I was able to run the motor reverse after set EMO_RUN to 0.

Regards,
Eugene

TC275 Appkit can be identified by DAS, but not by UDE and Memtool

$
0
0
Issue as title proposed, test through on-board DAP and off-board JTAG. Here is my questions:

1) highly doubt the chip's debug interface was locked but the DAS not report DEVICE_LOCKED but DEVICE_DATA when write/read any data from DAS
Attachment 4064

2)if the chip was locked is there any way to recover the board better than replace the chip ( I have not the passworld because it was bought from someone else)


thanks.
?????

firmware update FoE XMC4800

$
0
0
Hi!
I've been able to download a .bin file with FoE from the master, but now i don't know how to retrive the file from where it is sotred and i don't know how to write it in the correct flash partition as to make it the new CPU firmware.
ETHCAT_FWUPDATE_SSC_APPLICATION_XMC48 doesn't work for me, so i adapted it to my application. In the process_app() i write

Code:


if(nAlStatus == STATE_INIT)
        {

                        /************************** check if there is a new firmware inside the backup flash partition ***********/
                        if(FWUPDATE_GetDownloadFinished() == 1) /* the INIT state is entered after the BOOT state → fw update finished*/
                        {
                                firmware_size_bytes = (START_ADDRESS_BACKUP_PARTITION + INFO_OFFSET / 4)[63];

                                  /* check metainfo if firmware for update is available inside backup partition */
                                  if ( (firmware_size_bytes > 0) && (firmware_size_bytes < APP_PARTITION_MAX_SIZE) )
                                  {

                                      /* program new firmware into application partition */
                                      FLASHPROG_Init(START_ADDRESS_APPL_PARTITION, APP_PARTITION_MAX_SIZE, FLASH_OPT_ERASE, FLASH_OPT_CHECK);
                                      FLASHPROG_Data(START_ADDRESS_BACKUP_PARTITION, firmware_size_bytes);
                                      FLASHPROG_Close();

                                      /* delete EEPROM content (2nd 64k sector) */
                                      FLASHPROG_Delete_physical_sector(XMC_FLASH_PHY_SECTOR_4);

                                        /* Restart to retry programming */
                                        BL_Normal_Restart();
                                      /* OK - new firmware was successfully programmed into application partition */

                                  }

                                  /* software from backup partition was just successfully programmed
                                  * into application partition.
                                  * In any case, make sure backup partition is erased before restarting firmware inside
                                  * application partition.
                                  */
                                  ptr_backupdata = START_ADDRESS_BACKUP_PARTITION;
                                  while(ptr_backupdata<START_ADDRESS_BACKUP_PARTITION + BACKUP_PARTITION_MAX_SIZE / 4)
                                  {
                                    /* is erase needed? */
                                    if (*ptr_backupdata!=0)
                                    {
                                      /* erase backup partition */
                                      FLASHPROG_Delete_physical_sectors(ptr_backupdata, 1);
                                    }
                                    ptr_backupdata++;
                                  }

                                  /* Restart inside application partition */
                                  BL_Normal_Restart();

                        }
}


the function BL_Normal_Restart and BL_Normal_Restart

Code:


void BL_Normal_Restart(void)
{
        /* Restart in alternative bootmode 0 */
        /* Clear the reset cause field for proper reset detection of the ssw */
        XMC_SCU_RESET_ClearDeviceResetReason();
        /* Set ABM0 as boot mode in SWCON field of STCON register */
        XMC_SCU_SetBootMode(XMC_SCU_BOOTMODE_NORMAL);
        /* Trigger power on reset */
        PPB->AIRCR = (1 << PPB_AIRCR_SYSRESETREQ_Pos) | (0x5FA << PPB_AIRCR_VECTKEY_Pos) | (0x1 << PPB_AIRCR_PRIGROUP_Pos);
}

void BL_FlashABM0_Restart(void)
{
        /* Restart in alternative bootmode 0 */
        /* Clear the reset cause field for proper reset detection of the ssw */
        XMC_SCU_RESET_ClearDeviceResetReason();
        /* Set ABM0 as boot mode in SWCON field of STCON register */
        XMC_SCU_SetBootMode(XMC_SCU_BOOTMODE_ABM0);
        /* Trigger power on reset */
        PPB->AIRCR = 1 << PPB_AIRCR_SYSRESETREQ_Pos
                        |0x5FA<<PPB_AIRCR_VECTKEY_Pos
                        | 0x1 << PPB_AIRCR_PRIGROUP_Pos;
}


The problem is that the ESC gets stuck in INIT state when i try to go back to OP after the FoE download.

How could i fix it?

Thanks for any help

SENT protocol support in XMC4xxx processors

$
0
0
Is there a way to program the XMC4xxx processor to receive SENT data? I'd like to interface to the TLE4998 Hall Sensor which uses the SENT protocol.

thanks

What is the minimum HI/LI ON pulse requirement for IR2181S?

$
0
0
Hi,

I am using IR21814S for LLC gate driver, and I need to limit the minimum duty of PWM signal. Could you help address the minimum HI/LI on pulse requirement for IR21814S? Thank you.

PWM_CCU4: How to find out if in active or passive part of cycle

$
0
0
Hi,

in my project using an XMC1100 with DAVE Apps I trigger ADC_MEASUREMENT by an PWM_CCU4
on Period match as well as Compare match while counting up.
An interrupt handler for ADC_MEASUREMENT then evaluates the results.

Since I switch a power MOSFET with the PWM output signal my measurements have rather different meanings
whether PWM is in active vs. inactive phase. How can I determine in which phase the PWM_CCU4 is currently?

PWM frequency is low (sub 1kHz). Thus PWM state will not have changed from the one it had during the ADC
did its measurements.

By the way, PWM_CCU4 will not signal Compare match while counting up when Duty Cycle is set to 0.0%, right?

Markus

Get current system clock time

$
0
0

Hi Pirathap,

I looked at the disassembly of your project, and function sort() wasn't created. Rephrasing, since all of its variables are automatics and since it has no incoming our outgoing parameters, the compiler drops its content. Rephrasing, it concludes that it adds no logic to your application other than some void operations, which are subsequently dismissed.

A quick-and-dirty solution would be to declare array as volatile (so volatile int array). Typically you only need this qualifier for SFRs and variables shared between the main program and an ISR. In this case it's netto effect is that the compiler doesn't optimise it out of your application. It's not the best solution, because all reads and writes to array are now explicit, so it doesn't result in the best code.

The preferred solution would be to pass array as a parameter that you want to bubble sort. You probably didn't do that because you wanted to run some quick tests.

Best regards,

Henk-Piet Glas[INDENT]
Principal Technical Specialist
Embedded Software

GTM/MCS development environment

$
0
0
Dear members

I have some question about GTM/MCS on triCore environment as I'm unfamiliar, starter.

GTM/MCS has some version (v1.x, v2.x and v3.x) for now.

Can I know which version the binary had been created with ? ( ex) from binary header ..etc.. )

Also,

I don't know make clear the compile, build tool for GTM/MCS because, there is few information about that. (free, commercial and also, C or assembler ..etc)

Could you let me know how to setup environment for GTM/MCS and better to me if simplest example code ?

Best regards,

shimizus

Many Instances of DAVE on 1 PC

$
0
0
Now I have 3 debuggers to test it and the result is: it runs.

The steps are:

1) Mark the 3 debuggers with a number (1,2,3)

2) Start the freeware USBDeview, connect each debugger to the pc at the usb port you intend to use for this debugger (but only 1 at the same time) and note the displayed serial number of the device 'J-Link' (e.g. 551001948)

3) Place each target code in a separate workspace (if still in same directory, copy each project directory and file .metadata into a separate directory)

4) Open DAVE-IDE Help / Preferences / General / Startup and Shutdown / Workspaces and check 'Prompt for workspace on startup' and close IDE

5) Now start 3 instances of the DAVE-IDE and select one of the 3 workspaces (the pc must have enough ram, each instance needs about 1 gig)

6) Connect all 3 debuggers to the pc and the targets (use same usb ports as at step 2)

7) At all 3 DAVE instances open 'Debug Configurations' (down arrow near the bug on main menue), select tab debugger and at line 'Connection' enter the usb serial number of the debugger connected to the target of this IDE instance

8) And at same tab: All debuggers need different port numbers, thus at debugger 2 and 3 lines 'GDB port', 'SWO port' and 'Telnet port' increment the port numbers of debugger 2 by 10 and of debugger 3 by 20.

That's all.

Best Regards
Wolfgang

XMC Lib I2C error in v2.1.22

$
0
0
Hello,

After upgrading DFP Libary fom v2.11 to 2.12.1 I got my project usine I2C devices on an XMC4500
was not workiung anymore.

After some investigation, I found that that code for XMC_I2C_CH_SetBaudrateEx is probably wrong

Left side : wrong original, right side ( corrected version)
Attachment 4066

This is really frightening!! I really wonder how you test your library updates! Aparently badly.
A simple code review would have catched this.
:(
Jorge
?????

Ethercat Input Only - Star Topology - XMC43/48

$
0
0
Hello,

I would like to know if it's possible to configure the XMC4300 Ethercat Slave stack to work as an input only (end of the bus) ?

In the case of a star topology. The purpose to configure it this way would be to free some internal hardware ressources and some GPIO, peripheral, etc.
Viewing all 9892 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>