Skip to content

Commit

Permalink
Merge branch 'feat/remove_dependencies_on_unix' into 'master'
Browse files Browse the repository at this point in the history
feat(core): support compilation on non-Unix/Linux systems

Closes #10

See merge request ae_group/esp-brookesia!10
  • Loading branch information
Lzw655 committed Sep 25, 2024
2 parents 2b0d70f + 23a8d11 commit 5a31a27
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 5 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# ChangeLog

## v0.3.1 - 2024-09-25

### Enhancements:

* feat(core): support compilation on non-Unix/Linux systems

## v0.3.0 - 2024-09-23

### Enhancements:
Expand Down
2 changes: 1 addition & 1 deletion idf_component.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version: 0.3.0
version: 0.3.1
description: ESP-Brookesia is a human-machine interaction development framework designed for AIoT devices.
url: https://github.com/espressif/esp-brookesia
issues: https://github.com/espressif/esp-brookesia/issues
Expand Down
2 changes: 1 addition & 1 deletion library.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name=esp-brookesia
version=0.3.0
version=0.3.1
author=espressif
maintainer=espressif
sentence=ESP-Brookesia is a human-machine interaction development framework designed for AIoT devices.
Expand Down
7 changes: 5 additions & 2 deletions src/core/esp_brookesia_core_utils.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
*/
#include <stdio.h>
#include <stdlib.h>
#include <sys/param.h>
#include <time.h>
#include "esp_brookesia_conf_internal.h"
#include "esp_brookesia_core_utils.h"
Expand Down Expand Up @@ -39,7 +38,11 @@ bool esp_brookesia_core_utils_get_internal_font_by_size(uint8_t size_px, const l

uint8_t temp_size = size_px;
size_px = (size_px << 2) >> 2;
size_px = MIN(MAX(size_px, ESP_BROOKESIA_STYLE_FONT_SIZE_MIN), ESP_BROOKESIA_STYLE_FONT_SIZE_MAX);
if (size_px < ESP_BROOKESIA_STYLE_FONT_SIZE_MIN) {
size_px = ESP_BROOKESIA_STYLE_FONT_SIZE_MIN;
} else if (size_px > ESP_BROOKESIA_STYLE_FONT_SIZE_MAX) {
size_px = ESP_BROOKESIA_STYLE_FONT_SIZE_MAX;
}
if (temp_size != size_px) {
ESP_BROOKESIA_LOGW("Font size(%d) not support, use the nearest size(%d)", temp_size, size_px);
}
Expand Down
2 changes: 1 addition & 1 deletion src/esp_brookesia_versions.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#if !defined(ESP_BROOKESIA_VER_MAJOR) && !defined(ESP_BROOKESIA_VER_MINOR) && !defined(ESP_BROOKESIA_VER_PATCH)
#define ESP_BROOKESIA_VER_MAJOR 0
#define ESP_BROOKESIA_VER_MINOR 3
#define ESP_BROOKESIA_VER_PATCH 0
#define ESP_BROOKESIA_VER_PATCH 1
#endif

/* File `esp_brookesia_conf.h` */
Expand Down

0 comments on commit 5a31a27

Please sign in to comment.