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
dos
firmware
Commits
1bb79811
Verified
Commit
1bb79811
authored
5 years ago
by
rahix
Browse files
Options
Downloads
Patches
Plain Diff
chore(epicardium): Format remaining files
Signed-off-by:
Rahix
<
rahix@rahix.de
>
parent
31a49f64
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
epicardium/cdcacm.c
+178
-170
178 additions, 170 deletions
epicardium/cdcacm.c
epicardium/modules/pmic.c
+7
-4
7 additions, 4 deletions
epicardium/modules/pmic.c
with
185 additions
and
174 deletions
epicardium/cdcacm.c
+
178
−
170
View file @
1bb79811
...
...
@@ -117,7 +117,6 @@ void delay_us(unsigned int usec)
mxc_delay
(
usec
);
}
/******************************************************************************/
int
cdcacm_init
(
void
)
{
...
...
@@ -131,7 +130,8 @@ int cdcacm_init(void)
/* Start out in full speed */
usb_opts
.
enable_hs
=
0
;
usb_opts
.
delay_us
=
delay_us
;
/* Function which will be used for delays */
usb_opts
.
delay_us
=
delay_us
;
/* Function which will be used for delays */
usb_opts
.
init_callback
=
usb_startup_cb
;
usb_opts
.
shutdown_callback
=
usb_shutdown_cb
;
...
...
@@ -148,8 +148,12 @@ int cdcacm_init(void)
}
/* Register enumeration data */
enum_register_descriptor
(
ENUM_DESC_DEVICE
,
(
uint8_t
*
)
&
device_descriptor
,
0
);
enum_register_descriptor
(
ENUM_DESC_CONFIG
,
(
uint8_t
*
)
&
config_descriptor
,
0
);
enum_register_descriptor
(
ENUM_DESC_DEVICE
,
(
uint8_t
*
)
&
device_descriptor
,
0
);
enum_register_descriptor
(
ENUM_DESC_CONFIG
,
(
uint8_t
*
)
&
config_descriptor
,
0
);
enum_register_descriptor
(
ENUM_DESC_STRING
,
lang_id_desc
,
0
);
enum_register_descriptor
(
ENUM_DESC_STRING
,
mfg_id_desc
,
1
);
enum_register_descriptor
(
ENUM_DESC_STRING
,
prod_id_desc
,
2
);
...
...
@@ -206,12 +210,13 @@ void cdcacm_write(uint8_t *data, int len)
LOG_ERR
(
"cdcacm"
,
"fifo lockup detected"
);
lockup_disable
=
1
;
}
else
if
(
ret
!=
len
)
{
LOG_WARN
(
"cdcacm"
,
"write length mismatch, got %d"
,
ret
);
LOG_WARN
(
"cdcacm"
,
"write length mismatch, got %d"
,
ret
);
}
}
}
/******************************************************************************/
#if 0
static void echo_usb(void)
...
...
@@ -244,7 +249,8 @@ static void echo_usb(void)
static
int
setconfig_callback
(
usb_setup_pkt
*
sud
,
void
*
cbdata
)
{
/* Confirm the configuration value */
if
(
sud
->
wValue
==
config_descriptor
.
config_descriptor
.
bConfigurationValue
)
{
if
(
sud
->
wValue
==
config_descriptor
.
config_descriptor
.
bConfigurationValue
)
{
configured
=
1
;
MXC_SETBIT
(
&
event_flags
,
EVENT_ENUM_COMP
);
return
acm_configure
(
&
acm_cfg
);
/* Configure the device class */
...
...
@@ -359,7 +365,9 @@ void USB_IRQHandler(void)
if
(
serial_task_id
!=
NULL
)
{
BaseType_t
xHigherPriorityTaskWoken
=
pdFALSE
;
vTaskNotifyGiveFromISR
(
serial_task_id
,
&
xHigherPriorityTaskWoken
);
vTaskNotifyGiveFromISR
(
serial_task_id
,
&
xHigherPriorityTaskWoken
);
portYIELD_FROM_ISR
(
xHigherPriorityTaskWoken
);
}
}
...
...
This diff is collapsed.
Click to expand it.
epicardium/modules/pmic.c
+
7
−
4
View file @
1bb79811
...
...
@@ -62,8 +62,11 @@ void vPmicTask(void *pvParameters)
/* TODO: Remove when all interrupts are handled */
if
(
int_flag
&
~
(
MAX77650_INT_nEN_F
|
MAX77650_INT_nEN_R
))
{
LOG_WARN
(
"pmic"
,
"Unhandled PMIC Interrupt: %x"
,
int_flag
);
LOG_WARN
(
"pmic"
,
"Unhandled PMIC Interrupt: %x"
,
int_flag
);
}
if
(
delay
!=
portMAX_DELAY
)
{
...
...
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