Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
math_ops.h@0:4dd2d995f7d0, 2019-05-07 (annotated)
- Committer:
- benkatz
- Date:
- Tue May 07 01:56:53 2019 +0000
- Revision:
- 0:4dd2d995f7d0
works with the python side control
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| benkatz | 0:4dd2d995f7d0 | 1 | #ifndef MATH_OPS_H |
| benkatz | 0:4dd2d995f7d0 | 2 | #define MATH_OPS_H |
| benkatz | 0:4dd2d995f7d0 | 3 | |
| benkatz | 0:4dd2d995f7d0 | 4 | #define PI 3.14159265359f |
| benkatz | 0:4dd2d995f7d0 | 5 | #define SQRT3 1.73205080757f |
| benkatz | 0:4dd2d995f7d0 | 6 | |
| benkatz | 0:4dd2d995f7d0 | 7 | #include "math.h" |
| benkatz | 0:4dd2d995f7d0 | 8 | |
| benkatz | 0:4dd2d995f7d0 | 9 | float fmaxf(float x, float y); |
| benkatz | 0:4dd2d995f7d0 | 10 | float fminf(float x, float y); |
| benkatz | 0:4dd2d995f7d0 | 11 | float fmaxf3(float x, float y, float z); |
| benkatz | 0:4dd2d995f7d0 | 12 | float fminf3(float x, float y, float z); |
| benkatz | 0:4dd2d995f7d0 | 13 | float roundf(float x); |
| benkatz | 0:4dd2d995f7d0 | 14 | void limit_norm(float *x, float *y, float limit); |
| benkatz | 0:4dd2d995f7d0 | 15 | void limit(float *x, float min, float max); |
| benkatz | 0:4dd2d995f7d0 | 16 | int float_to_uint(float x, float x_min, float x_max, int bits); |
| benkatz | 0:4dd2d995f7d0 | 17 | float uint_to_float(int x_int, float x_min, float x_max, int bits); |
| benkatz | 0:4dd2d995f7d0 | 18 | |
| benkatz | 0:4dd2d995f7d0 | 19 | #endif |