OpenCores
URL https://opencores.org/ocsvn/mlite/mlite/trunk

Subversion Repositories mlite

[/] [mlite/] [trunk/] [tools/] [etermip.c] - Diff between revs 242 and 269

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 242 Rev 269
Line 365... Line 365...
   unsigned int ticksLast = GetTickCount();
   unsigned int ticksLast = GetTickCount();
   int length;
   int length;
   unsigned char buf[80];
   unsigned char buf[80];
   DWORD count;
   DWORD count;
   unsigned int ticks;
   unsigned int ticks;
 
   int downloadSkip = 0;
   (void)argc;
   (void)argc;
   (void)argv;
   (void)argv;
 
 
   WinPcapInit();
   WinPcapInit();
#ifndef SIMULATE_PLASMA
#ifndef SIMULATE_PLASMA
   SerialOpen("COM1", 57600);
   SerialOpen("COM1", 57600);
 
   if(argc != 2 || strcmp(argv[1], "none"))
   SendFile();
   SendFile();
 
   else
 
      downloadSkip = 1;
#else
#else
   IPInit(EthernetSendPacket);
   IPInit(EthernetSendPacket);
   HtmlInit(1);
   HtmlInit(1);
   ConsoleInit();
   ConsoleInit();
#endif
#endif
Line 384... Line 388...
   {
   {
      // Read keypresses
      // Read keypresses
      while(kbhit())
      while(kbhit())
      {
      {
         buf[0] = (unsigned char)getch();
         buf[0] = (unsigned char)getch();
 
         if(downloadSkip && buf[0] == '`')
 
            SendFile();
         WriteFile(serial_handle, buf, 1, &count, NULL);
         WriteFile(serial_handle, buf, 1, &count, NULL);
      }
      }
 
 
      // Read UART
      // Read UART
      for(;;)
      for(;;)
Line 420... Line 426...
         ticksLast = ticks;
         ticksLast = ticks;
      }
      }
   }
   }
}
}
 
 
 No newline at end of file
 No newline at end of file
 
 
 No newline at end of file
 No newline at end of file

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.