加入大疆C板例程bsp
This commit is contained in:
12
bsp/boards/bsp_laser.c
Normal file
12
bsp/boards/bsp_laser.c
Normal file
@@ -0,0 +1,12 @@
|
||||
#include "bsp_laser.h"
|
||||
#include "main.h"
|
||||
|
||||
extern TIM_HandleTypeDef htim3;
|
||||
void laser_on(void)
|
||||
{
|
||||
__HAL_TIM_SetCompare(&htim3, TIM_CHANNEL_3, 8399);
|
||||
}
|
||||
void laser_off(void)
|
||||
{
|
||||
__HAL_TIM_SetCompare(&htim3, TIM_CHANNEL_3, 0);
|
||||
}
|
||||
Reference in New Issue
Block a user