23 lines
746 B
Scheme
23 lines
746 B
Scheme
|
(use-modules ((inkplate lowlevel) #:prefix inkplate:)
|
||
|
(srfi srfi-19))
|
||
|
|
||
|
(let ((my-dev (inkplate:open "/dev/ttyUSB0")))
|
||
|
(inkplate:clear-screen my-dev)
|
||
|
(inkplate:set-cursor my-dev 280 100)
|
||
|
|
||
|
(inkplate:set-text-size my-dev 10)
|
||
|
(inkplate:print my-dev (inkplate:convert-string-to-hex (date->string (current-date) "~Y")))
|
||
|
|
||
|
(inkplate:set-cursor my-dev 275 180)
|
||
|
(inkplate:set-text-size my-dev 8)
|
||
|
(inkplate:print my-dev (inkplate:convert-string-to-hex (date->string (current-date) "~m-~d")))
|
||
|
|
||
|
(inkplate:draw-rectangle my-dev 270 90 250 155 3)
|
||
|
(inkplate:draw-rectangle my-dev 269 89 252 157 3)
|
||
|
(inkplate:draw-rectangle my-dev 268 88 254 159 3)
|
||
|
|
||
|
(inkplate:update my-dev)
|
||
|
(inkplate:send my-dev)
|
||
|
|
||
|
(inkplate:close my-dev))
|