From f1552605d9b87aaee349f5e668cc61343d93a14a Mon Sep 17 00:00:00 2001 From: Johny Mattsson Date: Thu, 1 Oct 2015 15:20:53 +1000 Subject: [PATCH] Change os_update_cpu_freq... to ets_update_cpu_freq... Again, the os_xxx version has been removed from the SDK. --- app/modules/node.c | 4 ++-- app/ssl/app/espconn_ssl.c | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/app/modules/node.c b/app/modules/node.c index 65438cde..f21de4a4 100644 --- a/app/modules/node.c +++ b/app/modules/node.c @@ -410,10 +410,10 @@ static int node_setcpufreq(lua_State* L) uint32_t new_freq = luaL_checkinteger(L, 1); if (new_freq == CPU160MHZ){ REG_SET_BIT(0x3ff00014, BIT(0)); - os_update_cpu_frequency(CPU160MHZ); + ets_update_cpu_frequency(CPU160MHZ); } else { REG_CLR_BIT(0x3ff00014, BIT(0)); - os_update_cpu_frequency(CPU80MHZ); + ets_update_cpu_frequency(CPU80MHZ); } new_freq = ets_get_cpu_frequency(); lua_pushinteger(L, new_freq); diff --git a/app/ssl/app/espconn_ssl.c b/app/ssl/app/espconn_ssl.c index 860db844..d73a19af 100644 --- a/app/ssl/app/espconn_ssl.c +++ b/app/ssl/app/espconn_ssl.c @@ -440,7 +440,7 @@ espconn_ssl_crecv(void *arg, struct tcp_pcb *pcb, struct pbuf *p, err_t err) pssl->quiet = true; os_printf("client handshake ok!\n"); REG_CLR_BIT(0x3ff00014, BIT(0)); - os_update_cpu_frequency(80); + ets_update_cpu_frequency(80); precv->pespconn->state = ESPCONN_CONNECT; precv->pcommon.pcb = pcb; pbuf_free(p); @@ -613,7 +613,7 @@ espconn_ssl_connect(void *arg, struct tcp_pcb *tpcb, err_t err) } REG_SET_BIT(0x3ff00014, BIT(0)); - os_update_cpu_frequency(160); + ets_update_cpu_frequency(160); os_printf("client handshake start.\n"); pssl->quiet = false; pssl->ssl_ctx = ssl_ctx_new(options, SSL_DEFAULT_CLNT_SESS); @@ -794,7 +794,7 @@ espconn_ssl_ssent(void *arg, struct tcp_pcb *pcb, u16_t len) pssl->quiet = true; os_printf("server handshake ok!\n"); REG_CLR_BIT(0x3ff00014, BIT(0)); - os_update_cpu_frequency(80); + ets_update_cpu_frequency(80); psent->pespconn->state = ESPCONN_CONNECT; if (psent->pespconn->proto.tcp->connect_callback != NULL) { @@ -1043,7 +1043,7 @@ espconn_ssl_accept(void *arg, struct tcp_pcb *pcb, err_t err) } REG_SET_BIT(0x3ff00014, BIT(0)); - os_update_cpu_frequency(160); + ets_update_cpu_frequency(160); os_printf("server handshake start.\n"); pssl->quiet = false; pssl->ssl_ctx = ssl_ctx_new(SSL_DISPLAY_CERTS, SSL_DEFAULT_SVR_SESS);