You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

l6208_target_config.h 3.8KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. /******************************************************//**
  2. * @file l6208_target_config.h
  3. * @author IPC Rennes
  4. * @version V1.5.0
  5. * @date June 1st, 2018
  6. * @brief Predefines values for the L6208 parameters
  7. * @note (C) COPYRIGHT 2016 STMicroelectronics
  8. ******************************************************************************
  9. * @attention
  10. *
  11. * <h2><center>&copy; COPYRIGHT(c) 2016 STMicroelectronics</center></h2>
  12. *
  13. * Redistribution and use in source and binary forms, with or without modification,
  14. * are permitted provided that the following conditions are met:
  15. * 1. Redistributions of source code must retain the above copyright notice,
  16. * this list of conditions and the following disclaimer.
  17. * 2. Redistributions in binary form must reproduce the above copyright notice,
  18. * this list of conditions and the following disclaimer in the documentation
  19. * and/or other materials provided with the distribution.
  20. * 3. Neither the name of STMicroelectronics nor the names of its contributors
  21. * may be used to endorse or promote products derived from this software
  22. * without specific prior written permission.
  23. *
  24. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
  25. * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  26. * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  27. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
  28. * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  29. * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
  30. * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
  31. * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  32. * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  33. * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  34. *
  35. ******************************************************************************
  36. */
  37. /* Define to prevent recursive inclusion -------------------------------------*/
  38. #ifndef __L6208_TARGET_CONFIG_H
  39. #define __L6208_TARGET_CONFIG_H
  40. #ifdef __cplusplus
  41. extern "C" {
  42. #endif
  43. /** @addtogroup BSP
  44. * @{
  45. */
  46. /** @addtogroup L6208
  47. * @{
  48. */
  49. /** @addtogroup L6208_Exported_Constants
  50. * @{
  51. */
  52. /** @defgroup Predefined_L6208_Parameters_Values Predefined L6208 Parameters Values
  53. * @{
  54. */
  55. /// Acceleration rate in step/s^2 or (1/16)th step/s^2 for microstep modes
  56. #define L6208_CONF_PARAM_ACC_RATE (1000)
  57. /// Acceleration current torque in % (from 0 to 100)
  58. #define L6208_CONF_PARAM_ACC_CURRENT (10)
  59. /// Deceleration rate in step/s^2 or (1/16)th step/s^2 for microstep modes
  60. #define L6208_CONF_PARAM_DEC_RATE (1000)
  61. /// Deceleration current torque in % (from 0 to 100)
  62. #define L6208_CONF_PARAM_DEC_CURRENT (10)
  63. /// Running speed in step/s or (1/16)th step/s for microstep modes
  64. #define L6208_CONF_PARAM_RUNNING_SPEED (1000)
  65. /// Running current torque in % (from 0 to 100)
  66. #define L6208_CONF_PARAM_RUNNING_CURRENT (10)
  67. /// Holding current torque in % (from 0 to 100)
  68. #define L6208_CONF_PARAM_HOLDING_CURRENT (10)
  69. /// Step mode via enum motorStepMode_t
  70. #define L6208_CONF_PARAM_STEP_MODE (STEP_MODE_1_16)
  71. /// Decay mode via enum motorDecayMode_t
  72. #define L6208_CONF_PARAM_DECAY_MODE (FAST_DECAY)
  73. /// Dwelling time in ms
  74. #define L6208_CONF_PARAM_DWELL_TIME (0)
  75. /// Automatic HIZ STOP
  76. #define L6208_CONF_PARAM_AUTO_HIZ_STOP (FALSE)
  77. /// VREFA and VREFB PWM frequency (Hz)
  78. #define L6208_CONF_VREF_PWM_FREQUENCY (100000)
  79. /**
  80. * @}
  81. */
  82. /**
  83. * @}
  84. */
  85. /**
  86. * @}
  87. */
  88. /**
  89. * @}
  90. */
  91. #ifdef __cplusplus
  92. }
  93. #endif
  94. #endif /* __L6208_TARGET_CONFIG_H */
  95. /******************* (C) COPYRIGHT 2016 STMicroelectronics *****END OF FILE****/