Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
F
firmware
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
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
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
trilader
firmware
Commits
32144f97
Verified
Commit
32144f97
authored
5 years ago
by
rahix
Browse files
Options
Downloads
Patches
Plain Diff
feat(epicardium): Add switch for core 1 debugging
Signed-off-by:
Rahix
<
rahix@rahix.de
>
parent
1067d234
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
Documentation/how-to-build.rst
+2
-0
2 additions, 0 deletions
Documentation/how-to-build.rst
epicardium/main.c
+19
-1
19 additions, 1 deletion
epicardium/main.c
meson.build
+7
-0
7 additions, 0 deletions
meson.build
meson_options.txt
+8
-0
8 additions, 0 deletions
meson_options.txt
with
36 additions
and
1 deletion
Documentation/how-to-build.rst
+
2
−
0
View file @
32144f97
...
...
@@ -68,6 +68,8 @@ firmware features:
- ``-Ddebug_prints=true``: Print more verbose debugging log messages
- ``-Dble_trace=true``: Enable BLE tracing. This will output lots of status
info related to BLE.
- ``-Ddebug_core1=true``: Enable the core 1 SWD lines which are exposed on the
SAO connector. Only use this if you have a debugger which is modified for core 1.
.. warning::
...
...
This diff is collapsed.
Click to expand it.
epicardium/main.c
+
19
−
1
View file @
32144f97
...
...
@@ -6,6 +6,7 @@
#include
"max32665.h"
#include
"uart.h"
#include
"cdcacm.h"
#include
"gpio.h"
#include
"card10.h"
#include
"pmic.h"
...
...
@@ -51,7 +52,24 @@ int main(void)
LOG_INFO
(
"startup"
,
"Version "
CARD10_VERSION
);
card10_init
();
card10_diag
();
#ifdef CARD10_DEBUG_CORE1
LOG_WARN
(
"startup"
,
"Core 1 Debugger Mode"
);
static
const
gpio_cfg_t
swclk
=
{
PORT_0
,
PIN_7
,
GPIO_FUNC_ALT3
,
GPIO_PAD_NONE
,
};
static
const
gpio_cfg_t
swdio
=
{
PORT_0
,
PIN_6
,
GPIO_FUNC_ALT3
,
GPIO_PAD_NONE
,
};
GPIO_Config
(
&
swclk
);
GPIO_Config
(
&
swdio
);
#endif
/* CARD10_DEBUG_CORE1 */
gfx_copy_region_raw
(
&
display_screen
,
0
,
0
,
160
,
80
,
2
,
(
const
void
*
)(
Heart
)
...
...
This diff is collapsed.
Click to expand it.
meson.build
+
7
−
0
View file @
32144f97
...
...
@@ -28,6 +28,13 @@ if get_option('debug_prints')
)
endif
if
get_option
(
'debug_core1'
)
add_global_arguments
(
[
'-DCARD10_DEBUG_CORE1=1'
],
language
:
'c'
,
)
endif
add_global_link_arguments
(
'-Wl,--gc-sections'
,
'-lm'
,
...
...
This diff is collapsed.
Click to expand it.
meson_options.txt
+
8
−
0
View file @
32144f97
...
...
@@ -6,6 +6,14 @@ option(
description
:
'Whether to print debug messages on the serial console'
)
option
(
'debug_core1'
,
type
:
'boolean'
,
value
:
false
,
description
:
'Enable core 1 debugging interface'
)
option
(
'ble_trace'
,
type
:
'boolean'
,
...
...
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