Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
st7789_mpy
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
st7789_mpy
Commits
30087b4e
Commit
30087b4e
authored
May 26, 2020
by
Russ
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: compile error: mp_raise_ValueError issue #1
parent
ff343dc6
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
3 deletions
+3
-3
firmware/README.md
firmware/README.md
+1
-1
firmware/firmware.bin
firmware/firmware.bin
+0
-0
st7789/st7789.c
st7789/st7789.c
+2
-2
No files found.
firmware/README.md
View file @
30087b4e
MicroPython v1.12-
96-gc3095b37e
compiled using ESP IDF v3
MicroPython v1.12-
464-gcae77daf0
compiled using ESP IDF v3
with the st7789 C driver and the frozen python font files:
-
vga1_8x8.py
...
...
firmware/firmware.bin
View file @
30087b4e
No preview for this file type
st7789/st7789.c
View file @
30087b4e
...
...
@@ -714,12 +714,12 @@ mp_obj_t st7789_ST7789_make_new(const mp_obj_type_t *type,
self
->
rotation
=
args
[
ARG_rotation
].
u_int
%
4
;
if
(
self
->
display_height
!=
240
||
(
self
->
display_width
!=
240
&&
self
->
display_width
!=
135
))
{
mp_raise_ValueError
(
"Unsupported display. Only 240x240 and 135x240 are supported"
);
mp_raise_ValueError
(
MP_ERROR_TEXT
(
"Unsupported display. Only 240x240 and 135x240 are supported"
)
);
}
if
(
args
[
ARG_reset
].
u_obj
==
MP_OBJ_NULL
||
args
[
ARG_dc
].
u_obj
==
MP_OBJ_NULL
)
{
mp_raise_ValueError
(
"must specify all of reset/dc pins"
);
mp_raise_ValueError
(
MP_ERROR_TEXT
(
"must specify all of reset/dc pins"
)
);
}
self
->
reset
=
mp_hal_get_pin_obj
(
args
[
ARG_reset
].
u_obj
);
...
...
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