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

6panel #2

Open
wants to merge 24 commits into
base: main6
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,6 @@ jobs:
- name: Run clang-format style check for C/C++/Protobuf programs.
uses: jidicula/[email protected]
with:
clang-format-version: "14"
clang-format-version: "15"
check-path: "src"
exclude-regex: Fonts
33 changes: 24 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,23 @@
|--------|---------------------|---------------------|-----------------------
| CL | clear | None | CL
| BR | brightness | 0~100 | BR:60
| F | font type | font type | F:FreeMono9pt7b
| S | font size | size | S:2
| FT | font type | font type | FT:FreeMono9pt7b
| FT
| SZ | font size | size | SZ:2
| BG | background clor | red,green,blue | BG:255,0,0
| TC | text color | red,green,blue | TC:0,0,255
| CR | cursor | x,y | CR:10,20
| P | a string to print | string | P:Hello World
| I | a image to load | image name | I:smile.bmp
| GR | grid | | GR
| PT | print a string(left) | PT:Hello World
| PC | print a string(horizontal center) | PC:Hello\World
| SC | print a string(screen center) | SC:Hello\World
| IM | a image to load | image name | IM:smile.bmp
| CI | fill circle | x,y,radius,r,g,b | CI:x,y,radius,r,g,b
| RT | fill rectangle | x,y,w,h,r,g,b | CI:x,y,width,height,r,g,b
| FL | flush all command | -- | FL
| D | delay time | time ms | D:2000

| HP | string information | string | HP:46 or HP:SLOW
| DL | delay time | time ms | DL:2000
| FS | flash 4 rectangles | times,delay | FS:5,300 (5times, 300ms)

Type of Fonts
=============
Expand All @@ -31,16 +38,24 @@ CL;P:Hello;D:1000;CL;CR:10,20;P:World;D:2000;CL;
CL;I:sample1_96x64.bmp;D:2000;CL;CR:10,20;TC:0,255,0;P:Hello,World;D:1000;CL;
CL;CR:15,0;I:face2_96x64.bmp;D:3000;
```
; Get the width and height of a string
command - FT:FreeSerif12pt7b;HP:Hello
result - x=?,y=?,x1=?,y1=?,w=?,h=? (w: width, h:height)

Caution:
Users should be careful when fonts are changed.



### Code formatting

Instasll clang-format v14.0.0 or later.
Instasll clang-format v15.
```sh
clang-format -i src/* -style=file:.clang-format
clang-format -i src/*.* -style=file:.clang-format
```

For pre-commit, use the following:

```sh
clang-format -i src/* -style=file:.clang-format -n -Werror
clang-format -i src/*.* -style=file:.clang-format -n -Werror
```
Binary file added data/HappyFace_94x94.bmp
Binary file not shown.
Binary file added data/NormalFace_94x94.bmp
Binary file not shown.
Binary file added data/SadFace_94x94.bmp
Binary file not shown.
Binary file removed data/face2_96x64.bmp
Binary file not shown.
Binary file removed data/sample1_96x64.bmp
Binary file not shown.
15 changes: 11 additions & 4 deletions platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,19 @@
; Please visit documentation for the other options and examples
; https://docs.platformio.org/page/projectconf.html

[env:firebeetle32]

[env:esp32doit-devkit-v1]
platform = espressif32
board = firebeetle32
board = esp32doit-devkit-v1
framework = arduino
lib_deps = adafruit/Adafruit GFX Library@^1.11.3

upload_port = COM3
monitor_port = COM3
; [env:firebeetle32]
; platform = espressif32
; board = firebeetle32
; framework = arduino
; lib_deps = adafruit/Adafruit GFX Library@^1.11.3

upload_port = COM6
monitor_port = COM6
monitor_speed = 115200
Loading