feat(esp8266): Modify old system APIs to new ones

This commit is contained in:
Dong Heng
2018-06-25 16:30:38 +08:00
parent c5b9f8ed9d
commit bf0b8c8bb6
17 changed files with 40 additions and 36 deletions
components
esp8266
lwip/port/esp8266/include
newlib/newlib/port
spi_flash/src
ssl
axtls/source
mbedtls/port/openssl/include/platform
examples
get-started/project_template/main
protocols
mqtt/main
openssl_client/main
openssl_demo/main
openssl_server/main
storage/spiffs_test/main
wifi
smart_config/main
wifi_station_machine/main

@ -34,8 +34,6 @@
extern "C" {
#endif
uint32_t os_random(void);
int32_t os_get_random(unsigned char *buf, size_t len);
/**

@ -245,7 +245,7 @@ static uint32_t queue_msg_waiting_wrapper(void *queue)
static uint32_t get_free_heap_size_wrapper(void)
{
return (uint32_t)system_get_free_heap_size();
return (uint32_t)esp_get_free_heap_size();
}
static void *timer_create_wrapper(const char *name, uint32_t period_ticks, bool auto_load, void *arg, void (*cb)(void *timer))
@ -308,7 +308,7 @@ static void srand_wrapper(uint32_t seed)
static int32_t rand_wrapper(void)
{
return (int32_t)os_random();
return (int32_t)esp_random();
}
wifi_osi_funcs_t s_wifi_osi_funcs = {