Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
M
marlin-anet-a8
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jonas Leder
marlin-anet-a8
Commits
d9f7ed9a
Commit
d9f7ed9a
authored
8 years ago
by
Scott Lahteine
Browse files
Options
Downloads
Patches
Plain Diff
Move some macros from Marlin.h to macros.h
parent
277899c1
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
Marlin/Marlin.h
+0
-11
0 additions, 11 deletions
Marlin/Marlin.h
Marlin/macros.h
+11
-0
11 additions, 0 deletions
Marlin/macros.h
with
11 additions
and
11 deletions
Marlin/Marlin.h
+
0
−
11
View file @
d9f7ed9a
...
...
@@ -22,12 +22,6 @@
#ifndef MARLIN_H
#define MARLIN_H
#define FORCE_INLINE __attribute__((always_inline)) inline
/**
* Compiler warning on unused variable.
*/
#define UNUSED(x) (void) (x)
#include
<math.h>
#include
<stdio.h>
#include
<stdlib.h>
...
...
@@ -265,11 +259,6 @@ inline void refresh_cmd_timeout() { previous_cmd_ms = millis(); }
void
setPwmFrequency
(
uint8_t
pin
,
int
val
);
#endif
#ifndef CRITICAL_SECTION_START
#define CRITICAL_SECTION_START unsigned char _sreg = SREG; cli();
#define CRITICAL_SECTION_END SREG = _sreg;
#endif
/**
* Feedrate scaling and conversion
*/
...
...
This diff is collapsed.
Click to expand it.
Marlin/macros.h
+
11
−
0
View file @
d9f7ed9a
...
...
@@ -23,6 +23,17 @@
#ifndef MACROS_H
#define MACROS_H
#define FORCE_INLINE __attribute__((always_inline)) inline
// Bracket code that shouldn't be interrupted
#ifndef CRITICAL_SECTION_START
#define CRITICAL_SECTION_START unsigned char _sreg = SREG; cli();
#define CRITICAL_SECTION_END SREG = _sreg;
#endif
// Remove compiler warning on an unused variable
#define UNUSED(x) (void) (x)
// Macros to make a string from a macro
#define STRINGIFY_(M) #M
#define STRINGIFY(M) STRINGIFY_(M)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment