Function-style critical section macros
This commit is contained in:
1 parent
7b02a62da8
commit
fa6e7cb733
15 files changed
+42
-42
No files matched your search
@@ -129,9 +129,9 @@ void Servo::writeMicroseconds(int value) {
|
||||
value = constrain(value, SERVO_MIN(min), SERVO_MAX(max)) - (TRIM_DURATION);
|
||||
value = usToTicks(value); // convert to ticks after compensating for interrupt overhead - 12 Aug 2009
|
||||
|
||||
CRITICAL_SECTION_START;
|
||||
CRITICAL_SECTION_START();
|
||||
servo_info[channel].ticks = value;
|
||||
CRITICAL_SECTION_END;
|
||||
CRITICAL_SECTION_END();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user