IDF release/v4.4 b8050b365e (#6594)

This commit is contained in:
Me No Dev
2022-04-20 12:23:18 +03:00
committed by GitHub
parent d3340837c7
commit 45b7fa05b6
109 changed files with 396 additions and 93 deletions

View File

@ -23,7 +23,7 @@ extern "C" {
/** Minor version number (x.X.x) */
#define ESP_IDF_VERSION_MINOR 4
/** Patch version number (x.x.X) */
#define ESP_IDF_VERSION_PATCH 0
#define ESP_IDF_VERSION_PATCH 1
/**
* Macro to convert IDF version number into an integer

View File

@ -63,6 +63,10 @@ uint8_t regi2c_ctrl_read_reg_mask(uint8_t block, uint8_t host_id, uint8_t reg_ad
void regi2c_ctrl_write_reg(uint8_t block, uint8_t host_id, uint8_t reg_add, uint8_t data);
void regi2c_ctrl_write_reg_mask(uint8_t block, uint8_t host_id, uint8_t reg_add, uint8_t msb, uint8_t lsb, uint8_t data);
/* enter the critical section that protects internal registers. Don't use it in SDK. Use the functions above. */
void regi2c_enter_critical(void);
void regi2c_exit_critical(void);
#endif // BOOTLOADER_BUILD
/* Convenience macros for the above functions, these use register definitions

View File

@ -1,24 +1,9 @@
#ifndef ESP_LITTLEFS_H__
#define ESP_LITTLEFS_H__
#include <stdint.h>
#include <stddef.h>
#include <stdarg.h>
#include <unistd.h>
#include <utime.h>
#include "freertos/FreeRTOS.h"
#include "freertos/semphr.h"
#include "esp_err.h"
#include <sys/types.h>
#include <sys/reent.h>
#include <sys/stat.h>
#include <sys/time.h>
#include <sys/poll.h>
#include <sys/dirent.h>
#include <string.h>
#include "sdkconfig.h"
#include "littlefs/lfs.h"
#include "sdkconfig.h"
#ifdef __cplusplus
extern "C" {

View File

@ -154,6 +154,10 @@ typedef enum {
ESP_RMAKER_REQ_SRC_CLOUD,
/** Request received when a schedule has triggered */
ESP_RMAKER_REQ_SRC_SCHEDULE,
/** Request received when a scene has been activated */
ESP_RMAKER_REQ_SRC_SCENE_ACTIVATE,
/** Request received when a scene has been deactivated */
ESP_RMAKER_REQ_SRC_SCENE_DEACTIVATE,
/** Request received from a local controller */
ESP_RMAKER_REQ_SRC_LOCAL,
/** This will always be the last value. Any value equal to or

View File

@ -0,0 +1,38 @@
// Copyright 2022 Espressif Systems (Shanghai) PTE LTD
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
#pragma once
#ifdef __cplusplus
extern "C"
{
#endif
#include <esp_err.h>
/** Enable Scenes
*
* This API enables the scenes service for the node. For more information,
* check [here](https://rainmaker.espressif.com/docs/scenes.html)
*
* @note This API should be called after esp_rmaker_node_init() but before esp_rmaker_start().
*
* @return ESP_OK on success.
* @return error in case of failure.
*/
esp_err_t esp_rmaker_scenes_enable(void);
#ifdef __cplusplus
}
#endif

View File

@ -45,6 +45,7 @@ extern "C"
#define ESP_RMAKER_DEF_TIMEZONE_NAME "TZ"
#define ESP_RMAKER_DEF_TIMEZONE_POSIX_NAME "TZ-POSIX"
#define ESP_RMAKER_DEF_SCHEDULE_NAME "Schedules"
#define ESP_RMAKER_DEF_SCENES_NAME "Scenes"
#define ESP_RMAKER_DEF_REBOOT_NAME "Reboot"
#define ESP_RMAKER_DEF_FACTORY_RESET_NAME "Factory-Reset"
#define ESP_RMAKER_DEF_WIFI_RESET_NAME "Wi-Fi-Reset"
@ -265,6 +266,20 @@ esp_rmaker_param_t *esp_rmaker_timezone_posix_param_create(const char *param_nam
*/
esp_rmaker_param_t *esp_rmaker_schedules_param_create(const char *param_name, int max_schedules);
/**
* Create standard Scenes param
*
* This will create the standard scenes parameter. Default value
* is set internally.
*
* @param[in] param_name Name of the parameter
* @param[in] max_scenes Maximum number of scenes allowed
*
* @return Parameter handle on success.
* @return NULL in case of failures.
*/
esp_rmaker_param_t *esp_rmaker_scenes_param_create(const char *param_name, int max_scenes);
/**
* Create standard Reboot param
*

View File

@ -71,6 +71,24 @@ esp_rmaker_device_t *esp_rmaker_time_service_create(const char *serv_name, const
*/
esp_rmaker_device_t *esp_rmaker_create_schedule_service(const char *serv_name, esp_rmaker_device_write_cb_t write_cb, esp_rmaker_device_read_cb_t read_cb, int max_schedules, void *priv_data);
/** Create a standard Scenes service
*
* This creates a Scenes service with the mandatory parameters. The default parameter names will be used.
* Refer \ref esp_rmaker_standard_params.h for default names.
*
* @param[in] serv_name The unique service name
* @param[in] write_cb Write callback.
* @param[in] read_cb Read callback.
* @param[in] max_scenes Maximum number of scenes supported.
* @param[in] deactivation_support Deactivation callback support.
* @param[in] priv_data (Optional) Private data associated with the service. This should stay
* allocated throughout the lifetime of the service.
*
* @return service_handle on success.
* @return NULL in case of any error.
*/
esp_rmaker_device_t *esp_rmaker_create_scenes_service(const char *serv_name, esp_rmaker_device_write_cb_t write_cb, esp_rmaker_device_read_cb_t read_cb, int max_scenes, bool deactivation_support, void *priv_data);
/** Create a standard System service
*
* This creates an empty System service. Appropriate parameters should be added by the caller.

View File

@ -44,6 +44,7 @@ extern "C"
#define ESP_RMAKER_PARAM_TIMEZONE "esp.param.tz"
#define ESP_RMAKER_PARAM_TIMEZONE_POSIX "esp.param.tz_posix"
#define ESP_RMAKER_PARAM_SCHEDULES "esp.param.schedules"
#define ESP_RMAKER_PARAM_SCENES "esp.param.scenes"
#define ESP_RMAKER_PARAM_REBOOT "esp.param.reboot"
#define ESP_RMAKER_PARAM_FACTORY_RESET "esp.param.factory-reset"
#define ESP_RMAKER_PARAM_WIFI_RESET "esp.param.wifi-reset"
@ -63,6 +64,7 @@ extern "C"
#define ESP_RMAKER_SERVICE_OTA "esp.service.ota"
#define ESP_RMAKER_SERVICE_TIME "esp.service.time"
#define ESP_RMAKER_SERVICE_SCHEDULE "esp.service.schedule"
#define ESP_RMAKER_SERVICE_SCENES "esp.service.scenes"
#define ESP_RMAKER_SERVICE_SYSTEM "esp.service.system"
#define ESP_RMAKER_SERVICE_LOCAL_CONTROL "esp.service.local_control"

View File

@ -19,7 +19,7 @@ extern "C" {
#endif
typedef enum {
FB_RGB888, FB_BGR888, FB_RGB565, FB_BGR565
FB_RGB888, FB_BGR888, FB_RGB565, FB_BGR565, FB_GRAY
} fb_format_t;
typedef struct {