Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
uPython-mirror
Commits
b0accc85
Commit
b0accc85
authored
Aug 16, 2014
by
Damien George
Browse files
stmhal: Fix printing of pin name in error message.
parent
d779b964
Changes
1
Hide whitespace changes
Inline
Side-by-side
stmhal/adc.c
View file @
b0accc85
...
...
@@ -167,7 +167,7 @@ STATIC mp_obj_t adc_make_new(mp_obj_t type_in, uint n_args, uint n_kw, const mp_
const
pin_obj_t
*
pin
=
pin_find
(
pin_obj
);
if
((
pin
->
adc_num
&
PIN_ADC1
)
==
0
)
{
// No ADC1 function on that pin
nlr_raise
(
mp_obj_new_exception_msg_varg
(
&
mp_type_ValueError
,
"pin %s does not have ADC capabilities"
,
pin
->
name
));
nlr_raise
(
mp_obj_new_exception_msg_varg
(
&
mp_type_ValueError
,
"pin %s does not have ADC capabilities"
,
qstr_str
(
pin
->
name
))
)
;
}
channel
=
pin
->
adc_channel
;
}
...
...
Write
Preview
Supports
Markdown
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