source: soft/giet_vm/apps/numsplit/consumer.c @ 161

Last change on this file since 161 was 160, checked in by karaoui, 12 years ago

giet-vm new version

File size: 565 bytes
Line 
1#include "consumer_proto.h"
2
3
4FUNC(cons_func)
5{
6    srl_mwmr_t input = GET_MWMR(mwmr);
7    char buf[BUF_SIZE];
8    int i,x;
9    while(1)
10    {
11        srl_mwmr_read(input, (unsigned int*)buf, WORD_SIZE);//8*4
12        srl_log_printf (NONE, "Consumer : %s\n", buf);
13#ifdef FULL_PRINT
14        //srl_log_printf (NONE, "Consumer : ");
15        for(i=0; i<BUF_SIZE; i++)
16        {
17            srl_log_printf (NONE, "%c/", buf[i]);
18        }
19        srl_log_printf (NONE, "\n");
20#endif
21        //for ( x = rand()>>4 ; x > 0 ; x-- ) asm volatile ( "nop" );
22//#endif
23    }
24}
Note: See TracBrowser for help on using the repository browser.