projects
/
proxmark3-svn
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
00349d8
)
save 2.3K flash-memory by avoiding a single floating point operation (#630)
author
pwpiwi
<pwpiwi@users.noreply.github.com>
Thu, 26 Jul 2018 15:18:10 +0000
(17:18 +0200)
committer
GitHub
<noreply@github.com>
Thu, 26 Jul 2018 15:18:10 +0000
(17:18 +0200)
armsrc/util.c
patch
|
blob
|
blame
|
history
diff --git
a/armsrc/util.c
b/armsrc/util.c
index e25c6e0ba8e98d9c836082568150281f1581084e..59dfe07b45987250ae74b0495de38636e293560d 100644
(file)
--- a/
armsrc/util.c
+++ b/
armsrc/util.c
@@
-489,13
+489,13
@@
void WaitTicks(uint32_t ticks){
// 1us = 1.5ticks.
void WaitUS(uint16_t us){
if ( us == 0 ) return;
// 1us = 1.5ticks.
void WaitUS(uint16_t us){
if ( us == 0 ) return;
- WaitTicks(
(uint32_t)(us * 1.5) )
;
+ WaitTicks(
(uint32_t)us * 3 / 2 )
;
}
void WaitMS(uint16_t ms){
if (ms == 0) return;
}
void WaitMS(uint16_t ms){
if (ms == 0) return;
- WaitTicks( (uint32_t)
(ms * 1500)
);
+ WaitTicks( (uint32_t)
ms * 1500
);
}
}
Impressum
,
Datenschutz