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

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [newlib-1.17.0/] [libgloss/] [mn10200/] [test.c] - Rev 318

Go to most recent revision | Compare with Previous | Blame | View Log

#include <stdio.h>
#include <string.h>
 
static void
send_msg1 (void)
{
  static char msg[] = "Hello World\r\n";
  write(1, msg, strlen (msg));
}
 
static void
send_msg2 (void)
{
  static char msg[] = "Goodnight Irene\r\n";
  write(1, msg, strlen (msg));
}
 
static void
delay (void)
{
  int i;
 
  for (i = 0; i < 32000; i++)
    ;
}
 
int
main(int argc, char *argv[])
{
  int i, j;
  for (i = 0; i < 10; i++)
    {
      send_msg1 ();
      delay ();
      send_msg2 ();
    }
  return 0;
}
 
 
 

Go to most recent revision | Compare with Previous | Blame | View Log

powered by: WebSVN 2.1.0

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