11/*
22 * Copyright (c) 2019, Mike Wolfram
3+ * Copyright (c) 2021, Thomas Sommer
34 *
45 * This file is part of the modm project.
56 *
1516#include < modm/architecture/interface/register.hpp>
1617#include < modm/platform/gpio/base.hpp>
1718#include < modm/processing/resumable.hpp>
18- #include < modm/ui/graphic.hpp>
19+
20+ #include < modm/ui/graphic/display.hpp>
21+ #include < modm/ui/graphic/buffer.hpp>
22+ #include < modm/ui/graphic/buffer_bool.hpp>
23+ // #include <modm/ui/graphic/painter_remote.hpp>
1924
2025#include " ili9341_interface_parallel.hpp"
2126#include " ili9341_interface_spi.hpp"
@@ -28,8 +33,9 @@ namespace modm
2833// / @ingroup modm_driver_ili9341
2934template <class Interface , class Reset , typename RB = Resolution<32 , 32 >>
3035class Ili9341
31- : public Interface, public Display<color::Rgb565<true >, Resolution<320 , 240 >>,
32- public ShapePainter<Resolution<320 , 240 >, true >,
36+ : public Interface,
37+ // : public RemotePainter<Resolution<320, 240>, Interface>,
38+ public Display<color::Rgb565<true >, Resolution<320 , 240 >>,
3339 public FlashPainter<true >
3440// TODO LocalPainter must be available so we can Paint directly on ili9341
3541// class Ili9341 : public Interface, public Display<color::Rgb565<true>, 320, 240>, public LocalPainter<320, 240>
@@ -43,7 +49,8 @@ class Ili9341
4349
4450public:
4551 template <typename ... Args>
46- Ili9341 (Args &&...args) : Interface(std::forward<Args>(args)...),
52+ Ili9341 (Args &&...args) :
53+ Interface (std::forward<Args>(args)...),
4754 Display<color::Rgb565<true >, Resolution<320 , 240 >>(color::html::White)
4855 { Reset::setOutput (modm::Gpio::High); }
4956
@@ -119,7 +126,7 @@ class Ili9341
119126 modm::ResumableResult<void > setClipping (Point point);
120127 modm::ResumableResult<void > setClipping (Area area);
121128
122- // TODO add final
129+ // TODO Add final as soon as RemotePainter is connected
123130 // Hardware accelerated drawing directly on the screen
124131 modm::ResumableResult<void > drawFast (Point point);
125132 modm::ResumableResult<void > drawFast (HLine hline);
@@ -133,8 +140,7 @@ class Ili9341
133140 uint16_t buff_cmd16[3 ];
134141 ili9341_register::MemoryAccessCtrl_t madCtrl;
135142
136- // Parallel use in resumable function
137- // No overlap permitted!
143+ // Parallel use in resumable function: don't overlap!
138144 struct {
139145 // Buffer for color conversion
140146 modm::Buffer<modm::color::Rgb565<true >, RB> bufferRgb565;
0 commit comments