I'm trying to setup a tcp server on the ESP8266, but I always get a error with the "proto.udp"
invalid type argument of '->' (have 'struct espconn')
Any idea ?
Jannik Jung
Explore... Chat... Share...
invalid type argument of '->' (have 'struct espconn')
#include "espconn.h"
#include "mem.h"
#include "user_interface.h"
static struct espconn *pUdpServer;
void user_init(void)
{
pUdpServer = (struct espconn *)os_zalloc(sizeof(struct espconn));
ets_memset( pUdpServer, 0, sizeof( struct espconn ) );
espconn_create( pUdpServer );
pUdpServer->type = ESPCONN_UDP;
pUdpServer->proto.udp = (esp_udp *)os_zalloc(sizeof(esp_udp));
pUdpServer->proto.udp->local_port = 7777;
espconn_regist_recvcb(pUdpServer, udpserver_recv);
if( espconn_create( pUdpServer ) )
{
while(1) ;
}
}
It takes about 20-25 seconds for home assistant c[…]
I tried to upgrade tof my sonoff basic R2 with the[…]
a problem Perhaps you want to define "Probl[…]
Rebooting your router will not give you a faster I[…]
There are no other notifications from esptool.py i[…]
Using the Arduino IDE, you'll learn how to set up […]
In this project, you will post to Twitter using an[…]
In this project, we will build a water level contr[…]
I guess I'm late, but I had the same problem and f[…]
Last night I received my first D1 Minis for a lear[…]
Although I am aware that this is an old post, I fe[…]