Skip to content

Commit 0526855

Browse files
committed
Update README.md about compatibility with Windows
Fix #94
1 parent 967d47c commit 0526855

File tree

2 files changed

+59
-19
lines changed

2 files changed

+59
-19
lines changed

HISTORY.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ I tried to give credit whenever possible. If I have missed anyone, kindly add it
1010
- Tweak: Don't hard code MONITOR_PORT in examples, for more flexible testing. (Issue #157) (https://github.com/peplin)
1111
- Tweak: Silence the stderr output from call to `which`. (Issue #158) (https://github.com/peplin)
1212
- Fix: Override complete compiler tool paths for chipKIT. (Issue #159) (https://github.com/peplin)
13+
- New: The makefile is compatible with Windows
14+
- New: Update `README.md` file about usage and Windows compatibility
1315

1416
### 1.2.0 (2014-01-14)
1517
- Add: Add RPM SPECfile and new `package` directory to store package instructions and files (https://github.com/sej7278)

README.md

Lines changed: 57 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,37 @@
11
# A Makefile for Arduino Sketches
22

3-
This is a very simple Makefile which knows how to build Arduino sketches. It defines the entire workflows for compiling code, flashing it to Arduino and even communicating through Serial monitor. You don't need to change anything in the Arduino sketches.
3+
This is a very simple Makefile which knows how to build Arduino sketches. It defines entire workflows for compiling code, flashing it to Arduino and even communicating through Serial monitor. You don't need to change anything in the Arduino sketches.
44

5-
If you're using FreeBSD, Debian or Ubuntu, you can find this in the `arduino-mk` package.
5+
## Features
66

7-
## Usage
7+
- Very robust
8+
- Supports all official AVR-based Arduino boards
9+
- Supports chipKIT
10+
- Works on all three major OS (Mac, Linux, Windows)
11+
- Auto detects serial baud rate and libraries used
12+
- Support for `*.ino` and `*.pde` sketches as well as raw `*.c` and `*.cpp`
13+
- Support for Arduino Software versions 1.0.x as well as 0.x.
14+
Support for Arduino 1.5.x is still work in progress
15+
- Automatic dependency tracking. Referred libraries are automatically included
16+
in the build process. Changes in `*.h` files lead to recompilation of sources which include them
817

9-
You can also find more [detailed instructions in this guide](http://hardwarefun.com/tutorials/compiling-arduino-sketches-using-makefile) or also checkout the sample makefiles inside the examples/ folder
18+
## Installation
1019

11-
Download a copy of this repo some where in your system.
20+
### Through package
1221

13-
On the Mac you might want to set:
22+
If you're using FreeBSD, Debian or Ubuntu, you can find this in the `arduino-mk`
23+
package and can be installed using `apt-get` or `aptitude`.
1424

15-
ARDUINO_DIR = /Applications/Arduino.app/Contents/Resources/Java
16-
ARDMK_DIR = /usr/local
17-
AVR_TOOLS_DIR = /usr
25+
### From source
1826

19-
On Linux, you shouldn't need to set anything other than your board type and port:
27+
- Download the latest release
28+
- Or clone it from Github using the command `git clone [email protected]:sudar/Arduino-Makefile.git`
29+
- Check the [usage section](https://github.com/sudar/Arduino-Makefile#usage) in this readme about setting usage options
2030

21-
BOARD_TAG = mega2560
22-
MONITOR_PORT = /dev/ttyACM0
31+
## Requirements
2332

24-
- `BOARD_TAG` - Type of board, for a list see boards.txt or `make show_boards`
25-
- `MONITOR_PORT` - The port where your Arduino is plugged in, usually `/dev/ttyACM0` or `/dev/ttyUSB0` in Linux or Mac OS X and `com3`, `com4`, etc. in Windows.
26-
- `ARDUINO_DIR` - Path to Arduino installation. In Cygwin in Windows this path must be
27-
relative, not absolute (e.g. "../../arduino" and not "/c/cygwin/Arduino").
28-
- `ARDMK_DIR` - Path where the `*.mk` are present. If you installed the package, then it is usually `/usr/share/arduino`
29-
- `AVR_TOOLS_DIR` - Path where the avr tools chain binaries are present. If you are going to use the binaries that came with Arduino installation, then you don't have to set it.
33+
You need to have the Arduino IDE. You can either install it through the
34+
installer or download the distribution zip file and extract it.
3035

3136
The Makefile also delegates resetting the board to a short Perl program.
3237
You'll need to install `Device::SerialPort` to use it though.
@@ -45,14 +50,47 @@ On openSUSE:
4550

4651
On Mac using MacPorts:
4752

48-
sudo port install p5-device-serialport
53+
sudo port install p5-device-serialport
4954

5055
and use /opt/local/bin/perl5 instead of /usr/bin/perl
5156

5257
On other systems:
5358

5459
cpan Device::SerialPort
5560

61+
## Usage
62+
63+
You can also find more [detailed instructions in this guide](http://hardwarefun.com/tutorials/compiling-arduino-sketches-using-makefile) or also checkout the sample makefiles inside the examples/ folder
64+
65+
Download a copy of this repo some where in your system or install it through a package.
66+
67+
On the Mac you might want to set:
68+
69+
ARDUINO_DIR = /Applications/Arduino.app/Contents/Resources/Java
70+
ARDMK_DIR = /usr/local
71+
AVR_TOOLS_DIR = /usr
72+
MONITOR_PORT = /dev/ttyACM0
73+
BOARD_TAG = mega2560
74+
75+
On Linux (if you have installed through package), you shouldn't need to set anything other than your board type and port:
76+
77+
BOARD_TAG = mega2560
78+
MONITOR_PORT = /dev/ttyACM0
79+
80+
On Windows (using cygwin), you might want to set:
81+
82+
ARDUINO_DIR = ../../arduino
83+
ARDMK_DIR = path/to/mkfile
84+
MONITOR_PORT = com3
85+
BOARD_TAG = mega2560
86+
87+
- `BOARD_TAG` - Type of board, for a list see boards.txt or `make show_boards`
88+
- `MONITOR_PORT` - The port where your Arduino is plugged in, usually `/dev/ttyACM0` or `/dev/ttyUSB0` in Linux or Mac OS X and `com3`, `com4`, etc. in Windows.
89+
- `ARDUINO_DIR` - Path to Arduino installation. In Cygwin in Windows this path must be
90+
relative, not absolute (e.g. "../../arduino" and not "/c/cygwin/Arduino").
91+
- `ARDMK_DIR` - Path where the `*.mk` are present. If you installed the package, then it is usually `/usr/share/arduino`
92+
- `AVR_TOOLS_DIR` - Path where the avr tools chain binaries are present. If you are going to use the binaries that came with Arduino installation, then you don't have to set it.
93+
5694
## Including Libraries
5795

5896
You can specify space separated list of libraries that are needed for your sketch to the variable `ARDUINO_LIBS`.

0 commit comments

Comments
 (0)