Project

General

Profile

Statistics
| Revision:

root / branches / simulator / projects / simulator / simulator / core / main.c @ 988

History | View | Annotate | Download (496 Bytes)

1
/**
2
 * @file main.c
3
 * @author Colony Project
4
 * @brief Initializes the program.
5
 *
6
 * Contains only the main function, which
7
 * initializes the program.
8
 **/
9

    
10
#include <stdlib.h>
11
#include <stdio.h>
12

    
13
#include "gtk_gui.h"
14
#include "robot.h"
15

    
16
int main(int argc, char** argv)
17
{
18
        if (robots_initialize())
19
                return -1;
20

    
21
        if(argc<=1){
22
                printf("Usage: simulator <robot execetuable>\n");
23
                exit(-1);
24
        }
25
        robot_create(argv[1]);
26

    
27
        printf("returned to parent\n");
28

    
29
        gtk_gui_run(argc, argv);
30

    
31
        return 0;
32
}
33