Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
car-controlserver
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wenzhongjian
car-controlserver
Commits
28919483
Commit
28919483
authored
Jul 31, 2025
by
957dd
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调整水tank控制
parent
2b1f2196
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
2 additions
and
11 deletions
+2
-11
main
build/main
+0
-0
tank0206_control.c
drivers/devicecontrol/tank0206_control.c
+2
-2
gpio_init.c
drivers/gpio/gpio_init.c
+0
-6
gpio_init.h
drivers/gpio/gpio_init.h
+0
-3
No files found.
build/main
View file @
28919483
No preview for this file type
drivers/devicecontrol/tank0206_control.c
View file @
28919483
...
...
@@ -174,9 +174,9 @@ void tank0206_change(unsigned char *buf) {
if
(
mode
==
1
)
{
tank0206_mode_lift_flont
(
val
);
//
tank0206_mode_right_flont(val);
tank0206_mode_right_flont
(
val
);
}
else
if
(
mode
==
2
)
{
//
tank0206_mode_lift_back(val);
tank0206_mode_lift_back
(
val
);
tank0206_mode_right_back
(
val
);
}
...
...
drivers/gpio/gpio_init.c
View file @
28919483
...
...
@@ -7,8 +7,6 @@
#define MIN_DUTY 0 // 最小占空比
#define MAX_DUTY 100 // 最大占空比
// int device_delay_count =0;//设备计算函数
int
g_gpioPwm
[
30
];
//软件控制
int
g_gpiowpi
[
40
];
//能使用高低引脚和其他引脚
...
...
@@ -121,6 +119,3 @@ void physics_pwm_init() {
}
void
device_exit_end
(){
//main最后结束需要调用的函数
//if(AppExit_pin_pwm == 202) tank_shot_back_stop_task_end();
}
\ No newline at end of file
drivers/gpio/gpio_init.h
View file @
28919483
...
...
@@ -5,8 +5,6 @@
#ifndef GPIO_INIT_H__
#define GPIO_INIT_H__
//extern int device_delay_count;//延时计算函数,使用前必须置0
// 定义 PWM 引脚的 WiringPi 编号
#define PWM_PIN_SPEED 21
#define PWM_PIN_CHANGE 2
...
...
@@ -23,6 +21,5 @@ void pin_value(int pin,int value);
void
physics_pwm_init
();
void
pwm_value
(
int
pin
,
int
value
);
//软件陪我们控制调速
void
device_exit_end
();
//main最后结束需要调用的函数
#endif
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment