Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Merge branch 'master' of github.com:jgautier/firmata

  • Loading branch information...
commit fd53d7e42a746ce643f8875c71ad805cf63d3887 2 parents d452ee3 + 46f5c29
Julian Gautier authored June 06, 2011

Showing 1 changed file with 28 additions and 11 deletions. Show diff stats Hide diff stats

  1. 39  readme.md
39  readme.md
Source Rendered
@@ -25,10 +25,15 @@ If you run *firmata* from the command line it will prompt you for the usb port.
25 25
      SERVO:0x04   
26 26
     }
27 27
   This is an enumeration of the different modes available.  This are used in calls to the *pinMode* function.
  28
+
28 29
   *Board.HIGH* and *Board.LOW*
  30
+
29 31
   These are constants used to set a digital pin low or high.  Used in calls to the *digitalWrite* function.
  32
+
30 33
   *Board.pins*
  34
+
31 35
   This is an array of all the pins on the arduino board.
  36
+
32 37
   Each value in the array is an object:
33 38
 
34 39
     {
@@ -37,20 +42,32 @@ If you run *firmata* from the command line it will prompt you for the usb port.
37 42
     ,supportedModes://an array of modes from board.MODES that are supported on this pin.
38 43
     ,analogChannel://will be 127 for digital pins and the pin number for analog pins.
39 44
     }
  45
+
40 46
   This array holds all pins digital and analog. To get the analog pin number as seen on the arduino board use the analogChannel attribute.
  47
+
41 48
   *Board.analogPins*
  49
+
42 50
   This is an array of all the array indexes of the analog pins in the *Board.pins* array.  
43 51
   For example to get the analog pin 5 from the *Board.pins* attributes use:
44 52
 
45 53
     board.pins[board.analogPins[5]];
46  
-  #methods
47  
-    *board.pinMode(pin,mode)*  
48  
-      Set a mode for a pin.  pin is the number of the pin and the mode is on of the Board.MODES values.
49  
-    *board.digitalWrite(pin,value)*  
50  
-      Write an output to a digital pin.  pin is the number of the pin and the value is either board.HIGH or board.LOW.
51  
-    *board.digitalRead(pin,callback)*
52  
-      Read a digital value from the pin.  Evertime there is data for the pin the callback will be fired with a value argument.  
53  
-    *board.analogWrite(pin,value)*  
54  
-      Write an output to a digital pin.  pin is the number of the pin and the value is between 0 and 255.  
55  
-    *board.analogRead(pin,callback)*  
56  
-      Read an input for an analog pin.  Every time there is data on the pin the callback will be fired with a value argument.  
  54
+##methods
  55
+  *board.pinMode(pin,mode)*  
  56
+
  57
+  Set a mode for a pin.  pin is the number of the pin and the mode is on of the Board.MODES values.
  58
+
  59
+  *board.digitalWrite(pin,value)*  
  60
+
  61
+  Write an output to a digital pin.  pin is the number of the pin and the value is either board.HGH or board.LOW.
  62
+
  63
+  *board.digitalRead(pin,callback)*
  64
+
  65
+  Read a digital value from the pin.  Evertime there is data for the pin the callback will be fired with a value argument.  
  66
+
  67
+  *board.analogWrite(pin,value)*  
  68
+
  69
+  Write an output to a digital pin.  pin is the number of the pin and the value is between 0 and 255.  
  70
+
  71
+  *board.analogRead(pin,callback)*  
  72
+
  73
+  Read an input for an analog pin.  Every time there is data on the pin the callback will be fired with a value argument.  

0 notes on commit fd53d7e

Please sign in to comment.
Something went wrong with that request. Please try again.