https://github.com/dilawar/arduino_sample_project
A sample arduino project (makefile based flow)
https://github.com/dilawar/arduino_sample_project
Last synced: 8 months ago
JSON representation
A sample arduino project (makefile based flow)
- Host: GitHub
- URL: https://github.com/dilawar/arduino_sample_project
- Owner: dilawar
- Created: 2016-04-25T13:36:17.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2016-05-10T04:20:58.000Z (over 9 years ago)
- Last Synced: 2025-01-04T14:14:29.950Z (9 months ago)
- Language: C++
- Size: 54.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Sample project
This is a working version of a real lab project (https://github.com/ananthmurthy/eyeBlinkBehaviour).
This is here for a demo purposeTo build and uploading to arduino is as simple as typing
$ make
$ make uploadAnd you can edit your files in your faviorite editor. Works on Mac and Linux.
# What to change?
The source code goes into `src` folder. Open the makefile and changes the values
of `LOCAL_INO_SRCS` (there should be one or zero `.ino` file in your project).Most of source file would have either extension `.cpp` or `.c`. Append them to
variable `LOCAL_CPP_SRCS`. For example, this sample project has the following:~~~~
## INO file and other cpp files
LOCAL_INO_SRCS = $(PROJECT_DIR)/src/eye_blink_main.ino
LOCAL_CPP_SRCS = $(PROJECT_DIR)/src/TriggerImaging.cpp \
$(PROJECT_DIR)/src/Solenoid.cpp \
$(PROJECT_DIR)/src/PhaseChangeRoutine.cpp \
$(PROJECT_DIR)/src/main.cpp \
$(PROJECT_DIR)/src/LocalLibrary.cpp \
$(PROJECT_DIR)/src/LCDRelated.cpp \
$(PROJECT_DIR)/src/Initialize.cpp \
$(PROJECT_DIR)/src/DetectBlinks.cpp \
$(PROJECT_DIR)/src/Globals.cpp \
$(PROJECT_DIR)/src/ChangePhase.cpp~~~~
You don't have to change anything else. I've tested is on `Mac` and `Linux`.
Of-course you need to install arduino. Even if you don't have a board to connect
to, you can still build your project.