Skip to content

Commit 674ee37

Browse files
authored
Merge pull request #220 from Infineon/release/2.1.0
Added XMC1300 Boot Kit support in 2.x
2 parents 0188fdc + 9d230ab commit 674ee37

19 files changed

+9389
-5
lines changed

.github/workflows/compile-platform-examples.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,16 @@ jobs:
5353
stackMem: true
5454
dma: false
5555
alarmRtc: false
56+
- fqbn: Infineon:xmc:XMC1300_Boot_Kit
57+
i2s: false
58+
dieTemp: true
59+
heapMem: true
60+
sleep1100: true
61+
sleep4700 : false
62+
stackMem: true
63+
multiSerial: false
64+
dma: false
65+
alarmRtc: false
5666
- fqbn: Infineon:xmc:XMC4200_Platform2GO
5767
i2s: false
5868
dieTemp: false

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ This repository integrates [Infineon's](https://www.infineon.com/) XMC microcont
2020

2121
* [XMC1100 XMC 2Go](https://www.infineon.com/cms/en/product/evaluation-boards/kit_xmc_2go_xmc1100_v1/)
2222
* [XMC1100 Boot Kit](https://www.infineon.com/cms/en/product/evaluation-boards/kit_xmc11_boot_001/)
23+
* [XMC1300 Boot Kit](https://www.infineon.com/cms/de/product/evaluation-boards/kit_xmc13_boot_001/)
2324
* [XMC1400 Kit for Arduino](https://www.infineon.com/cms/en/product/evaluation-boards/kit_xmc1400_arduino/)
2425
* [XMC4200 Platform 2Go](https://www.infineon.com/cms/en/product/evaluation-boards/kit_xmc_plt2go_xmc4200/)
2526
* [XMC4400 Platform 2Go](https://www.infineon.com/cms/en/product/evaluation-boards/kit_xmc_plt2go_xmc4400//)
@@ -33,6 +34,7 @@ Please visit also the Wiki for additional information, e.g. datasheets, pin out
3334

3435
* Page for [XMC1100 XMC 2Go](https://github.com/Infineon/XMC-for-Arduino/wiki/XMC-2Go)
3536
* Page for [XMC1100 Boot Kit](https://github.com/Infineon/XMC-for-Arduino/wiki/XMC1100-Boot-Kit)
37+
* Page for [XMC1300 Boot Kit](https://github.com/Infineon/XMC-for-Arduino/wiki/XMC1300-Boot-Kit)
3638
* Page for [XMC1400 Kit for Arduino](https://github.com/Infineon/XMC-for-Arduino/wiki/XMC1400-Kit-for-Arduino)
3739
* Page for [XMC4200 Platform 2Go](https://github.com/Infineon/XMC-for-Arduino/wiki/XMC4200-Platform2Go)
3840
* Page for [XMC4400 Platform 2Go](https://github.com/Infineon/XMC-for-Arduino/wiki/XMC4400-Platform2Go)

boards.txt

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,50 @@ XMC1100_XMC2GO.menu.LIB.DSP.library.selected=-DARM_LIB_CMSIS_DSP
9090
XMC1100_XMC2GO.menu.LIB.DSPNN=ARM DSP / ARM NN Framework
9191
XMC1100_XMC2GO.menu.LIB.DSPNN.library.selected=-DARM_LIB_CMSIS_DSP -DARM_LIB_CMSIS_NN
9292

93+
####################################################
94+
XMC1300_Boot_Kit.name=XMC1300 Boot Kit
95+
XMC1300_Boot_Kit.upload.tool=xmcprog
96+
XMC1300_Boot_Kit.upload.speed=115200
97+
XMC1300_Boot_Kit.upload.resetmethod=ck
98+
XMC1300_Boot_Kit.upload.maximum_size=204800
99+
XMC1300_Boot_Kit.upload.wait_for_upload_port=true
100+
101+
XMC1300_Boot_Kit.communication=usb
102+
XMC1300_Boot_Kit.protocol=dragon_isp
103+
XMC1300_Boot_Kit.program.protocol=dragon_isp
104+
XMC1300_Boot_Kit.program.tool=xmcprog
105+
XMC1300_Boot_Kit.program.extra_params=-Pusb
106+
107+
XMC1300_Boot_Kit.serial.disableDTR=true
108+
XMC1300_Boot_Kit.serial.disableRTS=true
109+
110+
XMC1300_Boot_Kit.build.mcu=cortex-m0
111+
XMC1300_Boot_Kit.build.f_cpu=32000000L
112+
XMC1300_Boot_Kit.build.board=ARM_XMC
113+
XMC1300_Boot_Kit.build.board.version=1302
114+
XMC1300_Boot_Kit.build.board.type=T038x0200
115+
XMC1300_Boot_Kit.build.board.v=0200
116+
XMC1300_Boot_Kit.build.core=./
117+
XMC1300_Boot_Kit.build.variant=XMC1300
118+
XMC1300_Boot_Kit.build.board_variant=XMC1300_Boot_Kit
119+
XMC1300_Boot_Kit.build.flash_size=200K
120+
XMC1300_Boot_Kit.build.flash_ld=linker_script_200k.ld
121+
XMC1300_Boot_Kit.build.extra_flags=-DARM_MATH_CM0 -DXMC1_SERIES
122+
123+
XMC1300_Boot_Kit.menu.UART.debug=PC
124+
XMC1300_Boot_Kit.menu.UART.debug.uart.selected=-DSERIAL_HOSTPC
125+
XMC1300_Boot_Kit.menu.UART.onBoard=On Board
126+
XMC1300_Boot_Kit.menu.UART.onBoard.uart.selected=-DSERIAL_ONBOARD
127+
128+
XMC1300_Boot_Kit.menu.LIB.NONE=None
129+
XMC1300_Boot_Kit.menu.LIB.NONE.library.selected=
130+
XMC1300_Boot_Kit.menu.LIB.NN=ARM NN Framework
131+
XMC1300_Boot_Kit.menu.LIB.NN.library.selected=-DARM_LIB_CMSIS_NN
132+
XMC1300_Boot_Kit.menu.LIB.DSP=ARM DSP
133+
XMC1300_Boot_Kit.menu.LIB.DSP.library.selected=-DARM_LIB_CMSIS_DSP
134+
XMC1300_Boot_Kit.menu.LIB.DSPNN=ARM DSP / ARM NN Framework
135+
XMC1300_Boot_Kit.menu.LIB.DSPNN.library.selected=-DARM_LIB_CMSIS_DSP -DARM_LIB_CMSIS_NN
136+
93137
####################################################
94138
XMC1400_Arduino_Kit.name=XMC1400 Kit for Arduino
95139
XMC1400_Arduino_Kit.upload.tool=xmcprog

libraries/SPI/src/utility/xmc_spi_conf.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ XMC_SPI_t XMC_SPI_0 =
6868
}
6969
};
7070

71-
#elif defined(XMC1100_Boot_Kit) || defined(XMC1400_Boot_Kit)
71+
#elif defined(XMC1100_Boot_Kit) || defined(XMC1300_Boot_Kit) || defined(XMC1400_Boot_Kit)
7272
XMC_SPI_t XMC_SPI_0 =
7373
{
7474
.channel = XMC_SPI0_CH0,

libraries/SPI/src/utility/xmc_spi_conf.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ typedef struct XMC_SPI
5656
#define NUM_SPI 1
5757
extern XMC_SPI_t XMC_SPI_0;
5858

59-
#elif defined(XMC1100_Boot_Kit) || defined(XMC1400_Boot_Kit)
59+
#elif defined(XMC1100_Boot_Kit) || defined(XMC1300_Boot_Kit) || defined(XMC1400_Boot_Kit)
6060
#define NUM_SPI 1
6161
extern XMC_SPI_t XMC_SPI_0;
6262

libraries/Wire/src/utility/xmc_i2c_conf.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ XMC_I2C_t XMC_I2C_1 =
9696
.protocol_irq_service_request = 3
9797
};
9898

99-
#elif defined(XMC1100_Boot_Kit) || defined(XMC1400_Boot_Kit)
99+
#elif defined(XMC1100_Boot_Kit) || defined(XMC1300_Boot_Kit) || defined(XMC1400_Boot_Kit)
100100
XMC_I2C_t XMC_I2C_0 =
101101
{
102102
.channel = XMC_I2C0_CH0,

libraries/Wire/src/utility/xmc_i2c_conf.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ typedef struct XMC_I2C
6060
extern XMC_I2C_t XMC_I2C_0;
6161
extern XMC_I2C_t XMC_I2C_1;
6262

63-
#elif defined(XMC1100_Boot_Kit) || defined(XMC1400_Boot_Kit)
63+
#elif defined(XMC1100_Boot_Kit) || defined(XMC1300_Boot_Kit) || defined(XMC1400_Boot_Kit)
6464
#define NUM_I2C 1
6565
extern XMC_I2C_t XMC_I2C_0;
6666

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,5 @@
22
"name": "framework-arduinoxmc",
33
"description": "Integration of Infineon's XMC microcontrollers with the Arduino framework",
44
"url": "https://www.infineon.com/cms/en/product/microcontroller/32-bit-industrial-microcontroller-based-on-arm-cortex-m/",
5-
"version": "2.0.0"
5+
"version": "2.1.0"
66
}

package/package_infineon_index.template.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@
2828
{
2929
"name":"XMC1100 XMC2Go"
3030
},
31+
{
32+
"name":"XMC1300 Boot Kit"
33+
},
3134
{
3235
"name":"XMC1400 Kit for Arduino"
3336
},
Lines changed: 176 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,176 @@
1+
/*********************************************************************************************************************
2+
* @file XMC1000_RomFunctionTable.h
3+
* @brief ROM functions prototypes for the XMC1400-Series
4+
* @version V1.0
5+
* @date 08 April 2013
6+
*
7+
* @cond
8+
*********************************************************************************************************************
9+
* Copyright (c) 2013-2016, Infineon Technologies AG
10+
* All rights reserved.
11+
*
12+
* Redistribution and use in source and binary forms, with or without modification,are permitted provided that the
13+
* following conditions are met:
14+
*
15+
* Redistributions of source code must retain the above copyright notice, this list of conditions and the following
16+
* disclaimer.
17+
*
18+
* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following
19+
* disclaimer in the documentation and/or other materials provided with the distribution.
20+
*
21+
* Neither the name of the copyright holders nor the names of its contributors may be used to endorse or promote
22+
* products derived from this software without specific prior written permission.
23+
*
24+
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
25+
* INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
26+
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
27+
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
28+
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
29+
* WHETHER IN CONTRACT, STRICT LIABILITY,OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30+
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31+
*
32+
* To improve the quality of the software, users are encouraged to share modifications, enhancements or bug fixes with
33+
* Infineon Technologies AG [email protected]).
34+
*********************************************************************************************************************
35+
*
36+
**************************** Change history *********************************
37+
* V1.0, 08 Jan 2013, GD, First version with XMC1000 devices
38+
*****************************************************************************
39+
* @endcond
40+
*/
41+
42+
#ifndef ROM_FUNCTION_TABLE_H
43+
#define ROM_FUNCTION_TABLE_H
44+
45+
#ifdef __cplusplus
46+
extern "C" {
47+
#endif
48+
49+
/* ***************************************************************************
50+
******************************* Constants *******************************
51+
*************************************************************************** */
52+
/* Start address of the ROM function table */
53+
#define ROM_FUNCTION_TABLE_START (0x00000100U)
54+
55+
/* Pointer to Erase Flash Page routine */
56+
#define _NvmErase (ROM_FUNCTION_TABLE_START + 0x00U)
57+
58+
/* Pointer to Erase, Program & Verify Flash Page routine */
59+
#define _NvmProgVerify (ROM_FUNCTION_TABLE_START + 0x04U)
60+
61+
/* Pointer to Request BMI installation routine */
62+
#define _BmiInstallationReq (ROM_FUNCTION_TABLE_START + 0x08U)
63+
64+
65+
/* ***************************************************************************
66+
******************************** Enumerations ********************************
67+
*************************************************************************** */
68+
typedef enum TagNVMStatus
69+
{
70+
71+
/* The function succeeded */
72+
NVM_PASS = (int32_t)0x00010000U,
73+
74+
/* Generic error code */
75+
NVM_E_FAIL = (int32_t)0x80010001U,
76+
77+
/* Source data not in RAM */
78+
NVM_E_SRC_AREA_EXCCEED = (int32_t)0x80010003U,
79+
80+
/* Source data is not 4 byte aligned */
81+
NVM_E_SRC_ALIGNMENT = (int32_t)0x80010004U,
82+
83+
/* NVM module cannot be physically accessed */
84+
NVM_E_NVM_FAIL = (int32_t)0x80010005U,
85+
86+
/* Verification of written page not successful */
87+
NVM_E_VERIFY = (int32_t)0x80010006U,
88+
89+
/* Destination data is not (completely) located in NVM */
90+
NVM_E_DST_AREA_EXCEED = (int32_t)0x80010009U,
91+
92+
/* Destination data is not properly aligned */
93+
NVM_E_DST_ALIGNMENT = (int32_t)0x80010010U,
94+
95+
} NVM_STATUS;
96+
97+
98+
/* ***************************************************************************
99+
*********************************** Macros ***********************************
100+
*************************************************************************** */
101+
102+
/* ***************************************************************************
103+
Description: Erase granularity = 1 Page of 16 blocks of 16 Bytes
104+
= Equivalent to 256 Bytes using this routine.
105+
106+
Input parameters:
107+
– Logical address of the Flash Page to be erased which must be page aligned
108+
and in NVM address range
109+
110+
Return status:
111+
– OK (NVM_PASS)
112+
– Invalid address (NVM_E_DST_ALIGNMENT or NVM_E_DST_AREA_EXCEED)
113+
– Operation failed (Error during low level NVM programming driver):
114+
NVM_E_FAIL
115+
NVM_E_VERIFY
116+
NVM_E_NVM_FAIL
117+
118+
Prototype:
119+
NVM_STATUS XMC1000_NvmErasePage(uint32_t *pageAddr)
120+
*************************************************************************** */
121+
#define XMC1000_NvmErasePage (*((NVM_STATUS (**) (uint32_t * )) \
122+
_NvmErase))
123+
124+
/* ***************************************************************************
125+
Description: This procedure performs erase (skipped if not necessary), program
126+
and verify of selected Flash page.
127+
128+
Input parameter:
129+
– Logical address of the target Flash Page, must be page aligned and in NVM
130+
address range
131+
132+
– Address in SRAM where the data starts, must be 4-byte aligned
133+
134+
Return status:
135+
– OK (NVM_PASS)
136+
– Invalid addresses
137+
NVM_E_DST_ALIGNMENT
138+
NVM_E_SRC_ALIGNMENT
139+
NVM_E_DST_AREA_EXCEED
140+
NVM_E_SRC_AREA_EXCCEED
141+
– Operation failed (Error during low level NVM programming driver):
142+
NVM_E_FAIL
143+
NVM_E_VERIFY
144+
NVM_E_NVM_FAIL
145+
146+
Prototype:
147+
NVM_STATUS XMC1000_NvmProgVerify(const uint32_t *srcAddr, uint32_t *dstAddr)
148+
*************************************************************************** */
149+
#define XMC1000_NvmProgVerify (*((NVM_STATUS (**) (const uint32_t * ,\
150+
uint32_t * ))\
151+
_NvmProgVerify))
152+
153+
154+
/* ***************************************************************************
155+
Description: This procedure initiates installation of a new BMI value. In
156+
particular, it can be used as well as to restore the state upon delivery for a
157+
device already in User Productive mode.
158+
159+
Input parameter:
160+
– BMI value to be installed
161+
162+
Return status:
163+
– wrong input BMI value (0x01) - only upon error, if OK the procedure triggers
164+
a reset respectively does not return to calling routine !
165+
166+
Prototype:
167+
unsigned long XMC1000_BmiInstallationReq(unsigned short requestedBmiValue)
168+
**************************************************************************** */
169+
#define XMC1000_BmiInstallationReq (*((uint32_t (**) (uint16_t)) \
170+
_BmiInstallationReq))
171+
172+
#ifdef __cplusplus
173+
}
174+
#endif
175+
176+
#endif /* ROM_FUNCTION_TABLE_H */

0 commit comments

Comments
 (0)