Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
TFT_eSPI
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
TFT_eSPI
Commits
39fe01af
Commit
39fe01af
authored
Oct 06, 2020
by
Bodmer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update Animated_dial.ino
Correct error in example that became apparent with recent library updates.
parent
22ca8193
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
examples/Sprite/Animated_dial/Animated_dial.ino
examples/Sprite/Animated_dial/Animated_dial.ino
+2
-2
No files found.
examples/Sprite/Animated_dial/Animated_dial.ino
View file @
39fe01af
...
...
@@ -89,7 +89,7 @@ void setup() {
spr
.
setTextColor
(
TFT_WHITE
,
bg_color
);
spr
.
setTextDatum
(
MC_DATUM
);
spr
.
setTextPadding
(
spr_width
);
spr
.
drawNumber
(
0
,
spr_width
/
2
,
0
);
spr
.
drawNumber
(
0
,
spr_width
/
2
,
spr
.
fontHeight
()
/
2
);
spr
.
pushSprite
(
DIAL_CENTRE_X
-
spr_width
/
2
,
DIAL_CENTRE_Y
-
spr
.
fontHeight
()
/
2
);
// Plot the label text
...
...
@@ -203,7 +203,7 @@ void plotNeedle(int16_t angle, uint16_t ms_delay)
}
// Update the number at the centre of the dial
spr
.
drawNumber
(
old_angle
+
120
,
spr_width
/
2
,
0
);
spr
.
drawNumber
(
old_angle
+
120
,
spr_width
/
2
,
spr
.
fontHeight
()
/
2
);
spr
.
pushSprite
(
120
-
spr_width
/
2
,
120
-
spr
.
fontHeight
()
/
2
);
// Slow needle down slightly as it approaches the new position
...
...
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