Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
A
Ardupilot
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
OpenSource
Ardupilot
Commits
a165644d
Commit
a165644d
authored
12 years ago
by
uncrustify
Committed by
Pat Hickey
12 years ago
Browse files
Options
Downloads
Patches
Plain Diff
uncrustify ArduPlane/planner.pde
parent
09d5af69
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
ArduPlane/planner.pde
+23
-23
23 additions, 23 deletions
ArduPlane/planner.pde
with
23 additions
and
23 deletions
ArduPlane/planner.pde
+
23
−
23
View file @
a165644d
...
...
@@ -2,14 +2,14 @@
// These are function definitions so the Menu can be constructed before the functions
// are defined below. Order matters to the compiler.
static
int8_t
planner_gcs
(
uint8_t
argc
,
const
Menu
::
arg
*
argv
);
static
int8_t
planner_gcs
(
uint8_t
argc
,
const
Menu
::
arg
*
argv
);
// Creates a constant array of structs representing menu options
// and stores them in Flash memory, not RAM.
// User enters the string in the console to call the functions on the right.
// See class Menu in AP_Common for implementation details
static
const
struct
Menu
::
command
planner_menu_commands
[]
PROGMEM
=
{
{
"gcs"
,
planner_gcs
},
{
"gcs"
,
planner_gcs
},
};
// A Macro to create the Menu
...
...
@@ -18,36 +18,36 @@ MENU(planner_menu, "planner", planner_menu_commands);
static
int8_t
planner_mode
(
uint8_t
argc
,
const
Menu
::
arg
*
argv
)
{
Serial
.
printf_P
(
PSTR
(
"Planner Mode
\n\n
This mode is not intended for manual use
\n\n
"
));
planner_menu
.
run
();
Serial
.
printf_P
(
PSTR
(
"Planner Mode
\n\n
This mode is not intended for manual use
\n\n
"
));
planner_menu
.
run
();
return
0
;
}
static
int8_t
planner_gcs
(
uint8_t
argc
,
const
Menu
::
arg
*
argv
)
{
gcs0
.
init
(
&
Serial
);
gcs0
.
init
(
&
Serial
);
#if USB_MUX_PIN < 0
// we don't have gcs3 if we have the USB mux setup
gcs3
.
init
(
&
Serial3
);
// we don't have gcs3 if we have the USB mux setup
gcs3
.
init
(
&
Serial3
);
#endif
int16_t
loopcount
=
0
;
while
(
1
)
{
if
(
millis
()
-
fast_loopTimer_ms
>
19
)
{
fast_loopTimer_ms
=
millis
();
gcs_update
();
read_radio
();
gcs_data_stream_send
();
if
((
loopcount
%
16
)
==
0
)
{
// 3 hz
gcs_send_message
(
MSG_HEARTBEAT
);
}
loopcount
++
;
int16_t
loopcount
=
0
;
while
(
1
)
{
if
(
millis
()
-
fast_loopTimer_ms
>
19
)
{
fast_loopTimer_ms
=
millis
();
gcs_update
();
read_radio
();
gcs_data_stream_send
();
if
((
loopcount
%
16
)
==
0
)
{
// 3 hz
gcs_send_message
(
MSG_HEARTBEAT
);
}
loopcount
++
;
}
}
}
return
0
;
return
0
;
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment