1 2 3 4 5 6 7 8 9 10 11
12
13 14 15
16 package ti.platforms.tms320x28;
17
18 /*!
19 * ======== Platform ========
20 * A generic platform that supports any TMS320x28 device
21 *
22 * The device to be used by this platform is passed as the platform instance
23 * name. On the `xdc.tools.configuro` command line, it is done in the
24 * following way:
25 * @p(code)
26 * xs xdc.tools.configuro ... -p "ti.platforms.tms320x28:TMS320C2812"
27 * @p
28 *
29 * In package.bld, the platform instance is selected as in:
30 * @p(code)
31 * Pkg.addExecutable("test", target, "ti.platforms.tms320x28:TMS320C2812");
32 * @p
33 */
34 metaonly module Platform inherits xdc.platform.IPlatform
35 {
36 config xdc.platform.IPlatform.Board BOARD = {
37 id: "0",
38 boardName: "tms320x28",
39 boardFamily: null,
40 boardRevision: null
41 };
42
43 /*!
44 * ======== nameFormat ========
45 * Encoding of instance creation parameters in the instance's name
46 *
47 * For this platform, the parameters `deviceName`, `includeLinkCmdFile`
48 * and `clockRate` can be encoded in the instance name supplied on
49 * `xdc.tools.configuro` command line, for example:
50 * @p(code)
51 * xs xdc.tools.configuro ... -p ti.platforms.tms320x28:TMS320F28035:1:60
52 * @p
53 * Optional parameters can be omitted:
54 * @p(code)
55 * xs xdc.tools.configuro ... -p ti.platforms.tms320x28:TMS320F28035
56 * @p
57 */
58 readonly config string nameFormat
59 = "$(deviceName):$(includeLinkCmdFile):$(clockRate)";
60
61 /*!
62 * ======== genAliases ========
63 * Generate symbol mapping for TI Tools 6.0 or newer
64 */
65 config Bool genAliases = true;
66
67 instance:
68
69 config xdc.platform.IExeContext.Cpu CPU = {
70 id: "0",
71 clockRate: 0,
72 catalogName: "ti.catalog.c2800",
73 deviceName: "TMS320F28069",
74 revision: null,
75 };
76
77 /*!
78 * ======== deviceName ========
79 * The name of an `ICpuDataSheet` module for the device
80 *
81 * This parameter is required, but it does not have to be set explicitly;
82 * it can be encoded in the instance's name.
83 */
84 config string deviceName;
85
86 /*!
87 * ======== clockRate ========
88 * The clock rate for this device.
89 */
90 config Double clockRate = 0;
91
92 override config string codeMemory = null;
93
94 override config string dataMemory = null;
95
96 override config string stackMemory = null;
97
98 /*!
99 * ======== includeLinkCmdFile ========
100 * The flag that specifies if the platform should include a linker command
101 * file.
102 *
103 * By default, a user is responsible for adding a linker command file to
104 * the project, or to the linker command line. However, if this flag is
105 * set, this platform will include a default linker command file for the
106 * selected device.
107 */
108 config Bool includeLinkCmdFile = false;
109 };
110 111 112
113