text stringlengths 1 9.98k | __index_level_0__ int64 0 4.17k |
|---|---|
//BaseType_t xPortInterruptedFromISRContext(void);
// Following functions seem to not be used in SMP:
//static inline UBaseType_t xPortSetInterruptMaskFromISR(void)
//static inline void vPortClearInterruptMaskFromISR(UBaseType_t prev_level)
// Following functions should have been removed according to
// docs/en/migr... | 2,687 |
/*
*/
/*
#ifndef _WAIT_FOR_EVENT_H_
#define _WAIT_FOR_EVENT_H_
#include
#include
struct event;
struct event * event_create(void);
void event_delete( struct event * );
bool event_wait( struct event * ev );
bool event_wait_timed( struct event * ev,
time_t ms );
void event_signal( struct even... | 2,688 |
/*
*/
#pragma once
#include "sdkconfig.h"
/* Macros used instead ofsetoff() for better performance of interrupt handler */
#if CONFIG_FREERTOS_USE_LIST_DATA_INTEGRITY_CHECK_BYTES
/*
pxTopOfStack (4) +
xStateListItem (28) +
xEventListItem (28) +
uxPriority (4)
*/
#define PORT_OFFSET_PX_STACK 0x40
#else
/*
pxTopOfSta... | 2,689 |
org WEB site. */
#define portTASK_FUNCTION_PROTO( vFunction, pvParameters ) void vFunction( void *pvParameters )
#define portTASK_FUNCTION( vFunction, pvParameters ) void vFunction( void *pvParameters )
// interrupt module will mask interrupt with priority less than threshold
#define RVHAL_EXCM_LEVEL ... | 2,689 |
..) CHOOSE_MACRO_VA_ARG(portENTER_CRITICAL_IDF, portENTER_CRITICAL_SMP __VA_OPT__(,) __VA_ARGS__)(__VA_ARGS__)
#define portEXIT_CRITICAL(...) CHOOSE_MACRO_VA_ARG(portEXIT_CRITICAL_IDF, portEXIT_CRITICAL_SMP __VA_OPT__(,) __VA_ARGS__)(__VA_ARGS__)
#else
#define portENTER_CRITICAL... | 2,689 |
..) CHOOSE_MACRO_VA_ARG(portYIELD_FROM_ISR_CHECK, portYIELD_FROM_ISR_NO_CHECK __VA_OPT__(,) __VA_ARGS__)(__VA_ARGS__)
#else
#define portYIELD_FROM_ISR(...) CHOOSE_MACRO_VA_ARG(portYIELD_FROM_ISR_CHECK, portYIELD_FROM_ISR_NO_CHECK, ##__VA_ARGS__)(__VA_ARGS__)
#endif
#define portYI... | 2,689 |
However, on single core, the IDF style
critical sections simply disable interrupts, thus we discard the lock and timeout arguments.
Note: The IDF Style critical sections are named differently to their counterparts present in the xtensa port as few IDF
examples such as esp_zigbee_gateway, when compiled for RISC-V targ... | 2,689 |
*/
return (threshold == 0);
#endif /* SOC_INT_CLIC_SUPPORTED */
/* when enter critical code, FreeRTOS will mask threshold to RVHAL_EXCM_LEVEL
#define portYIELD_WITHIN_API() esp_crosscore_int_send_yield(xPortGetCoreID())
// System
void vPortSetStackWatchpoint(void *pxStackStart);
... | 2,689 |
A lot of files implicitly pull in API through
portmacro.h. Therefore, we need to keep these headers around for now to allow the rest of IDF to compile.
[refactor-todo] Clean up ESP-IDF inclusion dependencies and add a inclusion check.
*/
#include
#include
#include
#include "esp_attr.h"
#include "esp_newlib.h"
#in... | 2,689 |
/*
*/
#include "sdkconfig.h"
#include "esp_assert.h"
#include "esp_heap_caps.h"
#include "freertos/idf_additions.h"
#if CONFIG_FREERTOS_ENABLE_TASK_SNAPSHOT
#include "esp_private/freertos_debug.h"
#endif /* CONFIG_FREERTOS_ENABLE_TASK_SNAPSHOT */
#include "esp_private/freertos_idf_additions_priv.h"
/**
*/
/* ... | 2,690 |
CONFIG_FREERTOS_SMP && ( configNUM_CORES > 1 ) ) */
/**/
#if ( !CONFIG_FREERTOS_SMP && ( configNUM_CORES > 1 ) )
/*
*/
void prvReleaseKernelLock( void )
{
/* We call the tasks.c critical section macro to release xKernelLock */
taskEXIT_CRITICAL( &xKernelLock );
}
#endif /* ( !CONFIG_FREE... | 2,690 |
*/
configASSERT( xCoreID != 0 );
/* Called by the portable layer each time a tick interrupt occurs
traceTASK_INCREMENT_TICK( xTickCount );
if( uxSchedulerSuspended[ xCoreID ] == ( UBaseType_t ) 0U )
{
/* We need take the kernel lock here as we are about to access
... | 2,690 |
= pdFALSE )
{
xSwitchRequired = pdTRUE;
}
else
{
mtCOVERAGE_TEST_MARKER();
}
}
#endif /* configUSE_PREEMPTION */
}
#if ( configUSE_TICK_HOOK == 1 )
{
... | 2,690 |
This function is just a wrapper around
#if ( ( configNUM_CORES > 1 ) && ( configUSE_CORE_AFFINITY == 1 ) )
{
/* Convert xCoreID into an affinity mask */
UBaseType_t uxCoreAffinityMask;
/* Bit shifting 1 ) && ( configUSE_CORE_AFFINITY == 1 ) ) */... | 2,690 |
pxNewTCB->pxStack = ( StackType_t * ) pvPortMallocStack( ( ( ( size_t ) usStackDepth ) * sizeof( StackType_t ) ) ); /*lint !e961 MISRA exception as the casts are only redundant for some ports. */
if( pxNewTCB->pxStack == NULL )
{
/* C... | 2,690 |
*/
pxNewTCB = ( TCB_t * ) pvPortMalloc( sizeof( TCB_t ) ); /*lint !e9087 !e9079 All values returned by pvPortMalloc() have at least the alignment required by the MCU's stack, and the first member of TCB_t is always a pointer to the task's stack. */
if( pxNewTCB != NULL )
... | 2,690 |
= 0 ) /*lint !e9029 !e731 Macro has been consolidated for readability reasons. */
{
/* Tasks can be created statically or dynamically, so note this
pxNewTCB->ucStaticallyAllocated = tskDYNAMICALLY_ALLOCATED_STACK_AND_TCB;
}
#endif /... | 2,690 |
This function is just a wrapper around
#if ( ( configNUM_CORES > 1 ) && ( configUSE_CORE_AFFINITY == 1 ) )
{
/* Convert xCoreID into an affinity mask */
UBaseType_t uxCoreAffinityMask;
/* Bit shifting 1 ) && ( configUSE_CORE_AFFINITY == 1 ) ) */... | 2,690 |
*/
}
#endif /* configASSERT_DEFINED */
if( ( pxTaskBuffer != NULL ) && ( puxStackBuffer != NULL ) )
{
/* The memory used for the task's TCB and stack are passed into this
pxNewTCB = ( TCB_t * ) pxTaskBuffer; /*lint !e740 !e9087 Unusual ca... | 2,690 |
Just return a core ID of 0 */
xReturn = 0;
}
#endif /* configNUM_CORES > 1 */
return xReturn;
}
/**/
#if ( ( !CONFIG_FREERTOS_SMP ) && ( INCLUDE_xTaskGetIdleTaskHandle == 1 ) )
TaskHandle_t xTaskGetIdleTaskHandleForCore( BaseType_t xCoreID )
{
/* If xTaskGetIdleTaskHandle() is ca... | 2,690 |
CONFIG_FREERTOS_SMP ) && ( ( INCLUDE_xTaskGetCurrentTaskHandle == 1 ) || ( configUSE_MUTEXES == 1 ) ) ) */
/**/
#if ( !CONFIG_FREERTOS_SMP && ( configGENERATE_RUN_TIME_STATS == 1 ) && ( INCLUDE_xTaskGetIdleTaskHandle == 1 ) )
configRUN_TIME_COUNTER_TYPE ulTaskGetIdleRunTimeCounterForCore( BaseType_t xCoreID )
... | 2,690 |
*/
ulTotalTime /= ( configRUN_TIME_COUNTER_TYPE ) 100;
/* Avoid divide by zero errors. */
if( ulTotalTime > ( configRUN_TIME_COUNTER_TYPE ) 0 )
{
/* For SMP, we need to take the kernel lock here as we are about
prvENTER_CRITICAL_SMP_ONLY( &xKernelLock );
... | 2,690 |
e961 MISRA exception as the casts are only redundant for some ports. */
}
/* If the task is in the blocked or suspended list we need do
if( listIS_CONTAINED_WITHIN( &( pxReadyTasksLists[ uxPriorityUsedOnEntry ] ), &( pxTCB->xStateListItem ) ) != p... | 2,690 |
= pxTCB->uxBasePriority )
{
uxBasePriorityUsedOnEntry = pxTCB->uxBasePriority;
pxTCB->uxBasePriority = pxSavedPriority->uxBasePriority;
/* Remember the task's current priority before attempting to
uxPriorityUsedOnEntry = px... | 2,690 |
e961 MISRA exception as the casts are only redundant for some ports. */
}
/* If the task is in the blocked or suspended list we need do
if( listIS_CONTAINED_WITHIN( &( pxReadyTasksLists[ uxPriorityUsedOnEntry ] ), &( pxTCB->xStateListItem ) ) != p... | 2,690 |
*/
TCB_t * pxCurTask = ( TCB_t * ) xTaskGetCurrentTaskHandle();
struct _reent * ret;
if( pxCurTask == NULL )
{
/* No task running. Return global struct. */
ret = _GLOBAL_REENT;
}
else
{
/* We have a currently executing task. R... | 2,690 |
= -1 && uxArrayNumFilled pxStack = pxStack;
}
else
{
/* The stack cannot be used as the TCB has not been created. Free it. */
heap_caps_free( pxStack );
}
}
else
{
pxNewTCB = NULL;
}
if( ... | 2,690 |
/*
*/
#pragma once
/*
*/
#include "sdkconfig.h"
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "freertos/queue.h"
#include "freertos/semphr.h"
#include "freertos/stream_buffer.h"
#include "freertos/message_buffer.h"
#include "freertos/event_groups.h"
#include "esp_heap_caps.h"
/* *INDENT-OFF* ... | 2,691 |
CONFIG_FREERTOS_SMP ) && ( INCLUDE_xTaskGetIdleTaskHandle == 1 ) )
/**
*/
TaskHandle_t xTaskGetIdleTaskHandleForCore( BaseType_t xCoreID );
#endif /* ( ( !CONFIG_FREERTOS_SMP ) && ( INCLUDE_xTaskGetIdleTaskHandle == 1 ) ) */
#if ( ( !CONFIG_FREERTOS_SMP ) && ( ( INCLUDE_xTaskGetCurrentTaskHandle == 1 ) || ( con... | 2,691 |
0. Please use xTaskGetCoreID() instead." ) ) )
BaseType_t xTaskGetAffinity( TaskHandle_t xTask )
{
return xTaskGetCoreID( xTask );
}
static inline __attribute__( ( always_inline, deprecated( "This function is deprecated and will be removed in ESP-IDF 6.0. Please use xTaskGetIdleTaskHandleForCore() instead." ) ) )
... | 2,691 |
/*
*/
#pragma once
#warning freertos/task_snapshot.h header is no longer used, and will be removed in future versions.
#include "esp_private/freertos_debug.h"
| 2,692 |
/*
*/
#pragma once
#include "sdkconfig.h"
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
/*
*/
/* *INDENT-OFF* */
#ifdef __cplusplus
extern "C" {
#endif
/* *INDENT-ON* */
/* Task Snapshot */
/**
*/
typedef struct xTASK_SNAPSHOT
{
void * pxTCB; /*! pxEndOfStack, stack grows lo... | 2,693 |
/*
*/
#pragma once
/*
*/
#include "sdkconfig.h"
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
/* *INDENT-OFF* */
#ifdef __cplusplus
extern "C" {
#endif
/* *INDENT-ON* */
/*
**/
/*
*/
#if ( !CONFIG_FREERTOS_SMP && ( configNUM_CORES > 1 ) )
/* Macros that use a critical section when building fo... | 2,694 |
CONFIG_FREERTOS_SMP && ( configNUM_CORES == 1 ) )
/* Macros that suspend the scheduler or disables interrupts when building for single-core */
#define prvENTER_CRITICAL_OR_SUSPEND_ALL( pxLock ) ( { vTaskSuspendAll(); ( void ) ( pxLock ); } )
#define prvEXIT_CRITICAL_OR_RESUME_ALL( pxLock ) xTaskResumeA... | 2,694 |
CONFIG_FREERTOS_SMP && ( configNUM_CORES == 1 ) ) */
/*
*/
#if ( !CONFIG_FREERTOS_SMP && ( configNUM_CORES > 1 ) )
void prvTakeKernelLock( void );
void prvReleaseKernelLock( void );
#endif /* ( !CONFIG_FREERTOS_SMP && ( configNUM_CORES > 1 ) ) */
#if ( CONFIG_FREERTOS_SMP && ( configNUM_CORES > 1 ) )
/**
... | 2,694 |
/*
*/
#pragma once
#include "touch_element/touch_element.h"
#include "touch_element/touch_button.h"
#include "touch_element/touch_slider.h"
#include "touch_element/touch_matrix.h"
#include "esp_pm.h"
#include "sdkconfig.h"
#ifdef __cplusplus
extern "C" {
#endif
#define TE_TAG "Touch Element"
#define TE_DEBUG_TAG "... | 2,695 |
< Touch channel sensitivity
touch_pad_t channel; //!< Touch channel number(index)
te_dev_type_t type; //!< Touch channel type TODO: need to refactor as te_class_type_t
te_dev_state_t state; //!< Touch channel current state
bool is_use_last_threshold;
} te_dev_t;
typedef enum... | 2,695 |
/*
*/
#pragma once
#include "touch_element/touch_element.h"
#ifdef __cplusplus
extern "C" {
#endif
/* General matrix button instance default configuration */
#define TOUCH_MATRIX_GLOBAL_DEFAULT_CONFIG() \
{ ... | 2,696 |
< Matrix button y-axis channels sensitivity array
uint8_t x_channel_num; //!< The number of channels in x-axis
uint8_t y_channel_num; //!< The number of channels in y-axis
} touch_matrix_config_t;
/**
*/
typedef enum {
TOUCH_MATRIX_EVT_ON_PRESS, //!< Matrix b... | 2,696 |
< Matrix button instance handle
typedef void(*touch_matrix_callback_t)(touch_matrix_handle_t, touch_matrix_message_t *, void *); //!< Matrix button callback type
/**
*/
esp_err_t touch_matrix_install(const touch_matrix_global_config_t *global_config);
/**
void touch_matrix_uninstall(void);
/**
*/
esp_err_t touch_m... | 2,696 |
/*
*/
#pragma once
#include "touch_element/touch_element.h"
#ifdef __cplusplus
extern "C" {
#endif
/* General slider instance default configuration */
#define TOUCH_SLIDER_GLOBAL_DEFAULT_CONFIG() \
{ \
... | 2,697 |
< Slider channel threshold divider
uint16_t filter_reset_time; //!< Slider position filter reset time (Unit is esp_timer callback tick)
uint16_t benchmark_update_time; //!< Slider benchmark update time (Unit is esp_timer callback tick)
uint8_t position_filter_size; //!... | 2,697 |
< Slider on Press event
TOUCH_SLIDER_EVT_ON_RELEASE, //!< Slider on Release event
TOUCH_SLIDER_EVT_ON_CALCULATION, //!< Slider on Calculation event
TOUCH_SLIDER_EVT_MAX
} touch_slider_event_t;
typedef uint32_t touch_slider_position_t; //!< Slider position data type
/**
*/
... | 2,697 |
/*
*/
#pragma once
#include "touch_element/touch_element.h"
#ifdef __cplusplus
extern "C" {
#endif
/* General button instance default configuration */
#define TOUCH_BUTTON_GLOBAL_DEFAULT_CONFIG() \
{ \
... | 2,698 |
< Button Release event
TOUCH_BUTTON_EVT_ON_LONGPRESS, //!< Button LongPress event
TOUCH_BUTTON_EVT_MAX
} touch_button_event_t;
/**
*/
typedef struct {
touch_button_event_t event; //!< Button event
} touch_button_message_t;
typedef touch_elem_handle_t touch_button_handle_t; //!< Button han... | 2,698 |
/*
*/
#pragma once
#include "driver/touch_sensor.h"
#ifdef __cplusplus
extern "C" {
#endif
/* General hardware & system default configuration */
/* Since those are important hardware and algorithm parameters, user should not change them before knowing all details*/
/* */
#define TOUCH_ELEM_GLOBAL_DEFAULT_CONFI... | 2,699 |
smooth_filter_mode = TOUCH_PAD_SMOOTH_IIR_2, \
.benchmark_filter_mode = TOUCH_PAD_FILTER_IIR_16, \
.sample_count = 500, \
.sleep_cycle = 0xf, \
.... | 2,699 |
< None event
#define TOUCH_ELEM_EVENT_ON_PRESS BIT(1) //!< On Press event
#define TOUCH_ELEM_EVENT_ON_RELEASE BIT(2) //!< On Release event
#define TOUCH_ELEM_EVENT_ON_LONGPRESS BIT(3) //!< On LongPress event
#define TOUCH_ELEM_EVENT_ON_CALCULATION ... | 2,699 |
< Touch sensor channel upper charge voltage attenuation (Diff voltage is upper - attenuation - lower)
touch_low_volt_t lower_voltage; //!< Touch sensor channel lower charge voltage
touch_pad_conn_type_t suspend_channel_polarity; //!< Suspend channel polarity (High Impedance State or GND)
... | 2,699 |
< Benchmark debounce count
uint8_t benchmark_calibration_threshold; //!< Benchmark calibration threshold
uint8_t benchmark_jitter_step; //!< Benchmark jitter filter step (This only works at while benchmark filter mode is jitter filter)
} touch_elem_hw_config_t;
/**
*/
typedef struc... | 2,699 |
} touch_elem_sleep_config_t;
/* */
typedef void *touch_elem_handle_t; //!< Touch element handle type
typedef uint32_t touch_elem_event_t; //!< Touch element event type
/**
*/
typedef enum {
TOUCH_ELEM_TYPE_BUTTON, //!< Touch element button
TOUCH_ELEM_TYPE_SLIDER, //!< Touch eleme... | 2,699 |
/*
*/
#pragma once
#include
#include
#include
#include "esp_err.h"
#include "esp_assert.h"
#ifdef __cplusplus
extern "C"
{
#endif
#define ESP_BOOTLOADER_DESC_MAGIC_BYTE (80) /*!< The magic byte for the esp_bootloader_desc structure that is in DRAM. */
/**
*/
typedef struct {
uint8_t magic_byte; /... | 2,700 |
/*
*/
#ifndef __COEXIST_I154_H__
#define __COEXIST_I154_H__
#ifdef CONFIG_SOC_IEEE802154_SUPPORTED
typedef enum {
IEEE802154_HIGH = 1,
IEEE802154_MIDDLE,
IEEE802154_LOW,
IEEE802154_IDLE,
IEEE802154_EVENT_MAX,
} ieee802154_coex_event_t;
void esp_coex_ieee802154_txrx_pti_set(ieee802154_coex_event_t... | 2,701 |
/*
*/
#ifndef __ESP_COEXIST_H__
#define __ESP_COEXIST_H__
#include
#include "esp_err.h"
#include "hal/gpio_types.h"
#ifdef __cplusplus
extern "C" {
#endif
#define EXTERNAL_COEXIST_WIRE_1 0
#define EXTERNAL_COEXIST_WIRE_2 1
#define EXTERNAL_COEXIST_WIRE_3 2
#define EXTERNAL_COEXIST_WIRE_4 3
/**
*/
typedef enum {
... | 2,702 |
/*
*/
#ifndef __ESP_COEXIST_INTERNAL_H__
#define __ESP_COEXIST_INTERNAL_H__
#include
#include "esp_coexist.h"
#include "private/esp_coexist_adapter.h"
#ifdef __cplusplus
extern "C" {
#endif
typedef enum {
COEX_PREFER_WIFI = 0,
COEX_PREFER_BT,
COEX_PREFER_BALANCE,
COEX_PREFER_NUM,
} coex_prefer_t;
... | 2,703 |
/*
*/
#ifndef __ESP_MODEM_WRAPPER_INTERNAL_H__
#define __ESP_MODEM_WRAPPER_INTERNAL_H__
#ifdef __cplusplus
extern "C" {
#endif
#include
#include
#include
bool esp_coex_common_env_is_chip_wrapper(void);
void * esp_coex_common_spin_lock_create_wrapper(void);
uint32_t esp_coex_common_int_disable_wrapper(void *wi... | 2,704 |
/*
*/
#ifndef __ESP_COEXIST_ADAPTER_H__
#define __ESP_COEXIST_ADAPTER_H__
#include
#ifdef __cplusplus
extern "C" {
#endif
#define COEX_ADAPTER_VERSION 0x00000002
#define COEX_ADAPTER_MAGIC 0xDEADBEAF
#define COEX_ADAPTER_FUNCS_TIME_BLOCKING 0xffffffff
typedef struct {
int32_t _version;
#if CONFIG_I... | 2,705 |
/*
*/
#ifndef _ESP_TRANSPORT_INTERNAL_H_
#define _ESP_TRANSPORT_INTERNAL_H_
#include "sys/time.h"
#include "esp_transport.h"
#include "sys/socket.h"
#include "sys/queue.h"
#include "esp_log.h"
#include "esp_tls.h"
#ifdef __cplusplus
extern "C" {
#endif
typedef int (*get_socket_func)(esp_transport_handle_t t);
/*... | 2,706 |
< Connect function of this transport */
io_read_func _read; /*!< Read */
io_func _write; /*!< Write */
trans_func _close; /*!< Close */
poll_func _poll_read; /*!< Poll and read */
poll_func _poll_write; /*!< Poll and write */
trans_func... | 2,706 |
= ESP_OK) { \
ESP_LOGE(TAG,"%s(%d): Expected ESP_OK; reported: %d", __FUNCTION__, __LINE__, _esp_transport_err_to_check); \
action; \
} \
}
/**
*/
struct timeval* esp_transpo... | 2,706 |
/*
*/
#pragma once
#include
#include "esp_transport.h"
#ifdef __cplusplus
extern "C" {
#endif
typedef enum socks_version_t {SOCKS4 = 4} socks_version_t;
typedef enum socks_transport_response_t {
// The following values correspond to transport operation
SOCKS_RESPONSE_TARGET_NOT_FOUND = 0xF0,
SOCKS_RES... | 2,707 |
/*
*/
#ifndef _ESP_TRANSPORT_WS_H_
#define _ESP_TRANSPORT_WS_H_
#include "esp_transport.h"
#include
#ifdef __cplusplus
extern "C" {
#endif
typedef enum ws_transport_opcodes {
WS_TRANSPORT_OPCODES_CONT = 0x00,
WS_TRANSPORT_OPCODES_TEXT = 0x01,
WS_TRANSPORT_OPCODES_BINARY = 0x02,
WS_TRANSPORT_OPCO... | 2,708 |
/*
*/
#ifndef _ESP_TRANSPORT_SSL_H_
#define _ESP_TRANSPORT_SSL_H_
#include "esp_transport.h"
#include "esp_tls.h"
#ifdef __cplusplus
extern "C" {
#endif
/**
*/
esp_transport_handle_t esp_transport_ssl_init(void);
/**
*/
void esp_transport_ssl_set_cert_data(esp_transport_handle_t t, const char *data, int len);
... | 2,709 |
< Allocate and initialize a TLS session */
ESP_TRANSPORT_SESSION_TICKET_SAVE, /*!< Save TLS session so it can be restored for the next handshake */
ESP_TRANSPORT_SESSION_TICKET_USE, /*!< Use already saved session to reconnect faster */
ESP_TRANSPORT_SESSION_TICKET_FREE /*!< Deallocate and d... | 2,709 |
/*
*/
#ifndef _ESP_TRANSPORT_H_
#define _ESP_TRANSPORT_H_
#include
#include
#ifdef __cplusplus
extern "C" {
#endif
/**
*/
typedef struct esp_transport_keepalive {
bool keep_alive_enable; /*!=0 Last captured socket errno
*/
int esp_transport_get_errno(esp_transport_handle_t t);
/**
*/
esp_e... | 2,710 |
/*
*/
#ifndef _ESP_TRANSPORT_TCP_H_
#define _ESP_TRANSPORT_TCP_H_
#include "esp_transport.h"
#include
#include
#ifdef __cplusplus
extern "C" {
#endif
/**
void esp_transport_tcp_set_keep_alive(esp_transport_handle_t t, esp_transport_keep_alive_t *keep_alive_cfg);
/**
*/
void esp_transport_tcp_set_interface_name... | 2,711 |
/*
*/
#ifndef _TCP_TRANSPORT_FIXTURES_H_
#define _TCP_TRANSPORT_FIXTURES_H_
/**
*/
enum expected_sock_option_types {
SOCK_OPT_TYPE_BOOL,
SOCK_OPT_TYPE_INT,
};
struct expected_sock_option {
int level;
int optname;
int optval;
enum expected_sock_option_types opttype;
};
/**
*/
void tcp_transp... | 2,712 |
/*
*/
#pragma once
#include "esp_transport.h"
int mock_connect(esp_transport_handle_t t, const char *host, int port, int timeout_ms);
int mock_close(esp_transport_handle_t t);
int mock_write(esp_transport_handle_t t, const char *buffer, int len, int timeout_ms);
int mock_read(esp_transport_handle_t t, char *b... | 2,713 |
/*
*/
#pragma once
#include
#include "hal/sdm_types.h"
#include "esp_err.h"
#ifdef __cplusplus
extern "C" {
#endif
/**
*/
typedef struct sdm_channel_t *sdm_channel_handle_t;
/**
*/
typedef struct {
int gpio_num; /*!< GPIO number */
sdm_clock_source_t clk_src; /*!< Clock source */
uint... | 2,714 |
/*
*/
#pragma once
void pthread_internal_local_storage_destructor_callback(TaskHandle_t handle);
extern portMUX_TYPE pthread_lazy_init_lock;
| 2,715 |
/*
*/
#pragma once
#include
#include "esp_err.h"
#include "freertos/FreeRTOSConfig.h"
#ifdef __cplusplus
extern "C" {
#endif
#ifndef PTHREAD_STACK_MIN
#define PTHREAD_STACK_MIN CONFIG_PTHREAD_STACK_MIN
#endif
/** pthread configuration structure that influences pthread creation */
typedef struct {
size_t s... | 2,716 |
/*
*/
#pragma once
#include "esp_err.h"
#include "sdkconfig.h"
#ifdef __cplusplus
extern "C" {
#endif
#define PSRAM_SIZE_2MB (2 * 1024 * 1024)
#define PSRAM_SIZE_4MB (4 * 1024 * 1024)
#define PSRAM_SIZE_8MB (8 * 1024 * 1024)
#define PSRAM_SIZE_16MB ... | 2,717 |
/*
*/
#pragma once
#include
#include
#include
#include "esp_err.h"
#ifdef __cplusplus
extern "C" {
#endif
/**
*/
esp_err_t esp_psram_init(void);
/**
*/
bool esp_psram_is_initialized(void);
/**
*/
size_t esp_psram_get_size(void);
#ifdef __cplusplus
}
#endif
| 2,718 |
/*
*/
#pragma once
#include "sdkconfig.h"
#if !CONFIG_IDF_TARGET_ESP32
#error esp_himem is only supported on ESP32
#else
#include
#include "esp_err.h"
#ifdef __cplusplus
extern "C" {
#endif
//Opaque pointers as handles for ram/range data
typedef struct esp_himem_ramdata_t *esp_himem_handle_t;
typedef struct esp... | 2,719 |
CONFIG_IDF_TARGET_ESP32
| 2,719 |
/*
*/
/**
*/
#pragma once
#include
#include "esp_err.h"
#include "sdkconfig.h"
#ifdef __cplusplus
extern "C" {
#endif
#if CONFIG_IDF_TARGET_ESP32
#define MMU_PAGE_SIZE 0x8000
#else
#define MMU_PAGE_SIZE 0x10000
#define MMU_PAGE_TO_BYTES(page_id) ((page_id) * MMU_PAGE_SIZ... | 2,720 |
/*
*/
#pragma once
#include
#include
#include "esp_err.h"
#ifdef __cplusplus
extern "C" {
#endif
/**
*/
uint8_t esp_psram_io_get_cs_io(void);
#ifdef __cplusplus
}
#endif
| 2,721 |
/*
*/
#pragma once
#include
#include
#include "esp_err.h"
#ifdef __cplusplus
extern "C" {
#endif
/**
*/
bool esp_psram_check_ptr_addr(const void *p);
/**
*/
esp_err_t esp_psram_extram_add_to_heap_allocator(void);
/**
*/
esp_err_t esp_psram_extram_reserve_dma_pool(size_t size);
/**
*/
bool esp_psram_extram... | 2,722 |
/*
*/
#pragma once
#include
#include
#include "esp_app_desc.h"
#include
#include "esp_event.h"
#include "esp_partition.h"
#ifdef __cplusplus
extern "C" {
#endif
ESP_EVENT_DECLARE_BASE(ESP_HTTPS_OTA_EVENT);
/**
*/
typedef enum {
ESP_HTTPS_OTA_START, /*!http_config`.
*/
esp_err_t esp_ht... | 2,723 |
/* Copyright Joyent, Inc. and other Node contributors. All rights reserved.
*/
#ifndef http_parser_h
#define http_parser_h
#ifdef __cplusplus
extern "C" {
#endif
/* Also update SONAME in the Makefile whenever you change these. */
#define HTTP_PARSER_VERSION_MAJOR 2
#define HTTP_PARSER_VERSION_MINOR 7
#define HTTP_PAR... | 2,724 |
The parser will
*/
typedef int (*http_data_cb) (http_parser*, const char *at, size_t length);
typedef int (*http_cb) (http_parser*);
/* Request Methods */
#define HTTP_METHOD_MAP(XX) \
XX(0, DELETE, DELETE) \
XX(1, GET, GET) \
XX(2, HEAD, HEAD) \
XX(3, ... | 2,724 |
6.1.2 */ \
XX(31, LINK, LINK) \
XX(32, UNLINK, UNLINK) \
enum http_method
{
#define XX(num, name, string) HTTP_##name = num,
HTTP_METHOD_MAP(XX)
#undef XX
};
enum http_parser_type { HTTP_REQUEST, HTTP_RESPONSE, HTTP_BOTH };
/* Flag values for http_parser.flags field */
enum fla... | 2,724 |
*/
unsigned int upgrade : 1;
/** PUBLIC **/
void *data; /* A pointer to get hook to the "connection" or "socket" object */
};
struct http_parser_settings {
http_cb on_message_begin;
http_data_cb on_url;
http_data_cb on_status;
http_data_cb on_header_field;
http_data_cb on_header_value;
htt... | 2,724 |
Returns number of parsed bytes. Sets
size_t http_parser_execute(http_parser *parser,
const http_parser_settings *settings,
const char *data,
size_t len);
/* If http_should_keep_alive() in the on_headers_complete or
*/
int http_should_k... | 2,724 |
*/
int http_body_is_final(const http_parser *parser);
#ifdef __cplusplus
}
#endif
#endif
| 2,724 |
/*
*/
#pragma once
#ifdef __cplusplus
extern "C" {
#endif
#include
#include
#include
#include "esp_err.h"
#include "usb_private.h"
#include "usb/usb_types_ch9.h"
// Macros & Types
// States
/**
*/
typedef enum {
HCD_PORT_STATE_NOT_POWERED, /**< The port is not powered */
HCD_PORT_STATE_DISCON... | 2,725 |
Or the previous event is no longer valid */
HCD_PORT_EVENT_CONNECTION, /**< A device has been connected to the port */
HCD_PORT_EVENT_DISCONNECTION, /**< A device disconnection has been detected */
HCD_PORT_EVENT_ERROR, /**< A port error has been detected. Port is now HCD_PORT_STATE_RECOVE... | 2,725 |
e., an IN packet has exceeded the endpoint's MPS) */
HCD_PIPE_EVENT_ERROR_STALL, /**< Pipe received a STALL response received */
} hcd_pipe_event_t;
// Commands
/**
*/
typedef enum {
HCD_PORT_CMD_POWER_ON, /**< Power ON the port */
HCD_PORT_CMD_POWER_OFF, /**< Power OFF the... | 2,725 |
Enqueued URBs are left untouched */
HCD_PIPE_CMD_FLUSH, /**< Can only be called when halted. Will cause all enqueued URBs to be canceled */
HCD_PIPE_CMD_CLEAR, /**< Causes a halted pipe to become active again. Any enqueued URBs will being executing.*/
} hcd_pipe_cmd_t;
// Object Types... | 2,725 |
/*
*/
#pragma once
#include
#include
#include "sdkconfig.h"
#include "esp_err.h"
#include "usb_private.h"
#include "usbh.h"
#ifdef __cplusplus
extern "C" {
#endif
// Types
/**
*/
typedef struct {
usb_proc_req_cb_t proc_req_cb; /**< Processing request callback */
void *proc_req_cb_arg... | 2,726 |
/*
*/
#pragma once
#include
#include
#include
#include
#include "usb/usb_types_ch9.h"
#include "usb/usb_types_stack.h"
#ifdef __cplusplus
extern "C" {
#endif
// Types
typedef struct {
uint8_t *data_buffer;
size_t data_buffer_size;
int num_bytes;
int actual_num_bytes;
uint32_t flags;
... | 2,727 |
e., Device default pipes)
bool usb_host_inflight; // Debugging variable, used to prevent re-submitting URBs already inflight
// Public transfer structure. Must be last due to variable length array
usb_transfer_t transfer;
};
typedef struct urb_s urb_t;
/**
*/
typedef enum {
USB_PROC_REQ_SOURCE_USBH = ... | 2,727 |
/*
*/
#pragma once
#include
#include
#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "hcd.h"
#include "usb/usb_types_ch9.h"
#include "usb/usb_types_stack.h"
#ifdef __cplusplus
extern "C" {
#endif
// Types
// Handles
/**
*/
typedef struct usbh_ep_handle_s *usbh_ep_handle_t;
// Events
... | 2,728 |
The URB can be dequeued */
USBH_EP_EVENT_ERROR_XFER, /**< The EP encountered excessive errors when transferring a URB i.e., three three consecutive transaction errors (e.g., no ACK, bad CRC etc) */
USBH_EP_EVENT_ERROR_URB_NOT_AVAIL, /**< The EP tried to execute a transfer but no URB was avai... | 2,728 |
Hub driver should respond with a USBH_HUB_EVENT_PORT_DISABLED */
USBH_HUB_REQ_PORT_RECOVER, /**< Request that the Hub driver recovers a particular port (occurs after a gone
device has been freed). */
} usbh_hub_req_t;
/**
*/
typedef enum {
USBH_EP_CMD_HALT, ... | 2,728 |
/*
*/
/*
Warning: The USB Host Library API is still a beta version and may be subject to change
*/
#pragma once
#include
#include "usb/usb_types_ch9.h"
#ifdef __cplusplus
extern "C" {
#endif
// Protocol Standard
/**
*/
typedef enum {
USB_SPEED_LOW = 0, /**< USB Low Speed (1.5 Mbit/s) */
... | 2,729 |
g. no response or CRC error) */
USB_TRANSFER_STATUS_TIMED_OUT, /**< The transfer failed due to a time out */
USB_TRANSFER_STATUS_CANCELED, /**< The transfer was canceled */
USB_TRANSFER_STATUS_STALL, /**< The transfer was stalled */
USB_TRANSFER_STATUS_OVERFLOW, /**< The transf... | 2,729 |
Control transfers should include the size of the setup packet.
Isochronous transfer should be the total transfer size of all packets.
For non-contro... | 2,729 |
Number of service periods (i.e., intervals) to transfer data buffer over. */
usb_isoc_packet_desc_t isoc_packet_desc[]; /**< Descriptors for each Isochronous packet */
};
/**
*/
#define USB_TRANSFER_FLAG_ZERO_PACK 0x01 /**< (For bulk OUT only). Indicates that a bulk OUT transfers should always te... | 2,729 |
/*
*/
/*
Warning: The USB Host Library API is still a beta version and may be subject to change
*/
#pragma once
#include
#include "freertos/FreeRTOS.h"
#include "esp_err.h"
#include "esp_intr_alloc.h"
// Include the other USB Host Library headers as well
#include "usb/usb_helpers.h"
#include "usb/usb_types_ch9.h"
... | 2,730 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.