YRL Maze lab made more script-y

Dependencies:   PsiSwarmLab-ScriptingBased mbed

Fork of UKESF_Lab by UKESF Headstart Summer School

main.cpp

Committer:
YRL44
Date:
2018-09-18
Revision:
34:232559052b2f
Parent:
32:cdcc91651e55

File content as of revision 34:232559052b2f:

/**********************************************************
* UKESF Headstart Summer School - Robot Programming Lab   *
**********************************************************/

// Note: A line beginning with // is a 'comment' and is
// ignored by the compiler [it is shown in green text in the IDE]

// Include main.h - this contains the code needed to setup
// the Psi-Swarm robot and its hardware
#include "main.h"

// You can change the author name to saomething else if you want - just make sure it is no more than 16 characters long
char * author_name  = "YRL";

/// The main routine: it is recommended to leave this function alone and add user code to the above functions
int main()
{
    // Call external variable setting code
    #include "setMotorSpeeds.txt"
    
    // init() in psiswarm.cpp sets up the robot - we need to run this line of code before anything else or the robot won't work.
    init();

    // Call the scripted actions
    #include "script.txt"
    
    // When we have finished our code, we want to leave the MBED in an endless loop.
    while(1){}
}

////////////////////////////////////////////////////////////////////////////////////////////////////

// You can ignore the code beyond this point: we need these variables and functions to make the code
// compile without errors, but we aren't using the functions for this lab session.
char * program_name = "Headstart";
char * version_name = "0.5";
void handle_switch_event(char switch_state){}
void handle_user_serial_message(char * message, char length, char interface){}