This repository has been archived by the owner on Jan 7, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
STM32: Added preliminary xml device file for STM32F407/405
Still needs a lot more information, but right now the goal is to be able to compile the STM32F4 Discovery blink example.
- Loading branch information
Showing
1 changed file
with
61 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
<?xml version='1.0' encoding='UTF-8' ?> | ||
<!DOCTYPE rca SYSTEM "../devicefile.dtd"> | ||
<rca version="1.0"> | ||
<device platform="stm32" family="f4" name="407|405"> <!-- FIXME: "name" does not sound quite right --> | ||
<!-- _flash_, _pin-count-, _define_, -core_ and _peripheral nodes | ||
accept pin-id/size-id properties if they only apply to a specific | ||
size/pin id | ||
Furthermore for _define_, _peripheral_ and _gpio_ | ||
nodes you can use the pin-copunt property if they are only | ||
available on a device with a specific pin count. Add a _+_ | ||
to mean "and more" / a _-_ to mean "and less" | ||
--> | ||
<!-- Flash and RAM sizes --> | ||
<flash size-id="e">524288</flash> | ||
<flash size-id="g">1048576</flash> | ||
<ram>114688</ram> <!--Missing id => applies to all devices--> | ||
<!-- Number of pins --> | ||
<pin-count pin-id="r">64</pin-count> | ||
<pin-count pin-id="v">100</pin-count> | ||
<pin-count pin-id="z">144</pin-count> | ||
<pin-count pin-id="i">176</pin-count> | ||
<!-- Cpp Defines --> | ||
<define>__STM32F407__</define> | ||
<define>__ARM_STM32__</define> | ||
<define>STM32F4XX</define> | ||
<define size-id="e">STM32F407xE</define> <!-- Defines can depend on pin/size ids--> | ||
<!-- TODO: add linkerscript --> | ||
<!-- Core Driver --> | ||
<core>cortex-m4</core> | ||
<!-- Peripheral Drivers --> | ||
<peripheral type="clock" name="stm32" /> | ||
<peripheral type="gpio" name="stm32_af"> | ||
<!-- separate field for port and id are needed because | ||
e.g. on the lpc platform both are a number --> | ||
<gpio port="A" id="0" analog="Adc0,Adc1,Adc2"> | ||
<!-- This makes the GPIO connect to all peripheral drivers | ||
of a certain kind. For example Uart as well as UartHAL | ||
driver for the stm32 platform are both of the type uart | ||
and thus use the same alternate function --> | ||
<af peripheral-type="timer" peripheral-id="2">1</af> | ||
<af peripheral-type="timer" peripheral-id="5">2</af> | ||
<af peripheral-type="timer" peripheral-id="8">3</af> | ||
<!-- According to the development summit 2012 the driver | ||
directory is call uard thus the type will always be | ||
called uart and never usart! --> | ||
<af peripheral-type="uart" peripheral-id="2">7</af> | ||
<af peripheral-type="uart" peripheral-id="4">8</af> | ||
</gpio> | ||
<!-- For this proof of concept af, as well as analog are not | ||
evaluated | ||
TODO: add alternate functions as well as analog input connections --> | ||
<gpio port="A" id="9"></gpio> | ||
<!-- PD5 is only available on devices with 90 pins or more --> | ||
<gpio port="D" id="5" pin-count="90+"></gpio> | ||
<gpio port="D" id="12" pin-count="90+"></gpio> | ||
<gpio port="D" id="13" pin-count="100+"></gpio> | ||
<gpio port="D" id="14" pin-count="90+"></gpio> | ||
<gpio port="D" id="15" pin-count="90+"></gpio> | ||
</peripheral> | ||
</device> | ||
</rca> |