Advertisement
Guest User

Untitled

a guest
Nov 14th, 2018
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 15.58 KB | None | 0 0
  1.  
  2. /**
  3. ******************************************************************************
  4. * @file : main.c
  5. * @brief : Main program body
  6. ******************************************************************************
  7. ** This notice applies to any and all portions of this file
  8. * that are not between comment pairs USER CODE BEGIN and
  9. * USER CODE END. Other portions of this file, whether
  10. * inserted by the user or by software development tools
  11. * are owned by their respective copyright owners.
  12. *
  13. * COPYRIGHT(c) 2018 STMicroelectronics
  14. *
  15. * Redistribution and use in source and binary forms, with or without modification,
  16. * are permitted provided that the following conditions are met:
  17. * 1. Redistributions of source code must retain the above copyright notice,
  18. * this list of conditions and the following disclaimer.
  19. * 2. Redistributions in binary form must reproduce the above copyright notice,
  20. * this list of conditions and the following disclaimer in the documentation
  21. * and/or other materials provided with the distribution.
  22. * 3. Neither the name of STMicroelectronics nor the names of its contributors
  23. * may be used to endorse or promote products derived from this software
  24. * without specific prior written permission.
  25. *
  26. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
  27. * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  28. * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  29. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
  30. * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
  31. * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
  32. * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
  33. * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  34. * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  35. * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  36. *
  37. ******************************************************************************
  38. */
  39. /* Includes ------------------------------------------------------------------*/
  40. #include "main.h"
  41. #include "stm32f3xx_hal.h"
  42.  
  43. /* USER CODE BEGIN Includes */
  44.  
  45. /* USER CODE END Includes */
  46.  
  47. /* Private variables ---------------------------------------------------------*/
  48. I2C_HandleTypeDef hi2c1;
  49.  
  50. SPI_HandleTypeDef hspi1;
  51.  
  52. TIM_HandleTypeDef htim1;
  53. TIM_HandleTypeDef htim2;
  54.  
  55. PCD_HandleTypeDef hpcd_USB_FS;
  56.  
  57. /* USER CODE BEGIN PV */
  58. /* Private variables ---------------------------------------------------------*/
  59.  
  60. /* USER CODE END PV */
  61.  
  62. /* Private function prototypes -----------------------------------------------*/
  63. void SystemClock_Config(void);
  64. static void MX_GPIO_Init(void);
  65. static void MX_I2C1_Init(void);
  66. static void MX_SPI1_Init(void);
  67. static void MX_USB_PCD_Init(void);
  68. static void MX_TIM1_Init(void);
  69. static void MX_TIM2_Init(void);
  70.  
  71. void HAL_TIM_MspPostInit(TIM_HandleTypeDef *htim);
  72.  
  73.  
  74. /* USER CODE BEGIN PFP */
  75. /* Private function prototypes -----------------------------------------------*/
  76.  
  77. /* USER CODE END PFP */
  78.  
  79. /* USER CODE BEGIN 0 */
  80.  
  81. /* USER CODE END 0 */
  82.  
  83. /**
  84. * @brief The application entry point.
  85. *
  86. * @retval None
  87. */
  88. int main(void)
  89. {
  90. /* USER CODE BEGIN 1 */
  91.  
  92. /* USER CODE END 1 */
  93.  
  94. /* MCU Configuration----------------------------------------------------------*/
  95.  
  96. /* Reset of all peripherals, Initializes the Flash interface and the Systick. */
  97. HAL_Init();
  98.  
  99. /* USER CODE BEGIN Init */
  100. int nacin = 0; //ali gremo v + ali -?
  101. int test = 0;
  102. /* USER CODE END Init */
  103.  
  104. /* Configure the system clock */
  105. SystemClock_Config();
  106.  
  107. /* USER CODE BEGIN SysInit */
  108.  
  109. /* USER CODE END SysInit */
  110.  
  111. /* Initialize all configured peripherals */
  112. MX_GPIO_Init();
  113. MX_I2C1_Init();
  114. MX_SPI1_Init();
  115. MX_USB_PCD_Init();
  116. MX_TIM1_Init();
  117. MX_TIM2_Init();
  118. /* USER CODE BEGIN 2 */
  119. // zazenemo casovnik
  120. HAL_TIM_Base_Start(&htim1);
  121. HAL_TIM_Base_Start(&htim2);
  122.  
  123. // zazenemo PWM - neinvertirani izhodi
  124. HAL_TIM_PWM_Start(&htim1,TIM_CHANNEL_1);
  125.  
  126. // primer nastavljanja aktivne periode PWM iz programske kode
  127. // za kanal 1
  128. TIM1->CCR1=0;
  129. /* USER CODE END 2 */
  130.  
  131. /* Infinite loop */
  132. /* USER CODE BEGIN WHILE */
  133. while (1)
  134. {
  135. uint32_t vrednost=__HAL_TIM_GET_COUNTER(&htim2);
  136. //test = nacin se spremeni samo 1x
  137. if(vrednost == 10 && test == 0){
  138. if(nacin == 0)
  139. nacin = 1;
  140. else{
  141. nacin = 0;
  142. }
  143. test = 1;
  144. }
  145. if(vrednost == 0){
  146. //ko se timer resetira, resetiramo tud test
  147. test = 0;
  148. }
  149.  
  150. //gremo dol
  151. if(nacin == 1){
  152. if(vrednost < 10){
  153. TIM1->CCR1 = (10 - vrednost)*100;
  154. }
  155. else{
  156. TIM1->CCR1 = vrednost * 100;
  157. }
  158. }
  159. //gremo gor
  160. else{
  161. if(vrednost < 10){
  162. TIM1->CCR1 = vrednost*100;
  163. }
  164. else{
  165. TIM1->CCR1 = (10 - vrednost)*100;
  166. }
  167. }
  168.  
  169. /* USER CODE END WHILE */
  170.  
  171. /* USER CODE BEGIN 3 */
  172.  
  173. }
  174. /* USER CODE END 3 */
  175.  
  176. }
  177.  
  178. /**
  179. * @brief System Clock Configuration
  180. * @retval None
  181. */
  182. void SystemClock_Config(void)
  183. {
  184.  
  185. RCC_OscInitTypeDef RCC_OscInitStruct;
  186. RCC_ClkInitTypeDef RCC_ClkInitStruct;
  187. RCC_PeriphCLKInitTypeDef PeriphClkInit;
  188.  
  189. /**Initializes the CPU, AHB and APB busses clocks
  190. */
  191. RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI|RCC_OSCILLATORTYPE_HSE;
  192. RCC_OscInitStruct.HSEState = RCC_HSE_BYPASS;
  193. RCC_OscInitStruct.HSEPredivValue = RCC_HSE_PREDIV_DIV1;
  194. RCC_OscInitStruct.HSIState = RCC_HSI_ON;
  195. RCC_OscInitStruct.HSICalibrationValue = 16;
  196. RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON;
  197. RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSE;
  198. RCC_OscInitStruct.PLL.PLLMUL = RCC_PLL_MUL9;
  199. if (HAL_RCC_OscConfig(&RCC_OscInitStruct) != HAL_OK)
  200. {
  201. _Error_Handler(__FILE__, __LINE__);
  202. }
  203.  
  204. /**Initializes the CPU, AHB and APB busses clocks
  205. */
  206. RCC_ClkInitStruct.ClockType = RCC_CLOCKTYPE_HCLK|RCC_CLOCKTYPE_SYSCLK
  207. |RCC_CLOCKTYPE_PCLK1|RCC_CLOCKTYPE_PCLK2;
  208. RCC_ClkInitStruct.SYSCLKSource = RCC_SYSCLKSOURCE_PLLCLK;
  209. RCC_ClkInitStruct.AHBCLKDivider = RCC_SYSCLK_DIV1;
  210. RCC_ClkInitStruct.APB1CLKDivider = RCC_HCLK_DIV2;
  211. RCC_ClkInitStruct.APB2CLKDivider = RCC_HCLK_DIV1;
  212.  
  213. if (HAL_RCC_ClockConfig(&RCC_ClkInitStruct, FLASH_LATENCY_2) != HAL_OK)
  214. {
  215. _Error_Handler(__FILE__, __LINE__);
  216. }
  217.  
  218. PeriphClkInit.PeriphClockSelection = RCC_PERIPHCLK_USB|RCC_PERIPHCLK_I2C1
  219. |RCC_PERIPHCLK_TIM1;
  220. PeriphClkInit.I2c1ClockSelection = RCC_I2C1CLKSOURCE_HSI;
  221. PeriphClkInit.USBClockSelection = RCC_USBCLKSOURCE_PLL_DIV1_5;
  222. PeriphClkInit.Tim1ClockSelection = RCC_TIM1CLK_HCLK;
  223. if (HAL_RCCEx_PeriphCLKConfig(&PeriphClkInit) != HAL_OK)
  224. {
  225. _Error_Handler(__FILE__, __LINE__);
  226. }
  227.  
  228. /**Configure the Systick interrupt time
  229. */
  230. HAL_SYSTICK_Config(HAL_RCC_GetHCLKFreq()/1000);
  231.  
  232. /**Configure the Systick
  233. */
  234. HAL_SYSTICK_CLKSourceConfig(SYSTICK_CLKSOURCE_HCLK);
  235.  
  236. /* SysTick_IRQn interrupt configuration */
  237. HAL_NVIC_SetPriority(SysTick_IRQn, 0, 0);
  238. }
  239.  
  240. /* I2C1 init function */
  241. static void MX_I2C1_Init(void)
  242. {
  243.  
  244. hi2c1.Instance = I2C1;
  245. hi2c1.Init.Timing = 0x2000090E;
  246. hi2c1.Init.OwnAddress1 = 0;
  247. hi2c1.Init.AddressingMode = I2C_ADDRESSINGMODE_7BIT;
  248. hi2c1.Init.DualAddressMode = I2C_DUALADDRESS_DISABLE;
  249. hi2c1.Init.OwnAddress2 = 0;
  250. hi2c1.Init.OwnAddress2Masks = I2C_OA2_NOMASK;
  251. hi2c1.Init.GeneralCallMode = I2C_GENERALCALL_DISABLE;
  252. hi2c1.Init.NoStretchMode = I2C_NOSTRETCH_DISABLE;
  253. if (HAL_I2C_Init(&hi2c1) != HAL_OK)
  254. {
  255. _Error_Handler(__FILE__, __LINE__);
  256. }
  257.  
  258. /**Configure Analogue filter
  259. */
  260. if (HAL_I2CEx_ConfigAnalogFilter(&hi2c1, I2C_ANALOGFILTER_ENABLE) != HAL_OK)
  261. {
  262. _Error_Handler(__FILE__, __LINE__);
  263. }
  264.  
  265. /**Configure Digital filter
  266. */
  267. if (HAL_I2CEx_ConfigDigitalFilter(&hi2c1, 0) != HAL_OK)
  268. {
  269. _Error_Handler(__FILE__, __LINE__);
  270. }
  271.  
  272. }
  273.  
  274. /* SPI1 init function */
  275. static void MX_SPI1_Init(void)
  276. {
  277.  
  278. /* SPI1 parameter configuration*/
  279. hspi1.Instance = SPI1;
  280. hspi1.Init.Mode = SPI_MODE_MASTER;
  281. hspi1.Init.Direction = SPI_DIRECTION_2LINES;
  282. hspi1.Init.DataSize = SPI_DATASIZE_4BIT;
  283. hspi1.Init.CLKPolarity = SPI_POLARITY_LOW;
  284. hspi1.Init.CLKPhase = SPI_PHASE_1EDGE;
  285. hspi1.Init.NSS = SPI_NSS_SOFT;
  286. hspi1.Init.BaudRatePrescaler = SPI_BAUDRATEPRESCALER_4;
  287. hspi1.Init.FirstBit = SPI_FIRSTBIT_MSB;
  288. hspi1.Init.TIMode = SPI_TIMODE_DISABLE;
  289. hspi1.Init.CRCCalculation = SPI_CRCCALCULATION_DISABLE;
  290. hspi1.Init.CRCPolynomial = 7;
  291. hspi1.Init.CRCLength = SPI_CRC_LENGTH_DATASIZE;
  292. hspi1.Init.NSSPMode = SPI_NSS_PULSE_ENABLE;
  293. if (HAL_SPI_Init(&hspi1) != HAL_OK)
  294. {
  295. _Error_Handler(__FILE__, __LINE__);
  296. }
  297.  
  298. }
  299.  
  300. /* TIM1 init function */
  301. static void MX_TIM1_Init(void)
  302. {
  303.  
  304. TIM_ClockConfigTypeDef sClockSourceConfig;
  305. TIM_MasterConfigTypeDef sMasterConfig;
  306. TIM_OC_InitTypeDef sConfigOC;
  307. TIM_BreakDeadTimeConfigTypeDef sBreakDeadTimeConfig;
  308.  
  309. htim1.Instance = TIM1;
  310. htim1.Init.Prescaler = 71;
  311. htim1.Init.CounterMode = TIM_COUNTERMODE_UP;
  312. htim1.Init.Period = 999;
  313. htim1.Init.ClockDivision = TIM_CLOCKDIVISION_DIV1;
  314. htim1.Init.RepetitionCounter = 0;
  315. htim1.Init.AutoReloadPreload = TIM_AUTORELOAD_PRELOAD_DISABLE;
  316. if (HAL_TIM_Base_Init(&htim1) != HAL_OK)
  317. {
  318. _Error_Handler(__FILE__, __LINE__);
  319. }
  320.  
  321. sClockSourceConfig.ClockSource = TIM_CLOCKSOURCE_INTERNAL;
  322. if (HAL_TIM_ConfigClockSource(&htim1, &sClockSourceConfig) != HAL_OK)
  323. {
  324. _Error_Handler(__FILE__, __LINE__);
  325. }
  326.  
  327. if (HAL_TIM_PWM_Init(&htim1) != HAL_OK)
  328. {
  329. _Error_Handler(__FILE__, __LINE__);
  330. }
  331.  
  332. sMasterConfig.MasterOutputTrigger = TIM_TRGO_RESET;
  333. sMasterConfig.MasterOutputTrigger2 = TIM_TRGO2_RESET;
  334. sMasterConfig.MasterSlaveMode = TIM_MASTERSLAVEMODE_DISABLE;
  335. if (HAL_TIMEx_MasterConfigSynchronization(&htim1, &sMasterConfig) != HAL_OK)
  336. {
  337. _Error_Handler(__FILE__, __LINE__);
  338. }
  339.  
  340. sConfigOC.OCMode = TIM_OCMODE_PWM1;
  341. sConfigOC.Pulse = 100;
  342. sConfigOC.OCPolarity = TIM_OCPOLARITY_HIGH;
  343. sConfigOC.OCNPolarity = TIM_OCNPOLARITY_LOW;
  344. sConfigOC.OCFastMode = TIM_OCFAST_DISABLE;
  345. sConfigOC.OCIdleState = TIM_OCIDLESTATE_RESET;
  346. sConfigOC.OCNIdleState = TIM_OCNIDLESTATE_RESET;
  347. if (HAL_TIM_PWM_ConfigChannel(&htim1, &sConfigOC, TIM_CHANNEL_1) != HAL_OK)
  348. {
  349. _Error_Handler(__FILE__, __LINE__);
  350. }
  351.  
  352. sConfigOC.Pulse = 200;
  353. if (HAL_TIM_PWM_ConfigChannel(&htim1, &sConfigOC, TIM_CHANNEL_2) != HAL_OK)
  354. {
  355. _Error_Handler(__FILE__, __LINE__);
  356. }
  357.  
  358. sConfigOC.Pulse = 400;
  359. if (HAL_TIM_PWM_ConfigChannel(&htim1, &sConfigOC, TIM_CHANNEL_3) != HAL_OK)
  360. {
  361. _Error_Handler(__FILE__, __LINE__);
  362. }
  363.  
  364. sConfigOC.Pulse = 800;
  365. if (HAL_TIM_PWM_ConfigChannel(&htim1, &sConfigOC, TIM_CHANNEL_4) != HAL_OK)
  366. {
  367. _Error_Handler(__FILE__, __LINE__);
  368. }
  369.  
  370. sBreakDeadTimeConfig.OffStateRunMode = TIM_OSSR_DISABLE;
  371. sBreakDeadTimeConfig.OffStateIDLEMode = TIM_OSSI_DISABLE;
  372. sBreakDeadTimeConfig.LockLevel = TIM_LOCKLEVEL_OFF;
  373. sBreakDeadTimeConfig.DeadTime = 0;
  374. sBreakDeadTimeConfig.BreakState = TIM_BREAK_DISABLE;
  375. sBreakDeadTimeConfig.BreakPolarity = TIM_BREAKPOLARITY_HIGH;
  376. sBreakDeadTimeConfig.BreakFilter = 0;
  377. sBreakDeadTimeConfig.Break2State = TIM_BREAK2_DISABLE;
  378. sBreakDeadTimeConfig.Break2Polarity = TIM_BREAK2POLARITY_HIGH;
  379. sBreakDeadTimeConfig.Break2Filter = 0;
  380. sBreakDeadTimeConfig.AutomaticOutput = TIM_AUTOMATICOUTPUT_DISABLE;
  381. if (HAL_TIMEx_ConfigBreakDeadTime(&htim1, &sBreakDeadTimeConfig) != HAL_OK)
  382. {
  383. _Error_Handler(__FILE__, __LINE__);
  384. }
  385.  
  386. HAL_TIM_MspPostInit(&htim1);
  387.  
  388. }
  389.  
  390. /* TIM2 init function */
  391. static void MX_TIM2_Init(void)
  392. {
  393.  
  394. TIM_ClockConfigTypeDef sClockSourceConfig;
  395. TIM_MasterConfigTypeDef sMasterConfig;
  396.  
  397. htim2.Instance = TIM2;
  398. htim2.Init.Prescaler = 0;
  399. htim2.Init.CounterMode = TIM_COUNTERMODE_UP;
  400. htim2.Init.Period = 10;
  401. htim2.Init.ClockDivision = TIM_CLOCKDIVISION_DIV1;
  402. htim2.Init.AutoReloadPreload = TIM_AUTORELOAD_PRELOAD_DISABLE;
  403. if (HAL_TIM_Base_Init(&htim2) != HAL_OK)
  404. {
  405. _Error_Handler(__FILE__, __LINE__);
  406. }
  407.  
  408. sClockSourceConfig.ClockSource = TIM_CLOCKSOURCE_ETRMODE2;
  409. sClockSourceConfig.ClockPolarity = TIM_CLOCKPOLARITY_NONINVERTED;
  410. sClockSourceConfig.ClockPrescaler = TIM_CLOCKPRESCALER_DIV1;
  411. sClockSourceConfig.ClockFilter = 0;
  412. if (HAL_TIM_ConfigClockSource(&htim2, &sClockSourceConfig) != HAL_OK)
  413. {
  414. _Error_Handler(__FILE__, __LINE__);
  415. }
  416.  
  417. sMasterConfig.MasterOutputTrigger = TIM_TRGO_RESET;
  418. sMasterConfig.MasterSlaveMode = TIM_MASTERSLAVEMODE_DISABLE;
  419. if (HAL_TIMEx_MasterConfigSynchronization(&htim2, &sMasterConfig) != HAL_OK)
  420. {
  421. _Error_Handler(__FILE__, __LINE__);
  422. }
  423.  
  424. }
  425.  
  426. /* USB init function */
  427. static void MX_USB_PCD_Init(void)
  428. {
  429.  
  430. hpcd_USB_FS.Instance = USB;
  431. hpcd_USB_FS.Init.dev_endpoints = 8;
  432. hpcd_USB_FS.Init.speed = PCD_SPEED_FULL;
  433. hpcd_USB_FS.Init.ep0_mps = DEP0CTL_MPS_64;
  434. hpcd_USB_FS.Init.phy_itface = PCD_PHY_EMBEDDED;
  435. hpcd_USB_FS.Init.low_power_enable = DISABLE;
  436. hpcd_USB_FS.Init.battery_charging_enable = DISABLE;
  437. if (HAL_PCD_Init(&hpcd_USB_FS) != HAL_OK)
  438. {
  439. _Error_Handler(__FILE__, __LINE__);
  440. }
  441.  
  442. }
  443.  
  444. /** Configure pins as
  445. * Analog
  446. * Input
  447. * Output
  448. * EVENT_OUT
  449. * EXTI
  450. */
  451. static void MX_GPIO_Init(void)
  452. {
  453.  
  454. GPIO_InitTypeDef GPIO_InitStruct;
  455.  
  456. /* GPIO Ports Clock Enable */
  457. __HAL_RCC_GPIOE_CLK_ENABLE();
  458. __HAL_RCC_GPIOC_CLK_ENABLE();
  459. __HAL_RCC_GPIOF_CLK_ENABLE();
  460. __HAL_RCC_GPIOA_CLK_ENABLE();
  461. __HAL_RCC_GPIOB_CLK_ENABLE();
  462.  
  463. /*Configure GPIO pin Output Level */
  464. HAL_GPIO_WritePin(GPIOE, CS_I2C_SPI_Pin|LD6_Pin, GPIO_PIN_RESET);
  465.  
  466. /*Configure GPIO pins : DRDY_Pin MEMS_INT3_Pin MEMS_INT4_Pin MEMS_INT1_Pin
  467. MEMS_INT2_Pin */
  468. GPIO_InitStruct.Pin = DRDY_Pin|MEMS_INT3_Pin|MEMS_INT4_Pin|MEMS_INT1_Pin
  469. |MEMS_INT2_Pin;
  470. GPIO_InitStruct.Mode = GPIO_MODE_EVT_RISING;
  471. GPIO_InitStruct.Pull = GPIO_NOPULL;
  472. HAL_GPIO_Init(GPIOE, &GPIO_InitStruct);
  473.  
  474. /*Configure GPIO pins : CS_I2C_SPI_Pin LD6_Pin */
  475. GPIO_InitStruct.Pin = CS_I2C_SPI_Pin|LD6_Pin;
  476. GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP;
  477. GPIO_InitStruct.Pull = GPIO_NOPULL;
  478. GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
  479. HAL_GPIO_Init(GPIOE, &GPIO_InitStruct);
  480.  
  481. }
  482.  
  483. /* USER CODE BEGIN 4 */
  484.  
  485. /* USER CODE END 4 */
  486.  
  487. /**
  488. * @brief This function is executed in case of error occurrence.
  489. * @param file: The file name as string.
  490. * @param line: The line in file as a number.
  491. * @retval None
  492. */
  493. void _Error_Handler(char *file, int line)
  494. {
  495. /* USER CODE BEGIN Error_Handler_Debug */
  496. /* User can add his own implementation to report the HAL error return state */
  497. while(1)
  498. {
  499. }
  500. /* USER CODE END Error_Handler_Debug */
  501. }
  502.  
  503. #ifdef USE_FULL_ASSERT
  504. /**
  505. * @brief Reports the name of the source file and the source line number
  506. * where the assert_param error has occurred.
  507. * @param file: pointer to the source file name
  508. * @param line: assert_param error line source number
  509. * @retval None
  510. */
  511. void assert_failed(uint8_t* file, uint32_t line)
  512. {
  513. /* USER CODE BEGIN 6 */
  514. /* User can add his own implementation to report the file name and line number,
  515. tex: printf("Wrong parameters value: file %s on line %d\r\n", file, line) */
  516. /* USER CODE END 6 */
  517. }
  518. #endif /* USE_FULL_ASSERT */
  519.  
  520. /**
  521. * @}
  522. */
  523.  
  524. /**
  525. * @}
  526. */
  527.  
  528. /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement