Registered User mNo edit summary |
Registered User mNo edit summary Tag: 2017 source edit |
||
(16 intermediate revisions by 4 users not shown) | |||
Line 1: | Line 1: | ||
<noinclude>{{ApplicableFor | <noinclude>{{ApplicableFor | ||
|MPUs list=STM32MP15x | |MPUs list=STM32MP15x | ||
|MPUs checklist=STM32MP13x, STM32MP15x | |MPUs checklist=STM32MP13x, STM32MP15x, STM32MP25x | ||
}}</noinclude> | }}</noinclude> | ||
==Article purpose== | ==Article purpose== | ||
The purpose of this article is to | The purpose of this article is to: | ||
* briefly introduce the VREFBUF | * briefly introduce the VREFBUF peripheral and its main features, | ||
* indicate the | * indicate the peripheral instances assignment at boot time and their assignment at runtime (including whether instances can be allocated to secure contexts), | ||
* list the software frameworks and drivers managing the peripheral, | |||
* explain | * explain how to configure the peripheral. | ||
==Peripheral overview== | ==Peripheral overview== | ||
The '''VREFBUF''' peripheral is an internal voltage regulator. | The '''VREFBUF ''' peripheral is an internal voltage regulator. | ||
The VREFBUF is supplied via the VDDA pin. When enabled, it can provide a reference voltage in the range of: 1,5V, 1,8V, 2,048V or 2,5V. | The VREFBUF is supplied via the VDDA pin. When enabled, it can provide a reference voltage in the range of: 1,5V, 1,8V, 2,048V or 2,5V. | ||
The VREFBUF can be used to provide an analog voltage reference for: | The VREFBUF can be used to provide an analog voltage reference for: | ||
* | * [[ADC internal peripheral]] | ||
* | * [[DAC internal peripheral]] | ||
* External components through the dedicated VREF+ pin. | * External components through the dedicated VREF+ pin. | ||
The VREFBUF can be left unused. In this case, an external voltage regulator can provide reference voltage to VREF+ pin. | The VREFBUF can be left unused. In this case, an external voltage regulator can provide reference voltage to VREF+ pin. | ||
Refer to the [[STM32MP15 resources#Reference manuals|STM32MP15 reference manuals]] for the complete list of features, and to the software | Refer to the [[STM32MP15 resources#Reference manuals|STM32MP15 reference manuals]] for the complete list of features, and to the software frameworks and drivers, introduced below, to see which features are implemented. | ||
==Peripheral usage== | |||
This chapter is applicable in the scope of the '''OpenSTLinux BSP''' running on the Arm<sup>®</sup> Cortex<sup>®</sup>-A processor(s), and the '''STM32CubeMPU Package''' running on the Arm<sup>®</sup> Cortex<sup>®</sup>-M processor. | |||
===Boot time assignment=== | |||
====On {{MicroprocessorDevice | device=15}}==== | |||
The VREFBUF is not used at boot time. | |||
===Runtime assignment=== | |||
====On {{MicroprocessorDevice | device=15}}==== | |||
{{#lst:STM32MP1_internal_peripherals_assignment_table_template|stm32mp15_runtime}} | |||
<section begin=stm32mp15_runtime /> | |||
| rowspan="1" | Analog | |||
| rowspan="1" | [[STM32MP15 VREFBUF internal peripheral|VREFBUF]] | |||
| VREFBUF | |||
| | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| <span title="assignable peripheral" style="font-size:21px">☐</span> | |||
| Assignment (single choice) | |||
|- | |||
<section end=stm32mp15_runtime /> | |||
|} | |||
== | ==Software frameworks and drivers== | ||
Below are listed the software frameworks and drivers managing the VREFBUF peripheral for the embedded software components listed in the above tables. | |||
* '''Linux<sup>®</sup>''': [[Regulator overview|regulator framework]] | |||
{{Info|The VREFBUF is a system resource<ref name="resource manager">[[Resource_manager_for_coprocessing#The_system_resources|Resource manager for coprocessing]], focus on system resources</ref> which needs to be also controlled by the resource manager<ref name="resource manager"/> in case its consumers (e.g. [[ADC internal peripheral|ADC]], [[ADC internal peripheral|DAC]] or an external device connected to VREF+ pin) are spread across: | |||
{{Info|The VREFBUF is a system resource<ref name="resource manager">[[Resource_manager_for_coprocessing#The_system_resources|Resource manager for coprocessing]], focus on system resources</ref> which needs to be also controlled by the resource manager<ref name="resource manager"/> in case its consumers (e.g. ADC | |||
* the Arm<sup>®</sup> Cortex<sup>®</sup>-A7 non-secure context | * the Arm<sup>®</sup> Cortex<sup>®</sup>-A7 non-secure context | ||
* the Arm<sup>®</sup> Cortex<sup>®</sup>-M4 context | * the Arm<sup>®</sup> Cortex<sup>®</sup>-M4 context | ||
For this reason, the direct control of VREFBUF from the Arm<sup>®</sup> Cortex<sup>®</sup>-M4 is not recommended in | For this reason, the direct control of VREFBUF from the Arm<sup>®</sup> Cortex<sup>®</sup>-M4 is not recommended in [[STM32CubeMP15 Package architecture|STM32Cube]] by default.<br/> | ||
It's recommended to implement it in STM32Cube '''only if''' all consumers and the VDDA supply pin are controlled in the Arm<sup>®</sup> Cortex<sup>®</sup>-M4 context. | It's recommended to implement it in STM32Cube '''only if''' all consumers and the VDDA supply pin are controlled in the Arm<sup>®</sup> Cortex<sup>®</sup>-M4 context. | ||
}} | }} | ||
==How to assign and configure the peripheral== | |||
The peripheral assignment can be done via the [[STM32CubeMX]] graphical tool (and manually completed if needed).<br /> | |||
This tool also helps to configure the peripheral: | |||
* partial device trees (pin control and clock tree) generation for the OpenSTLinux software components, | |||
* HAL initialization code generation for the STM32CubeMPU Package. | |||
The configuration is applied by the firmware running in the context in which the peripheral is assigned. | |||
The configuration is applied by the firmware running in the context | |||
* For the Linux kernel configuration, please refer to [[Regulator_overview# | * For the Linux kernel configuration, please refer to [[Regulator_overview#Microprocessor_device_internal_regulator|device internal regulator]]. An example can be found also in [[ADC_device_tree_configuration#DT_configuration_examples|ADC DT configuration examples]] | ||
* In case the control of VREFBUF consumers are spread across the various cores, see also [[Resource manager for coprocessing]] | * In case the control of VREFBUF consumers are spread across the various cores, see also [[Resource manager for coprocessing]] | ||
==References== | ==References== | ||
<references/> | <references/> | ||
<noinclude> | <noinclude> | ||
[[Category:Analog peripherals|VREFBUF internal peripheral STM32MP15]] | [[Category:Analog peripherals|VREFBUF internal peripheral STM32MP15]] | ||
{{ArticleBasedOnModel| Internal peripheral article model}} | |||
{{PublicationRequestId | 8312 | 2018-08-07 | AlainF}} | {{PublicationRequestId | 8312 | 2018-08-07 | AlainF}} | ||
</noinclude> | </noinclude> |
Latest revision as of 16:18, 20 August 2024
1. Article purpose
The purpose of this article is to:
- briefly introduce the VREFBUF peripheral and its main features,
- indicate the peripheral instances assignment at boot time and their assignment at runtime (including whether instances can be allocated to secure contexts),
- list the software frameworks and drivers managing the peripheral,
- explain how to configure the peripheral.
2. Peripheral overview
The VREFBUF peripheral is an internal voltage regulator.
The VREFBUF is supplied via the VDDA pin. When enabled, it can provide a reference voltage in the range of: 1,5V, 1,8V, 2,048V or 2,5V.
The VREFBUF can be used to provide an analog voltage reference for:
- ADC internal peripheral
- DAC internal peripheral
- External components through the dedicated VREF+ pin.
The VREFBUF can be left unused. In this case, an external voltage regulator can provide reference voltage to VREF+ pin.
Refer to the STM32MP15 reference manuals for the complete list of features, and to the software frameworks and drivers, introduced below, to see which features are implemented.
3. Peripheral usage
This chapter is applicable in the scope of the OpenSTLinux BSP running on the Arm® Cortex®-A processor(s), and the STM32CubeMPU Package running on the Arm® Cortex®-M processor.
3.1. Boot time assignment
3.1.1. On STM32MP15x lines 
The VREFBUF is not used at boot time.
3.2. Runtime assignment
3.2.1. On STM32MP15x lines 
Click on to expand or collapse the legend...
Domain | Peripheral | Runtime allocation | Comment ![]() | |||
---|---|---|---|---|---|---|
Instance | Cortex-A7 secure (OP-TEE) |
Cortex-A7 non-secure (Linux) |
Cortex-M4 (STM32Cube) | |||
Analog | VREFBUF | VREFBUF | ☐ | ☐ | Assignment (single choice) |
4. Software frameworks and drivers
Below are listed the software frameworks and drivers managing the VREFBUF peripheral for the embedded software components listed in the above tables.
- Linux®: regulator framework
5. How to assign and configure the peripheral
The peripheral assignment can be done via the STM32CubeMX graphical tool (and manually completed if needed).
This tool also helps to configure the peripheral:
- partial device trees (pin control and clock tree) generation for the OpenSTLinux software components,
- HAL initialization code generation for the STM32CubeMPU Package.
The configuration is applied by the firmware running in the context in which the peripheral is assigned.
- For the Linux kernel configuration, please refer to device internal regulator. An example can be found also in ADC DT configuration examples
- In case the control of VREFBUF consumers are spread across the various cores, see also Resource manager for coprocessing
6. References
- ↑ Jump up to: 1.0 1.1 Resource manager for coprocessing, focus on system resources