chipKIT® Development Platform

Inspired by Arduino™

ChipKit network library - error running

Created Thu, 18 Jul 2013 02:29:14 +0000 by ferrcol


ferrcol

Thu, 18 Jul 2013 02:29:14 +0000

hi! I have the chipkit uno 32 and an ENC28J60 Ethernet module. The only code I found is:

http://sourceforge.net/projects/chipkitnetwork/

but, when i compile in mpide 0023 for windows, it don't work. The results are:

D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: WebServer.cpp.elf section .bss' will not fit in region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa00133f8 of WebServer.cpp.elf section .heap' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa0013bf8 of WebServer.cpp.elf section .stack' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa0014000 of WebServer.cpp.elf section .ramfunc' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa00133f8 of WebServer.cpp.elf section .heap' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa0013bf8 of WebServer.cpp.elf section .stack' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa0014000 of WebServer.cpp.elf section .ramfunc' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: region `kseg1_data_mem' overflowed by 65536 bytes collect2: ld returned 1 exit status

I don't know why, I'm beginner in Arduino IDE. Can you help me? Sorry for my bad English too.


majenko

Thu, 18 Jul 2013 16:29:01 +0000

That'll be my code then ;)

The Uno32 isn't big enough to run the default code. You have to cut it down in size a little by adjusting the sizes and numbers of buffers.

Edit the file include/settings.h and reduce some of the numbers in there.

You can reduce INTERFACES to 1 if you only have one ENC chip. MAX_PORTS can be taken down from 10 to something more in line with what you are doing (most people only need 1 port).

Try those to begin with.

The thing with Ethernet is it's a pretty memory hungry system - each packet can be up to 1500 bytes in size, and you need to have enough room to buffer packets as they come in so you don't miss any.


ferrcol

Thu, 18 Jul 2013 18:07:43 +0000

thanks for the reply, I edited settings.h... MAX_INTERFACES to 1 and MAX_PORT to 1. But it give the same error.

D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: WebServer.cpp.elf section .bss' will not fit in region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa00133f8 of WebServer.cpp.elf section .heap' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa0013bf8 of WebServer.cpp.elf section .stack' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa0014000 of WebServer.cpp.elf section .ramfunc' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa00133f8 of WebServer.cpp.elf section .heap' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa0013bf8 of WebServer.cpp.elf section .stack' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: address 0xa0014000 of WebServer.cpp.elf section .ramfunc' is not within region kseg1_data_mem' D:/mpide-0023-windows-20130626/hardware/pic32/compiler/pic32-tools/bin/../lib/gcc/pic32mx/4.5.1/../../../../pic32mx/bin/ld.exe: region `kseg1_data_mem' overflowed by 65536 bytes collect2: ld returned 1 exit status

I lowered ETH_BUF_SIZE to 1, ETH_DATA_LEN to 150 and TCP_BUF_SIZE to 480, but nothing.

Did you work with this library? or if any person know of that?


majenko

Thu, 18 Jul 2013 18:32:41 +0000

I wrote the library while on a wet holiday in Wales :P

It's really aimed at the '795 chip on the MAX32 which has 128KB of RAM.

I have just compiled the WebServer example sketch with the following settings:

#define ETH_BUF_SIZE 1
#define ETH_DATA_LEN 1500
#define TCP_BUF_SIZE 1500
#define MAX_PORTS 1
#define MAX_INTERFACES 1
#define MAX_ARP 10
#define MAX_TCP_CONNECTIONS 1
#define MAX_WEB_PAGES 20
#define MAX_GET_OPTIONS 20

I don't have a board to hand to test it with though, so I don't know how well it'll work.


ferrcol

Thu, 18 Jul 2013 21:51:06 +0000

So, if I go to Wales will work... great idea!

Now, I tested these settings, but it didn't work in UNO32 board, in MAX32 board the code compile fine.

Maybe the ide, I actually use the mpide 0023 (20130626) for windows. Can it be that?