Coder Social home page Coder Social logo

martin-ger / esp-open-lwip Goto Github PK

View Code? Open in Web Editor NEW

This project forked from pfalcon/esp-open-lwip

65.0 65.0 25.0 782 KB

ESP8266 lwIP library with NAT, SLIP, ENC28j60 Ethernet, and routing support

Makefile 0.81% C 98.09% Batchfile 0.19% Shell 0.20% C++ 0.71%
enc28j60 esp8266 napt nat routing-tables slip tunif

esp-open-lwip's People

Contributors

0hax avatar indesign-llc avatar martin-ger avatar pfalcon avatar st0ff3r avatar xxxajk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

esp-open-lwip's Issues

WiFi not working with new lwip stack.

Hi,
I integrated the lwip stack for ehternet and find that the stack is working for Ethernet. However I am not able to start the wifi stack. Is there an issue for wifi with this stack?

regards,
Rajkumar

building with MEM_USE_POOLS=1

anyone succeed in building with MEM_USE_POOLS=1 to avoid memory fragmentation?

tried to removed attr/DMEM_ATTR parameters in meme_std.h and creating a lwippools.h with:

#if MEM_USE_POOLS
LWIP_MALLOC_MEMPOOL_START
LWIP_MALLOC_MEMPOOL(100, 256)
LWIP_MALLOC_MEMPOOL(50, 512)
LWIP_MALLOC_MEMPOOL(20, 1024)
LWIP_MALLOC_MEMPOOL(20, 1536)
LWIP_MALLOC_MEMPOOL_END
#endif /* MEM_USE_POOLS */

but still get error when compiling:

In file included from lwip/core/memp.c:141:0:
include/lwip/memp_std.h:42:1: error: initializer element is not constant
LWIP_MEMPOOL(TCP_PCB, MEMP_NUM_TCP_PCB, sizeof(struct tcp_pcb), "TCP_PCB")
^
include/lwip/memp_std.h:42:1: error: (near initialization for 'memp_num[2]')
lwip/core/memp.c:160:47: error: variably modified 'memp_memory_TCP_PCB_base' at file scope
#define LWIP_MEMPOOL(name,num,size,desc) u8_t memp_memory_ ## name ## _base
^
include/lwip/memp_std.h:42:1: note: in expansion of macro 'LWIP_MEMPOOL'
LWIP_MEMPOOL(TCP_PCB, MEMP_NUM_TCP_PCB, sizeof(struct tcp_pcb), "TCP_PCB")
^

think I don't quite understand how the LWIP_MEMPOOL macro stuff works

any clues?

How to call TUNIF interface's functions?

When I include #include "netif/tunif.h"
and try to call some funtions such as

tunif_add_dns(134744072); // ip 8.8.8.8

It occurs some errors like

 tunif.c:(.text+0x70): undefined reference to `event_add'
 tunif.c:(.text+0x94): undefined reference to `event_add'
 tunif.c:(.text+0xc4): undefined reference to `event_del'
 tunif.c:(.text+0xc8): undefined reference to `event_free'
 tunif.c:(.text+0xdb): undefined reference to `event_del'
 tunif.c:(.text+0xe4): undefined reference to `event_free'
 

redirect devices to specific website

I understand that there is some routing happening on the ESP.
what I want to do now is to always route the devices connected to the ESP NAT to a specific website.

how can this be achieved ?

The UDP stack

Hello,

I have installed this library in my project using the ESP-NONOS-SDK-v2.2.0. However, the UDP part is not working. I am initializing the espconn structure with the UDP configured and then i am calling espconn_create(...).
Everything was working nice with the old library i add (got from pfalcon) but now nothing happens. I can't send nor receive anything in UDP. Is there some things i have forgotten to call or init or has changed in this project?

I have also some troubles relatives to the TCP stack but i think it is mostly because this library doesn't have an ssl stack, am i right? And i want secure connection.

Clancys

I'd like to use this in my PlatformIO project.

I can get everything to compile to the liblwip_open.a file but can't seem to find where I need to put it to have it compiled into my firmware. I tried replacing the liblwip_gcc.a in the ".platformio/packages/framework-arduinoespressif8266/tools/sdk/lib" folder. (This liblwip_open.a is much smaller for some reason.) . But that didn't work. I've been searching but have not found a solution yet.

Any help would be greatly appreciated.

Error when trying to build

I cloned the rep and then run make. Got the following error
esp-open-lwip$ make
make: Nothing to be done for 'FORCE'.
Any idea what is wrong ?
Thanks in advance

wifi_set_opmode_current(STATIONAP_MODE) leaking memory

reposting this:

I found out it was fixed by setting LWIP_HAVE_LOOPIF=0 and LWIP_HAVE_SLIPIF=0 but I had to disable content of lwip/netif/espenc.c in order to get it to compile without errors

using latest sdk 992479e from master branch, it appears that wifi_set_opmode_current(STATIONAP_MODE) is leaking memory:

wifi_set_opmode_current(NULL_MODE);

[...]

if (wifi_get_opmode() != STATIONAP_MODE) {
printf("HEAP1=%u\n\r", system_get_free_heap_size());
wifi_set_opmode_current(STATIONAP_MODE);
printf("HEAP2=%u\n\r", system_get_free_heap_size());
}

HEAP1=24888
mode : sta(ec:fa:bc:21:27:94) + softAP(ee:fa:bc:21:27:94)
4010b0b0 already freed
add if0
add if1
dhcp server start:(ip:10.0.5.1,mask:255.255.255.0,gw:10.0.5.1)
bcn 100
3fff7720 already freed
HEAP2=21472

How to fix the esp-open-lwip's compile-error?

I have already built the esp-open-sdk's toolchain , it looks fine.
When compiling the example's blinky, it's ok.

However when I tried to compile this repo esp-open-lwip,
it occurs some errors as the following..

image

I don't know much about Makefile.
How to fix this error for compiling this repo's esp-open-lwip ?

Thank you very much.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.