Index: ADuCM360_demo_cn0359/src/hal/drivers/adc.cpp =================================================================== diff -u -r8d80f35bf88694bd50d769b9bab31db8364a9004 -rb39d7f18a4f5f23a76b7fb484c13bffd225ef466 --- ADuCM360_demo_cn0359/src/hal/drivers/adc.cpp (.../adc.cpp) (revision 8d80f35bf88694bd50d769b9bab31db8364a9004) +++ ADuCM360_demo_cn0359/src/hal/drivers/adc.cpp (.../adc.cpp) (revision b39d7f18a4f5f23a76b7fb484c13bffd225ef466) @@ -36,8 +36,10 @@ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ******************************************************************************/ - +#ifdef EVAL_BUILD #include +#endif // EVAL_BUILD + #include #include #include @@ -50,9 +52,10 @@ #include #include #include +#include #define ADC0FLT_AF (15<<8) -#define ADC0FLT_SF 124 +#define ADC0FLT_SF 31 #define ADC1FLT_AF (15<<8) #define ADC1FLT_SF 124 @@ -394,16 +397,29 @@ t.timer_app.argv = new char*; new_timer(t); + + // If automated polling / publihsing flag is enabled + if(true == is_auto_publish_enbld()) + { + // Start publihsing raw conductivity measurements + app msg; + msg.argc = 0; + msg.fun = auto_publish; + msg.argv = new char*; + post_message(msg); + } break; } ++result.adc0_hit; - + +#ifdef EVAL_BUILD app msg; msg.argc = 0; msg.fun = on_conductivity; msg.argv = new char*; post_message(msg); +#endif // EVAL_BUILD return 0; } @@ -511,11 +527,11 @@ result.temp = 25; } - app msg; - msg.argc = 0; - msg.fun = on_rtd; - msg.argv = new char*; - post_message(msg); +// app msg; +// msg.argc = 0; +// msg.fun = on_rtd; +// msg.argv = new char*; +// post_message(msg); pADI_ADC1->CON = (pADI_ADC1->CON & ~ADC1CON_ADCREF_MSK & ~ADC1CON_ADCDIAG_MSK & ~ADC1CON_ADCCP_MSK & ~ADC1CON_ADCCN_MSK)