#endif
}
-static inline esp_err_t esp_apptrace_lock_initialize(void)
+static inline esp_err_t esp_apptrace_lock_initialize(esp_apptrace_lock_t *lock)
{
#if CONFIG_ESP32_APPTRACE_LOCK_ENABLE
- esp_apptrace_lock_init(&s_trace_buf.lock);
+ esp_apptrace_lock_init(lock);
#endif
return ESP_OK;
}
case 2:
ESP_LOGI(TAG, "Factory");
TEST_ASSERT_EQUAL(ESP_PARTITION_SUBTYPE_APP_FACTORY, cur_app->subtype);
- copy_current_app_to_next_part_and_reboot(cur_app);
+ copy_current_app_to_next_part_and_reboot();
break;
case 3:
ESP_LOGI(TAG, "OTA0");
TEST_ASSERT_EQUAL(ESP_PARTITION_SUBTYPE_APP_OTA_0, cur_app->subtype);
mark_app_valid();
- copy_current_app_to_next_part_and_reboot(cur_app);
+ copy_current_app_to_next_part_and_reboot();
break;
case 4:
ESP_LOGI(TAG, "OTA1");
TEST_ASSERT_EQUAL(ESP_PARTITION_SUBTYPE_APP_OTA_1, cur_app->subtype);
mark_app_valid();
- copy_current_app_to_next_part_and_reboot(cur_app);
+ copy_current_app_to_next_part_and_reboot();
break;
case 5:
ESP_LOGI(TAG, "OTA0");
case 2:
ESP_LOGI(TAG, "Factory");
TEST_ASSERT_EQUAL(ESP_PARTITION_SUBTYPE_APP_FACTORY, cur_app->subtype);
- copy_current_app_to_next_part_and_reboot(cur_app);
+ copy_current_app_to_next_part_and_reboot();
break;
case 3:
ESP_LOGI(TAG, "OTA0");
case 2:
ESP_LOGI(TAG, "Factory");
TEST_ASSERT_EQUAL(ESP_PARTITION_SUBTYPE_APP_FACTORY, cur_app->subtype);
- copy_current_app_to_next_part_and_reboot(cur_app);
+ copy_current_app_to_next_part_and_reboot();
break;
case 3:
ESP_LOGI(TAG, "OTA0");
TEST_ASSERT_EQUAL(ESP_PARTITION_SUBTYPE_APP_OTA_0, cur_app->subtype);
mark_app_valid();
- copy_current_app_to_next_part_and_reboot(cur_app);
+ copy_current_app_to_next_part_and_reboot();
break;
case 4:
ESP_LOGI(TAG, "OTA1");
nvs_close(handle);
nvs_flash_deinit();
- copy_current_app_to_next_part_and_reboot(cur_app);
+ copy_current_app_to_next_part_and_reboot();
break;
case 3:
ESP_LOGI(TAG, "OTA0");
* @param slave_func ``ptest_func_t`` to be executed by slave.
*/
#define TEST_MASTER_SLAVE(name, param_group, tag, master_func, slave_func) \
- static void PTEST_MASTER_NAME(name) () { test_serializer(&PGROUP_NAME(param_group), master_func); } \
- static void PTEST_SLAVE_NAME(name) () { test_serializer(&PGROUP_NAME(param_group), slave_func); } \
+ static void PTEST_MASTER_NAME(name) (void) { test_serializer(&PGROUP_NAME(param_group), master_func); } \
+ static void PTEST_SLAVE_NAME(name) (void) { test_serializer(&PGROUP_NAME(param_group), slave_func); } \
TEST_CASE_MULTIPLE_DEVICES("master slave test: "#name, tag, PTEST_MASTER_NAME(name), PTEST_SLAVE_NAME(name))
char drv[3] = {(char)('0' + s_pdrv), ':', 0};
f_mount(0, drv, 0);
// release SD driver
- esp_err_t (*host_deinit)() = s_card->host.deinit;
+ esp_err_t (*host_deinit)(void) = s_card->host.deinit;
ff_diskio_unregister(s_pdrv);
free(s_card);
s_card = NULL;
#ifdef OPEN_WATCOM_INDUSTRIAL_PC_PORT
#include "..\..\Source\portable\owatcom\16bitdos\pc\portmacro.h"
- typedef void ( __interrupt __far *pxISR )();
+ typedef void ( __interrupt __far *pxISR )(void);
#endif
#ifdef OPEN_WATCOM_FLASH_LITE_186_PORT
#include "..\..\Source\portable\owatcom\16bitdos\flsh186\portmacro.h"
- typedef void ( __interrupt __far *pxISR )();
+ typedef void ( __interrupt __far *pxISR )(void);
#endif
#ifdef GCC_MEGA_AVR
FreeRTOSConfig.h when using the Borland compiler. */
#include "frconfig.h"
#include "..\portable\BCC\16BitDOS\PC\prtmacro.h"
- typedef void ( __interrupt __far *pxISR )();
+ typedef void ( __interrupt __far *pxISR )(void);
#endif
#ifdef BCC_FLASH_LITE_186_PORT
FreeRTOSConfig.h when using the Borland compiler. */
#include "frconfig.h"
#include "..\portable\BCC\16BitDOS\flsh186\prtmacro.h"
- typedef void ( __interrupt __far *pxISR )();
+ typedef void ( __interrupt __far *pxISR )(void);
#endif
#ifdef __GNUC__
#if ( portNUM_PROCESSORS > 1 )
- static BaseType_t xHaveReadyTasks()
+ static BaseType_t xHaveReadyTasks( void )
{
for (int i = tskIDLE_PRIORITY + 1; i < configMAX_PRIORITIES; ++i)
{
*((uint32_t *)ptr) = (TLSP_DEL_BASE << index); //Indicate deletion by setting task storage element to a unique value
}
-static void task_cb(void)
+static void task_cb(void *arg)
{
int core = xPortGetCoreID();
for(int i = 0; i < NO_OF_TLSP; i++){
static bool test_set_bits;
static bool test_clear_bits;
-static void IRAM_ATTR event_group_isr(void)
+static void IRAM_ATTR event_group_isr(void *arg)
{
portBASE_TYPE task_woken = pdFALSE;
TIMERG0.int_clr_timers.t0 = 1;
vTaskDelete(NULL);
}
-static void IRAM_ATTR sender_ISR (void)
+static void IRAM_ATTR sender_ISR (void *arg)
{
int curcore = xPortGetCoreID();
if(curcore == 0){ //Clear timer interrupt
#define TEST_CASE(name_, desc_) \
static void UNITY_TEST_UID(test_func_) (void); \
- static void __attribute__((constructor)) UNITY_TEST_UID(test_reg_helper_) () \
+ static void __attribute__((constructor)) UNITY_TEST_UID(test_reg_helper_) (void) \
{ \
static test_func test_fn_[] = {&UNITY_TEST_UID(test_func_)}; \
static test_desc_t UNITY_TEST_UID(test_desc_) = { \
#define TEST_CASE_MULTIPLE_STAGES(name_, desc_, ...) \
UNITY_TEST_FN_SET(__VA_ARGS__); \
- static void __attribute__((constructor)) UNITY_TEST_UID(test_reg_helper_) () \
+ static void __attribute__((constructor)) UNITY_TEST_UID(test_reg_helper_) (void) \
{ \
static test_desc_t UNITY_TEST_UID(test_desc_) = { \
.name = name_, \
#define TEST_CASE_MULTIPLE_DEVICES(name_, desc_, ...) \
UNITY_TEST_FN_SET(__VA_ARGS__); \
- static void __attribute__((constructor)) UNITY_TEST_UID(test_reg_helper_) () \
+ static void __attribute__((constructor)) UNITY_TEST_UID(test_reg_helper_) (void) \
{ \
static test_desc_t UNITY_TEST_UID(test_desc_) = { \
.name = name_, \
int (*get_ppkey) (uint8_t *ifx, int *alg, uint8_t *addr, int *key_idx,
uint8_t *key, size_t key_len, int key_entry_valid);
void (*wpa_deauthenticate)(u8 reason_code);
- void (*wpa_neg_complete)();
+ void (*wpa_neg_complete)(void);
struct wpa_gtk_data gd; //used for calllback save param
u16 key_info; //used for txcallback param
u16 txcb_flags;
typedef void (*WPA_DEAUTH_FUNC)(u8 reason_code);
-typedef void (*WPA_NEG_COMPLETE)();
+typedef void (*WPA_NEG_COMPLETE)(void);
void wpa_register(char * payload, WPA_SEND_FUNC snd_func, \
WPA_SET_ASSOC_IE set_assoc_ie_func, \
ble_mesh_register_node_cmd();
}
-int ble_mesh_register_node_cb(void)
+int ble_mesh_register_node_cb(int argc, char** argv)
{
ESP_LOGD(TAG, "enter %s\n", __func__);
ble_mesh_node_init();
return err;
}
-int ble_mesh_node_reset(void)
+int ble_mesh_node_reset(int argc, char** argv)
{
esp_err_t err;
ESP_LOGD(TAG, "enter %s\n", __func__);
register_ble_address();
}
-int bt_mac(void)
+int bt_mac(int argc, char** argv)
{
const uint8_t *mac = esp_bt_dev_get_address();
printf("+BTMAC:"MACSTR"\n", MAC2STR(mac));
.command = "btmac",
.help = "get BT mac address",
.hint = NULL,
- .func = (esp_console_cmd_func_t)&bt_mac,
+ .func = &bt_mac,
};
ESP_ERROR_CHECK(esp_console_cmd_register(&cmd));
}
ble_mesh_register_node_cmd();
}
-int ble_mesh_register_node_cb(void)
+int ble_mesh_register_node_cb(int argc, char** argv)
{
ESP_LOGD(TAG, "enter %s\n", __func__);
ble_mesh_node_init();
ESP_LOGD(TAG, "exit %s\n", __func__);
}
-int ble_mesh_provisioner_register(void)
+int ble_mesh_provisioner_register(int argc, char** argv)
{
ESP_LOGD(TAG, "enter %s \n", __func__);
// esp_ble_mesh_register_unprov_adv_pkt_callback(ble_mesh_prov_adv_cb);
/**
* @brief this is ISR handler function, here we check for interrupt that triggers rising edge on CAP0 signal and according take action
*/
-static void IRAM_ATTR isr_handler(void)
+static void IRAM_ATTR isr_handler(void *arg)
{
uint32_t mcpwm_intr_status;
capture evt;
* @brief RMT receiver demo, this task will print each received NEC data.
*
*/
-static void rmt_example_nec_rx_task(void)
+static void rmt_example_nec_rx_task(void *arg)
{
int channel = RMT_RX_CHANNEL;
nec_rx_init();
* @brief RMT transmitter demo, this task will periodically send NEC data. (100 * 32 bits each time.)
*
*/
-static void rmt_example_nec_tx_task(void)
+static void rmt_example_nec_tx_task(void *arg)
{
vTaskDelay(10);
nec_tx_init();
return txBytes;
}
-static void tx_task(void)
+static void tx_task(void *arg)
{
static const char *TX_TASK_TAG = "TX_TASK";
esp_log_level_set(TX_TASK_TAG, ESP_LOG_INFO);
}
}
-static void rx_task(void)
+static void rx_task(void *arg)
{
static const char *RX_TASK_TAG = "RX_TASK";
esp_log_level_set(RX_TASK_TAG, ESP_LOG_INFO);
#define BUF_SIZE (1024)
-static void echo_task(void)
+static void echo_task(void *arg)
{
/* Configure parameters of an UART driver,
* communication pins and install the driver */
static const char *TAG = "RS485_ECHO_APP";
// An example of echo test with hardware flow control on UART
-static void echo_task(void)
+static void echo_task(void *arg)
{
const int uart_num = ECHO_UART_PORT;
uart_config_t uart_config = {
static const char* TAG = "uart_select_example";
-static void uart_select_task(void)
+static void uart_select_task(void *arg)
{
uart_config_t uart_config = {
.baud_rate = 115200,
}
}
- uart1_deinit(uart_fd);
+ uart1_deinit();
vTaskDelete(NULL);
}