Update library headers homepage
[arduino-mode.git] / README.org
blobf049540fbb44a0bd55a6273152e1bf88047ba2d1
1 * Intro
3 Arduino IDE for Emacs developer.
5 * Screenshots
7 #+ATTR_ORG: :width 600
8 #+ATTR_LATEX: :width 6.0in
9 #+ATTR_HTML: :width 600px
10 [[file:arduino-mode.png]]
12 * Install
14 ** MELPA available
16 * Features
18 - syntax highlighting
19 - command-line arduino interface
20 - org-mode babel support
22 * Usage
24 ** interactive with Arduino board in arduino-mode
26 - Upload :: In Arduino source code file, press =[C-c C-c]= to upload to Arduino board.
27 - Build :: In Arduino source code file, press =[C-c C-v]= to build.
29 ** Arduino code completing
31 use with package company-arduino to get Arduino code completing.
33 ** flycheck support
35 #+begin_src emacs-lisp
36 (require 'flycheck-arduino)
37 (add-hook 'arduino-mode-hook #'flycheck-arduino-setup)
38 #+end_src
40 ** Org Mode Babel source block support with ob-arduino.el
42 You need have Org-mode installed, ~ob-arduino.el~ is in arduino-mode by default now.
44 #+begin_src emacs-lisp
45 (require 'ob-arduino)
46 (add-to-list 'org-babel-load-languages '(arduino . t))
47 (org-babel-do-load-languages 'org-babel-load-languages org-babel-load-languages)
48 #+end_src
50 Like the following src block, press =[C-c C-c]= to upload to Arduino board.
52 #+begin_src org
53 ,#+begin_src arduino
54 // the setup function runs once when you press reset or power the board
55 void setup() {
56   // initialize digital pin LED_BUILTIN as an output.
57   pinMode(LED_BUILTIN, OUTPUT);
60 // the loop function runs over and over again forever
61 void loop() {
62   digitalWrite(LED_BUILTIN, HIGH);   // turn the LED on (HIGH is the voltage level)
63   delay(100);                       // wait for 0.1 second
64   digitalWrite(LED_BUILTIN, LOW);    // turn the LED off by making the voltage LOW
65   delay(100);                       // wait for 0.1 second
67 ,#+end_src
68 #+end_src