Skip to content

Commit bfca2c5

Browse files
authored
Merge branch 'master' into patch-1
2 parents 580acd3 + 76e0e67 commit bfca2c5

38 files changed

+1168
-1157
lines changed

Language/Functions/Advanced IO/pulseIn.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ subCategories: [ "Advanced I/O" ]
1717

1818
[float]
1919
=== Description
20-
Reads a pulse (either HIGH or LOW) on a pin. For example, if *value* is *HIGH*, `pulseIn()` waits for the pin to go *HIGH*, starts timing, then waits for the pin to go *LOW* and stops timing. Returns the length of the pulse in microseconds. Gives up and returns 0 if no pulse starts within a specified time out.
20+
Reads a pulse (either `HIGH` or `LOW`) on a pin. For example, if `value` is `HIGH`, `pulseIn()` waits for the pin to go from `LOW` to `HIGH`, starts timing, then waits for the pin to go `LOW` and stops timing. Returns the length of the pulse in microseconds or gives up and returns 0 if no complete pulse was received within the timeout.
2121

2222
The timing of this function has been determined empirically and will probably show errors in longer pulses. Works on pulses from 10 microseconds to 3 minutes in length.
2323
[%hardbreaks]

Language/Functions/Advanced IO/pulseInLong.adoc

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,11 @@ subCategories: [ "Advanced I/O" ]
1717

1818
[float]
1919
=== Description
20-
Reads a pulse (either HIGH or LOW) on a pin. For example, if value is HIGH, `pulseInLong()` waits for the pin to go `HIGH`, starts timing, then waits for the pin to go `LOW` and stops timing. Returns the length of the pulse in microseconds or 0 if no complete pulse was received within the timeout.
20+
`pulseInLong()` is an alternative to link:../pulsein[pulseIn()] which is better at handling long pulse and interrupt affected scenarios.
2121

22-
The timing of this function has been determined empirically and will probably show errors in shorter pulses. Works on pulses from 10 microseconds to 3 minutes in length. Please also note that if the pin is already high when the function is called, it will wait for the pin to go LOW and then HIGH before it starts counting. This routine can be used only if interrupts are activated. Furthermore the highest resolution is obtained with large intervals.
22+
Reads a pulse (either `HIGH` or `LOW`) on a pin. For example, if `value` is `HIGH`, `pulseInLong()` waits for the pin to go from `LOW` to `HIGH`, starts timing, then waits for the pin to go `LOW` and stops timing. Returns the length of the pulse in microseconds or gives up and returns 0 if no complete pulse was received within the timeout.
23+
24+
The timing of this function has been determined empirically and will probably show errors in shorter pulses. Works on pulses from 10 microseconds to 3 minutes in length. This routine can be used only if interrupts are activated. Furthermore the highest resolution is obtained with large intervals.
2325
[%hardbreaks]
2426

2527

Language/Functions/Analog IO/analogRead.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ subCategories: [ "Analog I/O" ]
1616

1717
[float]
1818
=== Description
19-
Reads the value from the specified analog pin. The Arduino board contains a 6 channel (8 channels on the Mini and Nano, 16 on the Mega), 10-bit analog to digital converter. This means that it will map input voltages between 0 and 5 volts into integer values between 0 and 1023. This yields a resolution between readings of: 5 volts / 1024 units or, .0049 volts (4.9 mV) per unit. The input range and resolution can be changed using link:../analogreference[analogReference()].
19+
Reads the value from the specified analog pin. The Arduino board contains a 6 channel (7 channels on MKR boards, 8 on the Mini and Nano, 16 on the Mega), 10-bit analog to digital converter. This means that it will map input voltages between 0 and 5 volts into integer values between 0 and 1023. This yields a resolution between readings of: 5 volts / 1024 units or, .0049 volts (4.9 mV) per unit. The input range and resolution can be changed using link:../analogreference[analogReference()].
2020

2121
It takes about 100 microseconds (0.0001 s) to read an analog input, so the maximum reading rate is about 10,000 times a second.
2222
[%hardbreaks]
@@ -29,7 +29,7 @@ It takes about 100 microseconds (0.0001 s) to read an analog input, so the maxim
2929

3030
[float]
3131
=== Parameters
32-
`pin`: the number of the analog input pin to read from (0 to 5 on most boards, 0 to 7 on the Mini and Nano, 0 to 15 on the Mega)
32+
`pin`: the number of the analog input pin to read from (0 to 5 on most boards, 0 to 6 on MKR boards, 0 to 7 on the Mini and Nano, 0 to 15 on the Mega)
3333

