Skip to content
This repository was archived by the owner on Feb 12, 2025. It is now read-only.

Commit 4b69ca5

Browse files
committed
Release 7.0.4
Added example Common_Persistent
1 parent ef64a88 commit 4b69ca5

File tree

4 files changed

+149
-6
lines changed

4 files changed

+149
-6
lines changed
Lines changed: 143 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,143 @@
1+
///
2+
/// @file Common_Persistent.ino
3+
/// @brief Example of features for basic edition
4+
///
5+
/// @details Project Pervasive Displays Library Suite
6+
/// @n Based on highView technology
7+
///
8+
/// @author Rei Vilo
9+
/// @date 21 Jan 2023
10+
/// @version 704
11+
///
12+
/// @copyright (c) Rei Vilo, 2010-2024
13+
/// @copyright Creative Commons Attribution-ShareAlike 4.0 International (CC BY-SA 4.0)
14+
///
15+
/// @see ReadMe.txt for references
16+
/// @n
17+
///
18+
19+
// Screen
20+
#include "PDLS_EXT3_Basic_Global.h"
21+
22+
// SDK
23+
// #include <Arduino.h>
24+
#include "hV_HAL_Peripherals.h"
25+
26+
// Include application, user and local libraries
27+
// #include <SPI.h>
28+
29+
// Configuration
30+
#include "hV_Configuration.h"
31+
32+
// Set parameters
33+
34+
// Define structures and classes
35+
36+
// Define variables and constants
37+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_154, boardRaspberryPiPico_RP2040);
38+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_213, boardRaspberryPiPico_RP2040);
39+
Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_266, boardRaspberryPiPico_RP2040);
40+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_271, boardRaspberryPiPico_RP2040);
41+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_287, boardRaspberryPiPico_RP2040);
42+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_370, boardRaspberryPiPico_RP2040);
43+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_417, boardRaspberryPiPico_RP2040);
44+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_437, boardRaspberryPiPico_RP2040);
45+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_565, boardRaspberryPiPico_RP2040);
46+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_581, boardRaspberryPiPico_RP2040);
47+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_741, boardRaspberryPiPico_RP2040);
48+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_969, boardRaspberryPiPico_RP2040);
49+
// Screen_EPD_EXT3 myScreen(eScreen_EPD_EXT3_B98, boardRaspberryPiPico_RP2040);
50+
51+
// Prototypes
52+
53+
// Utilities
54+
///
55+
/// @brief Wait with countdown
56+
/// @param second duration, s
57+
///
58+
void wait(uint8_t second)
59+
{
60+
for (uint8_t i = second; i > 0; i--)
61+
{
62+
Serial.print(formatString(" > %i \r", i));
63+
delay(1000);
64+
}
65+
Serial.print(" \r");
66+
}
67+
68+
// Functions
69+
///
70+
/// @brief Who am i? test screen
71+
///
72+
void displayPersistent()
73+
{
74+
myScreen.setOrientation(ORIENTATION_LANDSCAPE);
75+
myScreen.selectFont(Font_Terminal8x12);
76+
uint16_t dy = myScreen.characterSizeY();
77+
uint16_t y = 4;
78+
79+
myScreen.gText(4, y, myScreen.WhoAmI());
80+
y += dy;
81+
82+
myScreen.gText(4, y, formatString("%i x %i", myScreen.screenSizeX(), myScreen.screenSizeY()));
83+
y += dy;
84+
85+
myScreen.gText(4, y, formatString("PDLS %s v%i.%i.%i", SCREEN_EPD_EXT3_VARIANT, SCREEN_EPD_EXT3_RELEASE / 100, (SCREEN_EPD_EXT3_RELEASE / 10) % 10, SCREEN_EPD_EXT3_RELEASE % 10));
86+
y += dy;
87+
y += dy;
88+
89+
myScreen.selectFont(Font_Terminal6x8);
90+
myScreen.gText(4, y, "Unplug when the LED is on");
91+
92+
myScreen.flush();
93+
}
94+
95+
// Add setup code
96+
///
97+
/// @brief Setup
98+
///
99+
void setup()
100+
{
101+
Serial.begin(115200);
102+
delay(500);
103+
104+
Serial.println();
105+
Serial.println("=== " __FILE__);
106+
Serial.println("=== " __DATE__ " " __TIME__);
107+
Serial.println();
108+
109+
pinMode(LED_BUILTIN, OUTPUT);
110+
for (uint8_t i = 1; i < 7; i += 1)
111+
{
112+
digitalWrite(LED_BUILTIN, i % 2);
113+
delay(250);
114+
}
115+
116+
Serial.println("begin... ");
117+
myScreen.begin();
118+
Serial.println(formatString("%s %ix%i", myScreen.WhoAmI().c_str(), myScreen.screenSizeX(), myScreen.screenSizeY()));
119+
120+
Serial.println("Who Am I... ");
121+
myScreen.clear();
122+
displayPersistent();
123+
wait(2);
124+
125+
/*
126+
// To clear the screen
127+
myScreen.clear();
128+
myScreen.flush();
129+
*/
130+
131+
digitalWrite(LED_BUILTIN, HIGH);
132+
Serial.println("=== ");
133+
Serial.println();
134+
}
135+
136+
// Add loop code
137+
///
138+
/// @brief Loop, empty
139+
///
140+
void loop()
141+
{
142+
delay(1000);
143+
}

library.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
name=PDLS_EXT3_Basic_Global
2-
version=7.0.3
2+
version=7.0.4
33
author=Rei Vilo for Pervasive Displays
44
maintainer=Rei Vilo
55
sentence=Library for Pervasive Displays iTC monochrome and colour screens and EXT3-1 board

src/hV_Common.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
/// @n Based on highView technology
77
///
88
/// @author Rei Vilo
9-
/// @date 21 Nov 2023
10-
/// @version 702
9+
/// @date 21 Jan 2024
10+
/// @version 704
1111
///
1212
/// @copyright (c) Rei Vilo, 2010-2023
1313
/// @copyright All rights reserved
@@ -26,7 +26,7 @@
2626
///
2727
/// @brief Library release number
2828
///
29-
#define hV_COMMON_RELEASE 702
29+
#define hV_COMMON_RELEASE 704
3030

3131
// SDK
3232
#include "hV_HAL_Peripherals.h"

src/hV_Documentation.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@
4242
/// Additionally, the **[Wiki](https://docs.pervasivedisplays.com/)** provides a gradual introduction to the e-paper technology and how to use it.
4343
///
4444
/// @author Rei Vilo
45-
/// @date 21 Nov 2023
46-
/// @version 702
45+
/// @date 21 Jan 2024
46+
/// @version 704
4747
///
4848
/// @copyright &copy; Rei Vilo, 2010-2023
4949
/// @copyright All rights reserved

0 commit comments

Comments
 (0)