#---------------------------------------------- # Example Makefile for a lustre application # user makefile to use with Arduino.mk #---------------------------------------------- # Name of the final binary TARGET=control # usr sources: # ./objs/control.cpp: is the C code generated from lustre # utils/BatCar.cpp: an api to ease interfacing the batcar in/out # control_loop.cpp: the arduino cpp code (setup + loop) USR_SRCS= \ ./objs/control.cpp \ ../code/BatCar.cpp \ control_loop.cpp # Thinks that can be customized USR_CPP_FLAGS= USR_CC_FLAGS= USR_INCLS=-I./objs -I../code # target can be: # compile # upload # clean all: compile #------------------------------------------------------ # Lustre to C rules #------------------------------------------------------ # n.b. control_ext.h is part of the user code: # it bypass the default types definition to fit arduino ones LUS_FLAGS=-ctx-static -extmacro -exttypes ./objs/control.cpp: control.lus cd ./objs; lus2c ../control.lus control $(LUS_FLAGS); mv control.c control.cpp cp control_ext.h ./objs # Generic makefile ARDUINO_BOARD=SBC include ../utils/Arduino.mk