/[H8]/trunk/PIC/TCP-IP stack/main.c
ViewVC logotype

Diff of /trunk/PIC/TCP-IP stack/main.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 63 by hedin, Tue May 1 08:17:39 2007 UTC revision 64 by hedin, Tue May 1 13:47:27 2007 UTC
# Line 3  Line 3 
3    
4  #include "StackTsk.h"  #include "StackTsk.h"
5  #include "tick.h"  #include "tick.h"
6  #include "dhcp.h"  #include "Tcp.h"
7    
8  APP_CONFIG AppConfig;  APP_CONFIG AppConfig;
9    
10  void main()  int global_network_int;
11    char global_network_char;
12    
13    void network_send_hello( unsigned char termid)
14  {  {
15          while(1);  
16            switch(smState)
17            {
18                    case SM_CONNECT:
19                            Sock = TCPConnect(, 1234);
20                            if( Sock == INVALID_SOCKET ){
21                            return 1;
22                            }
23                            else
24                                    smState = SM_CONNECT_WAIT;
25                            return;
26                    case SM_CONNECT_WAIT:
27                            if( TCPISConnected(Sock) ){
28                                    smState = SM_CONNECTED;
29                            }
30                            return;
31            }
32  }  }
33  void network_send_hello( unsigned char termid)  
34    void main()
35  {  {
36                    TickInit();
37            StackInit();  // tcp,ud,mac,arp Init happends in StackInit();
38            while(1)
39            {
40                    TickUpdate();
41                    StackTask();
42                    TCPTick();
43            }
44  }  }

Legend:
Removed from v.63  
changed lines
  Added in v.64

  ViewVC Help
Powered by ViewVC 1.1.20