first commit
[clinton/Smoothieware.git] / src / main.cpp
CommitLineData
4cff3ded
AW
1/*
2 This file is part of Smoothie (http://smoothieware.org/). The motion control part is heavily based on Grbl (https://github.com/simen/grbl).
3 Smoothie is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
4 Smoothie is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
5 You should have received a copy of the GNU General Public License along with Smoothie. If not, see <http://www.gnu.org/licenses/>.
6*/
7
8#include "mbed.h"
9#include "libs/Kernel.h"
10#include "modules/tools/laser/Laser.h"
11#include "modules/tools/extruder/Extruder.h"
12#include "libs/SDFileSystem.h"
13#include "libs/Config.h"
14
15SDFileSystem sd(p5, p6, p7, p8, "sd");
16//LocalFileSystem local("local");
17
18//void checksum( Kernel* kernel, string key ){ kernel->serial->printf("%s: %u\r\n", key.c_str(), kernel->config->get_checksum(key)); }
19
20int main() {
21
22 Kernel* kernel = new Kernel();
23
24 kernel->serial->printf("Smoothie ( grbl port ) version 0.1a \r\nstart\r\n");
25
26 kernel->add_module( new Laser(p21) );
27 //kernel->add_module( new Extruder(p22) );
28
29 while(1){
30 kernel->call_event(ON_MAIN_LOOP);
31 }
32
33}