This commit is contained in:
Carl-Benedikt Krüger 2011-08-02 16:16:53 +02:00
parent 3f738461d1
commit 07e6290581
2 changed files with 11 additions and 10 deletions

View file

@ -1301,7 +1301,7 @@ int mmnif_open()
/* calculate my own ip address from core number
* Note: core 1 is the router core
*/
IP4_ADDR(&gw, 192,168,4,254);
IP4_ADDR(&gw, 0,0,0,0);
IP4_ADDR(&ipaddr, 192,168,0,RCCE_ue() +1);
IP4_ADDR(&netmask, 255,255,255,0);

View file

@ -177,7 +177,7 @@ void srv_on_conn(ServerEventArgs* e)
kprintf("send with %f kb/s", ((float)i*sizeof(buff))/(tmp2-tmp1));
}
#define SHELLDEBUGPRINTF(x,...) kprintf(x,##__VA_ARGS__);
//#define SHELLDEBUGPRINTF(x,...) kprintf(x,##__VA_ARGS__);
void* server_task(void* e)
{
@ -322,7 +322,7 @@ void* client_task(void* e)
SHELLDEBUGPRINTF("Client is ready...");
while (
cli_ConnectTo(&cli,"192.168.0.2",5555,0));
cli_ConnectTo(&cli,"192.168.0.1",5555,0));
sleep(1);
cli_sendBuffer(&cli,"Hallo Welt",sizeof("Hallo Welt"));
@ -411,15 +411,16 @@ int test_init(void)
#if defined(CONFIG_LWIP) && defined(CONFIG_ROCKCREEK)
// shell_init(RCCE_ue());
shell_init(RCCE_ue());
// sleep(10);
// SHELLDEBUGPRINTF("hello World! I AM CORE NO. %d =) \n",RCCE_ue());
sleep(10);
SHELLDEBUGPRINTF("hello World! I AM CORE NO. %d =) \n",RCCE_ue());
if (!RCCE_ue())
create_kernel_task(NULL,server_task,NULL);
else
create_kernel_task(NULL,client_task,NULL);
if (RCCE_ue())
create_kernel_task(NULL,server_task,NULL);
else
create_kernel_task(NULL,client_task,NULL);
#endif
// create_kernel_task(NULL, foo, "Hello from foo1");