3434
[float]
3535
=== Returns
Lines changed: 82 additions & 82 deletions
Original file line numberDiff line numberDiff line change
@@ -1,82 +1,82 @@
1-
---
2-
title: "isAlpha()"
3-
categories: [ "Functions" ]
4-
subCategories: [ "Characters" ]
5-
---
6-
7-
8-
9-
10-
11-
= isAlpha(thisChar)
12-
13-
14-
// OVERVIEW SECTION STARTS
15-
[#overview]
16-
--
17-
18-
[float]
19-
=== Description
20-
Analyse if a char is alpha (that is a letter). Returns true if thisChar contains a letter.
21-
[%hardbreaks]
22-
23-
24-
[float]
25-
=== Syntax
26-
[source,arduino]
27-
----
28-
isAlpha(thisChar)
29-
----
30-
31-
[float]
32-
=== Parameters
33-
`thisChar`: variable. *Allowed data types:* char
34-
35-
[float]
36-
=== Returns
37-
`true`: if thisChar is alpha.
38-
39-
--
40-
// OVERVIEW SECTION ENDS
41-
42-
43-
44-
// HOW TO USE SECTION STARTS
45-
[#howtouse]
46-
--
47-
48-
[float]
49-
=== Example Code
50-
51-
[source,arduino]
52-
----
53-
if (isAlpha(this)) // tests if this is a letter
54-
{
55-
Serial.println("The character is a letter");
56-
}
57-
else
58-
{
59-
Serial.println("The character is not a letter");
60-
}
61-
62-
----
63-
64-
--
65-
// HOW TO USE SECTION ENDS
66-
67-
68-
// SEE ALSO SECTION
69-
[#see_also]
70-
--
71-
72-
[float]
73-
=== See also
74-
75-
[role="language"]
76-
* #LANGUAGE# link:../../../variables/data-types/char[char]
77-
* #LANGUAGE# link:../../../structure/control-structure/if[if (conditional operators)]
78-
* #LANGUAGE# link:../../../structure/control-structure/while[while (conditional operators)]
79-
* #LANGUAGE# link:../../communication/serial/read[read()]
80-
81-
--
82-
// SEE ALSO SECTION ENDS
1+
---
2+
title: "isAlpha()"
3+
categories: [ "Functions" ]
4+
subCategories: [ "Characters" ]
5+
---
6+
7+
8+
9+
10+
11+
= isAlpha(thisChar)
12+
13+
14+
// OVERVIEW SECTION STARTS
15+
[#overview]
16+
--
17+
18+
[float]
19+
=== Description
20+
Analyse if a char is alpha (that is a letter). Returns true if thisChar contains a letter.
21+
[%hardbreaks]
22+
23+
24+
[float]
25+
=== Syntax
26+
[source,arduino]
27+
----
28+
isAlpha(thisChar)
29+
----
30+
31+
[float]
32+
=== Parameters
33+
`thisChar`: variable. *Allowed data types:* char
34+
35+
[float]
36+
=== Returns
37+
`true`: if thisChar is alpha.
38+
39+
--
40+
// OVERVIEW SECTION ENDS
41+
42+
43+
44+
// HOW TO USE SECTION STARTS
45+
[#howtouse]
46+
--
47+
48+
[float]
49+
=== Example Code
50+
51+
[source,arduino]
52+
----
53+
if (isAlpha(this)) // tests if this is a letter
54+
{
55+
Serial.println("The character is a letter");
56+
}
57+
else
58+
{
59+
Serial.println("The character is not a letter");
60+
}
61+
62+
----
63+
64+
--
65+
// HOW TO USE SECTION ENDS
66+
67+
68+
// SEE ALSO SECTION
69+
[#see_also]
70+
--
71+
72+
[float]
73+
=== See also
74+
75+
[role="language"]
76+
* #LANGUAGE# link:../../../variables/data-types/char[char]
77+
* #LANGUAGE# link:../../../structure/control-structure/if[if (conditional operators)]
78+
* #LANGUAGE# link:../../../structure/control-structure/while[while (conditional operators)]
79+
* #LANGUAGE# link:../../communication/serial/read[read()]
80+
81+
--
82+
// SEE ALSO SECTION ENDS
Lines changed: 81 additions & 81 deletions
Original file line numberDiff line numberDiff line change
@@ -1,82 +1,82 @@
1-
---
2-
title: "isAlphaNumeric()"
3-
categories: [ "Functions" ]
4-
subCategories: [ "Characters" ]
5-
---
6-
7-
8-
9-
10-
11-
= isAlphaNumeric(thisChar)
12-
13-
14-
// OVERVIEW SECTION STARTS
15-
[#overview]
16-
--
17-
18-
[float]
19-
=== Description
20-
Analyse if a char is alphanumeric (that is a letter or a numbers). Returns true if thisChar contains either a number or a letter.
21-
[%hardbreaks]
22-
23-
24-
[float]
25-
=== Syntax
26-
[source,arduino]
27-
----
28-
`isAlphaNumeric(thisChar)`
29-
----
30-
31-
[float]
32-
=== Parameters
33-
`thisChar`: variable. *Allowed data types:* char
34-
35-
[float]
36-
=== Returns
37-
`true`: if thisChar is alphanumeric.
38-
39-
--
40-
// OVERVIEW SECTION ENDS
41-
42-
43-
44-
// HOW TO USE SECTION STARTS
45-
[#howtouse]
46-
--
47-
48-
[float]
49-
=== Example Code
50-
51-
[source,arduino]
52-
----
53-
if (isAlphaNumeric(this)) // tests if this isa letter or a number
54-
{
55-
Serial.println("The character is alphanumeric");
56-
}
57-
else
58-
{
59-
Serial.println("The character is not alphanumeric");
60-
}
61-
62-
----
63-
64-
--
65-
// HOW TO USE SECTION ENDS
66-
67-
68-
// SEE ALSO SECTION
69-
[#see_also]
70-
--
71-
72-
[float]
73-
=== See also
74-
75-
[role="language"]
76-
* #LANGUAGE# link:../../../variables/data-types/char[char]
77-
* #LANGUAGE# link:../../../structure/control-structure/if[if (conditional operators)]
78-
* #LANGUAGE# link:../../../structure/control-structure/while[while (conditional operators)]
79-
* #LANGUAGE# link:../../communication/serial/read[read()]
80-
81-
--
1+
---
2+
title: "isAlphaNumeric()"
3+
categories: [ "Functions" ]
4+
subCategories: [ "Characters" ]
5+
---
6+
7+
8+
9+
10+
11+
= isAlphaNumeric(thisChar)
12+
13+
14+
// OVERVIEW SECTION STARTS
15+
[#overview]
16+
--
17+
18+
[float]
19+
=== Description
20+
Analyse if a char is alphanumeric (that is a letter or a numbers). Returns true if thisChar contains either a number or a letter.
21+
[%hardbreaks]
22+
23+
24+
[float]
25+
=== Syntax
26+
[source,arduino]
27+
----
28+
`isAlphaNumeric(thisChar)`
29+
----
30+
31+
[float]
32+
=== Parameters
33+
`thisChar`: variable. *Allowed data types:* char
34+
35+
[float]
36+
=== Returns
37+
`true`: if thisChar is alphanumeric.
38+
39+
--
40+
// OVERVIEW SECTION ENDS
41+
42+
43+
44+
// HOW TO USE SECTION STARTS
45+
[#howtouse]
46+
--
47+
48+
[float]
49+
=== Example Code
50+
51+
[source,arduino]
52+
----
53+
if (isAlphaNumeric(this)) // tests if this isa letter or a number
54+
{
55+
Serial.println("The character is alphanumeric");
56+
}
57+
else
58+
{
59+
Serial.println("The character is not alphanumeric");
60+
}
61+
62+
----
63+
64+
--
65+
// HOW TO USE SECTION ENDS
66+
67+
68+
// SEE ALSO SECTION
69+
[#see_also]
70+
--
71+
72+
[float]
73+
=== See also
74+
75+
[role="language"]
76+
* #LANGUAGE# link:../../../variables/data-types/char[char]
77+
* #LANGUAGE# link:../../../structure/control-structure/if[if (conditional operators)]
78+
* #LANGUAGE# link:../../../structure/control-structure/while[while (conditional operators)]
79+
* #LANGUAGE# link:../../communication/serial/read[read()]
80+
81+
--
8282
// SEE ALSO SECTION ENDS

0 commit comments

Comments
 (0)