mirror of
https://gitlab1.ptb.de/waltem01/Matrix
synced 2024-12-25 11:31:46 +00:00
additional commenting
This commit is contained in:
parent
b80596a181
commit
3dcba100fe
@ -143,15 +143,18 @@
|
|||||||
|
|
||||||
// Array of instructions for drawing lines and shapes
|
// Array of instructions for drawing lines and shapes
|
||||||
const instructions = [
|
const instructions = [
|
||||||
|
// Draw clock hands
|
||||||
lineInstruction(middle.x, middle.y, clock.positions?.second!),
|
lineInstruction(middle.x, middle.y, clock.positions?.second!),
|
||||||
lineInstruction(middle.x, middle.y, clock.positions?.minute!),
|
lineInstruction(middle.x, middle.y, clock.positions?.minute!),
|
||||||
lineInstruction(middle.x, middle.y, clock.positions?.hour!),
|
lineInstruction(middle.x, middle.y, clock.positions?.hour!),
|
||||||
|
// Draw clock body
|
||||||
{
|
{
|
||||||
endpoint: 'circle',
|
endpoint: 'circle',
|
||||||
x: middle.x,
|
x: middle.x,
|
||||||
y: middle.y,
|
y: middle.y,
|
||||||
r: Math.floor((clock.body / 100) * matrix.height)
|
r: Math.floor((clock.body / 100) * matrix.height)
|
||||||
} as CircleInstruction,
|
} as CircleInstruction,
|
||||||
|
// Update matrix to display clock
|
||||||
{
|
{
|
||||||
endpoint: 'update'
|
endpoint: 'update'
|
||||||
} as UpdateInstruction
|
} as UpdateInstruction
|
||||||
|
Loading…
Reference in New Issue
Block a user