aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/templates/pwm_lld.c
diff options
context:
space:
mode:
authorgdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2013-08-09 08:24:22 +0000
committergdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2013-08-09 08:24:22 +0000
commit8ca210a4af9fd039e290cfcc309adde543999c1f (patch)
tree1aa594d5e65d5ebabdd358acbe8d3a9ac29f2070 /os/hal/templates/pwm_lld.c
parentcb453a3a12464dd71856b1354d083b5b02260870 (diff)
downloadChibiOS-8ca210a4af9fd039e290cfcc309adde543999c1f.tar.gz
ChibiOS-8ca210a4af9fd039e290cfcc309adde543999c1f.tar.bz2
ChibiOS-8ca210a4af9fd039e290cfcc309adde543999c1f.zip
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/kernel_3_dev@6108 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/templates/pwm_lld.c')
-rw-r--r--os/hal/templates/pwm_lld.c186
1 files changed, 0 insertions, 186 deletions
diff --git a/os/hal/templates/pwm_lld.c b/os/hal/templates/pwm_lld.c
deleted file mode 100644
index a38290334..000000000
--- a/os/hal/templates/pwm_lld.c
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
- ChibiOS/RT - Copyright (C) 2006-2013 Giovanni Di Sirio
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
-*/
-
-/**
- * @file templates/pwm_lld.c
- * @brief PWM Driver subsystem low level driver source template.
- *
- * @addtogroup PWM
- * @{
- */
-
-#include "ch.h"
-#include "hal.h"
-
-#if HAL_USE_PWM || defined(__DOXYGEN__)
-
-/*===========================================================================*/
-/* Driver local definitions. */
-/*===========================================================================*/
-
-/*===========================================================================*/
-/* Driver exported variables. */
-/*===========================================================================*/
-
-/**
- * @brief PWM1 driver identifier.
- */
-#if PLATFORM_PWM_USE_PWM1 || defined(__DOXYGEN__)
-PWMDriver PWMD1;
-#endif
-
-/*===========================================================================*/
-/* Driver local variables and types. */
-/*===========================================================================*/
-
-/*===========================================================================*/
-/* Driver local functions. */
-/*===========================================================================*/
-
-/*===========================================================================*/
-/* Driver interrupt handlers. */
-/*===========================================================================*/
-
-/*===========================================================================*/
-/* Driver exported functions. */
-/*===========================================================================*/
-
-/**
- * @brief Low level PWM driver initialization.
- *
- * @notapi
- */
-void pwm_lld_init(void) {
-
-#if PLATFORM_PWM_USE_PWM1
- /* Driver initialization.*/
- pwmObjectInit(&PWMD1);
-#endif /* PLATFORM_PWM_USE_PWM1 */
-}
-
-/**
- * @brief Configures and activates the PWM peripheral.
- *
- * @param[in] pwmp pointer to the @p PWMDriver object
- *
- * @notapi
- */
-void pwm_lld_start(PWMDriver *pwmp) {
-
- if (pwmp->state == PWM_STOP) {
- /* Enables the peripheral.*/
-#if PLATFORM_PWM_USE_PWM1
- if (&PWMD1 == pwmp) {
-
- }
-#endif /* PLATFORM_PWM_USE_PWM1 */
- }
- /* Configures the peripheral.*/
-
-}
-
-/**
- * @brief Deactivates the PWM peripheral.
- *
- * @param[in] pwmp pointer to the @p PWMDriver object
- *
- * @notapi
- */
-void pwm_lld_stop(PWMDriver *pwmp) {
-
- if (pwmp->state == PWM_READY) {
- /* Resets the peripheral.*/
-
- /* Disables the peripheral.*/
-#if PLATFORM_PWM_USE_PWM1
- if (&PWMD1 == pwmp) {
-
- }
-#endif /* PLATFORM_PWM_USE_PWM1 */
- }
-}
-
-/**
- * @brief Changes the period the PWM peripheral.
- * @details This function changes the period of a PWM unit that has already
- * been activated using @p pwmStart().
- * @pre The PWM unit must have been activated using @p pwmStart().
- * @post The PWM unit period is changed to the new value.
- * @note The function has effect at the next cycle start.
- * @note If a period is specified that is shorter than the pulse width
- * programmed in one of the channels then the behavior is not
- * guaranteed.
- *
- * @param[in] pwmp pointer to a @p PWMDriver object
- * @param[in] period new cycle time in ticks
- *
- * @notapi
- */
-void pwm_lld_change_period(PWMDriver *pwmp, pwmcnt_t period) {
-
- (void)pwmp;
- (void)period;
-
-}
-
-/**
- * @brief Enables a PWM channel.
- * @pre The PWM unit must have been activated using @p pwmStart().
- * @post The channel is active using the specified configuration.
- * @note Depending on the hardware implementation this function has
- * effect starting on the next cycle (recommended implementation)
- * or immediately (fallback implementation).
- *
- * @param[in] pwmp pointer to a @p PWMDriver object
- * @param[in] channel PWM channel identifier (0...PWM_CHANNELS-1)
- * @param[in] width PWM pulse width as clock pulses number
- *
- * @notapi
- */
-void pwm_lld_enable_channel(PWMDriver *pwmp,
- pwmchannel_t channel,
- pwmcnt_t width) {
-
- (void)pwmp;
- (void)channel;
- (void)width;
-
-}
-
-/**
- * @brief Disables a PWM channel.
- * @pre The PWM unit must have been activated using @p pwmStart().
- * @post The channel is disabled and its output line returned to the
- * idle state.
- * @note Depending on the hardware implementation this function has
- * effect starting on the next cycle (recommended implementation)
- * or immediately (fallback implementation).
- *
- * @param[in] pwmp pointer to a @p PWMDriver object
- * @param[in] channel PWM channel identifier (0...PWM_CHANNELS-1)
- *
- * @notapi
- */
-void pwm_lld_disable_channel(PWMDriver *pwmp, pwmchannel_t channel) {
-
- (void)pwmp;
- (void)channel;
-
-}
-
-#endif /* HAL_USE_PWM */
-
-/** @} */