Просмотр исходного кода

Merge branch 'fix/ram_example_fixes' into 'master'

fix: Fix RAM example build and add it to the CI for future

See merge request espressif/esp-serial-flasher!62
Roland Dobai 2 лет назад
Родитель
Сommit
5db9833658
3 измененных файлов с 4 добавлено и 2 удалено
  1. 2 0
      .gitlab-ci.yml
  2. 1 1
      examples/common/bin2array.cmake
  3. 1 1
      examples/esp32_load_ram_example/main/main.c

+ 2 - 0
.gitlab-ci.yml

@@ -34,6 +34,8 @@ variables:
     - cd $CI_PROJECT_DIR/examples/esp32_example
     - cd $CI_PROJECT_DIR/examples/esp32_example
     - idf.py build -DMD5_ENABLED=1
     - idf.py build -DMD5_ENABLED=1
     - idf.py build -DMD5_ENABLED=0
     - idf.py build -DMD5_ENABLED=0
+    - cd $CI_PROJECT_DIR/examples/esp32_load_ram_example
+    - idf.py build
 
 
 build_idf_v4.2:
 build_idf_v4.2:
   extends: .build_idf_template
   extends: .build_idf_template

+ 1 - 1
examples/common/bin2array.cmake

@@ -3,7 +3,7 @@ function(create_resources dir output)
     # Create empty output file
     # Create empty output file
     file(WRITE ${output} "#include <stdint.h>\n\n")
     file(WRITE ${output} "#include <stdint.h>\n\n")
     # Collect input files
     # Collect input files
-    file(GLOB_RECURSE bin_paths ${dir}/*)
+    file(GLOB bin_paths ${dir}/ESP*/*)
     # Iterate through input files
     # Iterate through input files
     foreach(bin ${bin_paths})
     foreach(bin ${bin_paths})
         # Get short filenames, by discarding relative path
         # Get short filenames, by discarding relative path

+ 1 - 1
examples/esp32_load_ram_example/main/main.c

@@ -28,7 +28,7 @@ static const char *TAG = "serial_ram_loader";
 
 
 // Max line size
 // Max line size
 #define BUF_LEN 128
 #define BUF_LEN 128
-static char buf[BUF_LEN] = {0};
+static uint8_t buf[BUF_LEN] = {0};
 
 
 void slave_monitor(void *arg)
 void slave_monitor(void *arg)
 {
 {