utils: added macro to retrieve the number of elements of an array
This commit is contained in:
parent
b16c3c0fd1
commit
4515bd9e60
|
|
@ -28,6 +28,14 @@
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the number of elements of an array.
|
||||||
|
*
|
||||||
|
* @param x: array.
|
||||||
|
* @return number of elements.
|
||||||
|
*/
|
||||||
|
#define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0]))
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This function allows to obtain the value of a given calibration parameter for
|
* This function allows to obtain the value of a given calibration parameter for
|
||||||
* frequencies outside the calibration points. It works by searching the two
|
* frequencies outside the calibration points. It works by searching the two
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue