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.
message.h@4:eb7a23c25751, 2021-10-06 (annotated)
- Committer:
- nsheth
- Date:
- Wed Oct 06 22:08:02 2021 +0000
- Revision:
- 4:eb7a23c25751
- Parent:
- Message.h@3:81d1980d45aa
- Child:
- 6:7d8f30b3bc57
Added app config to library
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| nsheth | 3:81d1980d45aa | 1 | /****************************************************************************** |
| nsheth | 3:81d1980d45aa | 2 | Copyright (c) 2020 - 2021 Analog Devices Inc. All Rights Reserved. |
| nsheth | 3:81d1980d45aa | 3 | This software is proprietary & confidential to Analog Devices, Inc. |
| nsheth | 3:81d1980d45aa | 4 | and its licensors. |
| nsheth | 3:81d1980d45aa | 5 | ******************************************************************************/ |
| nsheth | 3:81d1980d45aa | 6 | /** |
| nsheth | 3:81d1980d45aa | 7 | * @file message.h |
| nsheth | 3:81d1980d45aa | 8 | * @brief Defines for message |
| nsheth | 3:81d1980d45aa | 9 | * @{ |
| nsheth | 3:81d1980d45aa | 10 | */ |
| nsheth | 3:81d1980d45aa | 11 | |
| nsheth | 3:81d1980d45aa | 12 | #ifndef __MESSAGE_H__ |
| nsheth | 3:81d1980d45aa | 13 | #define __MESSAGE_H__ |
| nsheth | 3:81d1980d45aa | 14 | |
| nsheth | 3:81d1980d45aa | 15 | /*============= I N C L U D E S =============*/ |
| nsheth | 3:81d1980d45aa | 16 | #include <stdarg.h> |
| nsheth | 3:81d1980d45aa | 17 | #include <stdbool.h> |
| nsheth | 3:81d1980d45aa | 18 | #include <stdint.h> |
| nsheth | 3:81d1980d45aa | 19 | #include <stdio.h> |
| nsheth | 3:81d1980d45aa | 20 | /*============= D E F I N E S =============*/ |
| nsheth | 3:81d1980d45aa | 21 | /** Maximum message size value */ |
| nsheth | 3:81d1980d45aa | 22 | #define MAX_MSG_SIZE 128 |
| nsheth | 3:81d1980d45aa | 23 | |
| nsheth | 3:81d1980d45aa | 24 | /** No Warning */ |
| nsheth | 3:81d1980d45aa | 25 | #define NO_WARN 0 |
| nsheth | 3:81d1980d45aa | 26 | /** DDS & NCO Frequency are not equal warning */ |
| nsheth | 3:81d1980d45aa | 27 | #define DDS_NCO_FREQ_WARN 1 |
| nsheth | 3:81d1980d45aa | 28 | /** Calibration failed warning */ |
| nsheth | 3:81d1980d45aa | 29 | #define CAL_LOAD_FAIL_WARN 2 |
| nsheth | 3:81d1980d45aa | 30 | /** Autorange disabled warning */ |
| nsheth | 3:81d1980d45aa | 31 | #define AUTORANGE_DISABLE_WARN 4 |
| nsheth | 3:81d1980d45aa | 32 | /** Autorange failed warning */ |
| nsheth | 3:81d1980d45aa | 33 | #define AUTORANGE_FAIL_WARN 8 |
| nsheth | 3:81d1980d45aa | 34 | /** Sweep count warning */ |
| nsheth | 3:81d1980d45aa | 35 | #define SWEEPCOUNT_WARN 16 |
| nsheth | 3:81d1980d45aa | 36 | /** Magnitude limit warning */ |
| nsheth | 3:81d1980d45aa | 37 | #define MAG_EXCEED_WARN 32 |
| nsheth | 3:81d1980d45aa | 38 | /** Offset limit warning */ |
| nsheth | 3:81d1980d45aa | 39 | #define OFFSET_LIMITED_WARN 64 |
| nsheth | 3:81d1980d45aa | 40 | /** Positive offset exceed warning */ |
| nsheth | 3:81d1980d45aa | 41 | #define OFFSET_POS_EXCEED_WARN 128 |
| nsheth | 3:81d1980d45aa | 42 | /** Negative offset exceed warning */ |
| nsheth | 3:81d1980d45aa | 43 | #define OFFSET_NEG_EXCEED_WARN 256 |
| nsheth | 3:81d1980d45aa | 44 | |
| nsheth | 3:81d1980d45aa | 45 | //#define ENABLE_DEBUG |
| nsheth | 3:81d1980d45aa | 46 | |
| nsheth | 3:81d1980d45aa | 47 | /** Prints Info Message */ |
| nsheth | 3:81d1980d45aa | 48 | #define INFO_MSG(...) printf("", __VA_ARGS__); |
| nsheth | 3:81d1980d45aa | 49 | /** Prints warn message */ |
| nsheth | 3:81d1980d45aa | 50 | #define WARN_MSG(...) printf("Warn : ", __VA_ARGS__); |
| nsheth | 3:81d1980d45aa | 51 | /** Prints error message */ |
| nsheth | 3:81d1980d45aa | 52 | #define ERROR_MSG(...) printf("Error : ", __VA_ARGS__); |
| nsheth | 3:81d1980d45aa | 53 | |
| nsheth | 3:81d1980d45aa | 54 | #endif /* __MESSAGE_H__ */ |
| nsheth | 3:81d1980d45aa | 55 | |
| nsheth | 3:81d1980d45aa | 56 | /** |
| nsheth | 3:81d1980d45aa | 57 | * @} |
| nsheth | 3:81d1980d45aa | 58 | */ |
