Guillaume Revaillot
5a349d3ab6
stm32g0: add i2c.
...
Regular i2c peripheral.
Partially tested as i had no i2c slave on hand, but i can see i2c on my scope..
2019-06-13 12:04:58 +02:00
Guillaume Revaillot
ba3b50a4ad
stm32g0: add spi.
...
classic "common" spi + frf bit spi peripheral.
As for i2c, i could only check signals on scope, no spi slave to check, but looks ok.
2019-06-13 11:56:20 +02:00
Guillaume Revaillot
a51ecb4719
stm32g0: add usart.
2019-06-13 11:56:20 +02:00
Guillaume Revaillot
bb98d0755c
stm32g0: add iwdg.
...
regular v2 iwdg.
2019-06-13 11:07:53 +02:00
Eric Van Albert
3d422a930f
stm32l4: add common DAC support
...
Replace the DAC1_BASE style, only used on l4 with the standard DAC_BASE
used on all other targets.
Reviewed-by: Karl Palsson <karlp@tweak.net.au>
2019-06-12 23:25:22 +00:00
Karl Palsson
209dea96e7
doc: stm32g0: rcc: fix missing/typod param names
2019-06-12 23:20:59 +00:00
Karl Palsson
9f58ad4393
doc: fix trivial missing trailers or typos
2019-06-12 23:16:58 +00:00
Karl Palsson
55c899c93b
doc: stm32l0: rcc: add groups requested by existing docs
...
And cleanse the arguments to all match the docs.
2019-06-12 23:06:28 +00:00
Karl Palsson
5eefc214f6
doc: stm32: fix "osc" incorrect linkages
...
Was copied around a lot, was always wrong.
2019-06-12 23:06:27 +00:00
Karl Palsson
4533b1be68
doc: fix some trivial parameter name style problems
...
Just gets them out of the way so we can do bigger item changes.
2019-06-12 23:06:27 +00:00
Karl Palsson
9904f9803e
doc: stm32: unify "peripheral API" titles
...
doxygen really wants the @defgroup _and_ the @addtogroup to both have
the full name, matching identically, to avoid all warnings.
Standardize on the "CAPS_PERIPH peripheral API" style.
2019-06-12 23:06:22 +00:00
Guillaume Revaillot
f38c6f4f91
stm32l0: rcc: doc: fix rcc_clock_setup_pll brief.
...
rcc_clock_setup_pll allows to use HSE or HSI as PLL source, comment is misleading.
2019-06-12 23:06:22 +00:00
Karl Palsson
b287bbd322
stm32: hash: move to peripherals API docs
...
Drop redundant .c files and add groupings and labels. Eliminates
warnings from doxygen
2019-06-12 23:06:22 +00:00
Karl Palsson
a143e5644e
doc: stm32f1:rtc: fix trivial param typos
2019-06-12 23:06:22 +00:00
Karl Palsson
9a53dc3a89
doc: stm32f0: adc: fix missing param (trivial)
2019-06-12 23:06:22 +00:00
Karl Palsson
cfdb9b7856
doc: stm32f0: rcc: add groups and tags for bus prescalers
2019-06-12 23:06:22 +00:00
Karl Palsson
e8f03b4615
doc: usbd: Add missing / incorrect parameters.
...
Just basic documentation to clear up errors for starters.
2019-06-12 23:06:22 +00:00
Karl Palsson
020d883338
doc: stm32: flash: fix missing doxygen trailer
2019-06-12 23:06:22 +00:00
Karl Palsson
c9d45e0e2c
doc: stm32: move RCC to peripheral api style
...
For f7, it was completely missing doc markers
2019-06-12 21:56:09 +00:00
Karl Palsson
7be50a5e75
make: use $(PREFIX)gcc instead of $(PREFIX)-gcc
...
The leading - makes it rather inconsistent with the majority of other
projects around the world. Use the form everyone else uses.
To solve this, properly pass prefix to inner makes as was always
intended.
Fixes: https://github.com/libopencm3/libopencm3/issues/1058
2019-06-07 21:25:46 +00:00
Guillaume Revaillot
a652856533
stm32l0: rcc: add rcc_set_peripheral_clk_sel(periph, sel)
2019-06-03 22:29:45 +00:00
Guillaume Revaillot
8668f9198b
stm32l0: rcc: add peripherals clock source selection helpers.
2019-06-03 22:29:45 +00:00
Guillaume Revaillot
6953138a28
stm32l0: add rcc_set_msi_range.
2019-06-03 22:29:45 +00:00
Bruno Randolf
53ce5aa3dd
stm32:l4:flash: Fix option bytes programming
...
FLASH_CR_OPTSTRT needs to be written to FLASH_CR, and there is no reason
to mask the last two data bits.
Signed-off-by: Bruno Randolf <br1@einfach.org>
Reviewed-by: Karl Palsson <karlp@tweak.net.au>
(original code appeared to be badly copied from the flash_common_f24 codebase)
2019-06-02 22:18:14 +00:00
Bruno Randolf
833ddd9b0a
stm32: rtc: clear wakeup clock selection
...
Clear wakeup clock selection before setting the desired bits, so no
old bits can stay set
Reviewed-by: Karl Palsson <karlp@tweak.net.au>
2019-06-02 22:18:05 +00:00
Bruno Randolf
b8424263e8
stm32:l4: rcc: Add RTC clock functions
2019-06-02 22:18:05 +00:00
Bruno Randolf
2c1823f7bb
stm32:l4: pwr: Add en/disable_backup_domain_write_protect()
2019-06-02 22:18:05 +00:00
Bruno Randolf
fe722d4643
stm32:l4: rcc: Add helper functions
...
Add functions for PLL output and 48MHz clock source selection
2019-06-02 22:18:05 +00:00
Bruno Randolf
a1ffdc59f0
stm32:l4: flash: Program in double words
...
According to RM0351 and RM0394 flash needs to be programmed by double words.
Also fix flash_program() which was wrong anyways.
Reviewed-by: Karl Palsson <karlp@tweak.net.au>
2019-06-02 22:17:55 +00:00
Karl Palsson
f990030440
stm32f4: rcc: move deprecated attribute to header
...
This makes it actually generate deprecated warnings. The deprecated
doxygen stays with the .c file as before.
2019-06-02 12:50:34 +00:00
Karl Palsson
a9dde2832e
stm32f4: rcc: drop 48 & 120 MHz configs
...
48Mhz has no purpose other than to be a naiive method of haivng working
USB. 120MHz never had any purpose, other than to match the f2 code it
was copied from. Drop them both. Remaining configs are all max speeds
for various F4 parts. Lower speeds are all custom
2019-06-02 10:50:10 +00:00
Miguel Sánchez de León Peque
1d68c299e8
stm32f4: add HSI clock configurations
2019-06-02 10:39:18 +00:00
Miguel Sánchez de León Peque
ca6dcfbea1
stm32f4: rcc: support hsi pll source
2019-06-02 10:38:43 +00:00
Karl Palsson
f2a9980638
stm32: doc: rtc: move to peripheral apis
...
Drop some dummy.c files, add some missing groupings and make sure all
specifics are included in the generated output.
2019-05-22 00:16:40 +00:00
Karl Palsson
0aef9c2ec6
stm32: doc: pwr: move to peripheral_api
...
Some families had partially moved to peripheral api, and others were
only documenting common code, but not specific code. Delete dummy .c
files, and check that all specific apis are also being documented, not
just common apis.
2019-05-22 00:10:39 +00:00
Karl Palsson
da76279bc6
stm32: flash: move to peripheral_apis
...
Change the groupings and headings to make them all consistent.
2019-05-21 23:41:21 +00:00
Karl Palsson
1001a9323b
stm32: doc: dma: move to peripheral_apis
...
drops dummy .c files, and adds proper groupings to the shared files.
2019-05-21 23:27:21 +00:00
Karl Palsson
9382042180
stm32: doc: move timer to peripheral_apis
...
Drop all the dummy timer.c files, and _actually_ compile the L1 specific
file that was dropped by accident in 5b8953124e in 2013!
2019-05-21 23:17:04 +00:00
Karl Palsson
508f8d9487
stm32: doc: gpio: move gpio to peripheral_apis
...
Drops dummy gpio.c files that weren't even being compiled in some cases.
2019-05-21 23:16:59 +00:00
Karl Palsson
d77f539013
stm32: doc: rng: migrate to peripheral apis
...
Gets them all documented properly, and cleans up the language that this
was just for F4.
2019-05-21 23:16:59 +00:00
Karl Palsson
1af3acdba4
stm32: doc: exti: fix missing/wrong groups and move to peripheral_api
...
Almost all families were missing all docs for the exti apis.
2019-05-21 23:16:59 +00:00
Karl Palsson
fe5e82a3cc
stm32: doc: dac: move to peripheral_apis.
...
Drops all the stub dummy header files, many of which weren't even being
built, and moves them to the clean peripherals_api doc section.
2019-05-21 23:16:51 +00:00
Karl Palsson
d559b5a4db
stm32g0: doc: move flash/pwr/rcc to "peripheral_apis"
...
Where we've been collecting things that have common/specific parts as
the new style of docs.
2019-05-21 21:47:43 +00:00
Karl Palsson
4aa9e484f6
stm32g0: flash: drop redundant docs
...
Functions that are already documented in the top level common api.h file
won't add any more documentation from later .c files. Keep docs for
part specifics, in the .h files where they're accessible to IDEs and
also the documentation generation, and drop all (including the redundant
ones) from the .c file.
2019-05-21 21:46:02 +00:00
Karl Palsson
709d98e0a8
doc: stm32g0: drop redundant @ingroup and close groups
...
the group defaults to the implicit container based on location, so drop
all the explicit @ingroups, less to maintain. Properly use /**@}*/ to
close all groups too, even though it mostly seems to have worked anyway.
Properly close all groups opened for files.
2019-05-21 21:44:05 +00:00
Guillaume Revaillot
55121126c3
stm32g0: add exti.
...
Regular exti, with enhanced EXTI_[FR]PR regs instead of EXTIR_PR.
2019-05-21 00:05:22 +00:00
Guillaume Revaillot
afd2db3097
stm32g0: add rcc.
2019-05-21 00:05:22 +00:00
Guillaume Revaillot
cbe5425090
stm32g0: add flash.
...
here, it's a bit of a mess.. G0 flash controller does not really
match exsting feature split. IE it has instruction cache only ..
so, no flash_idcache.c as it. flash_common_f could be used, but
flash_unlock would not take care of option byte ?
prefetch, icache and lock is ok. I had no look at flash programming
or erase yet..
2019-05-21 00:05:22 +00:00
Guillaume Revaillot
f13a9eee5b
stm32g0: add power.
...
neither v1 nor v2...
2019-05-20 23:59:42 +00:00
Guillaume Revaillot
c49937a09c
stm32g0: add gpio.
...
regular peripheral.
2019-05-20 23:43:46 +00:00