bool terminalTask::regTlm(void) { #if ENABLE_TELEMETRY return (TLM_REG_VAR(tlm_component_get_by_name("debug"), mCommandCount, tlm_uint) && TLM_REG_VAR(tlm_component_get_by_name("debug"), mDiskTlmSize, tlm_uint)); #else return true; #endif }
bool terminalTask::regTlm(void) { #if SYS_CFG_ENABLE_TLM return (TLM_REG_VAR(tlm_component_get_by_name(SYS_CFG_DEBUG_TLM_NAME), mCommandCount, tlm_uint) && TLM_REG_VAR(tlm_component_get_by_name(SYS_CFG_DEBUG_TLM_NAME), mDiskTlmSize, tlm_uint)); #else return true; #endif }
bool example_nv_vars::regTlm(void) { #if SYS_CFG_ENABLE_TLM // Get the "disk" component list, this list is saved on disk periodically when variables change value tlm_component *disk = tlm_component_get_by_name(SYS_CFG_DISK_TLM_NAME); // Register the variable as "disk variable" whose value will be saved TLM_REG_VAR(disk, mVarWeDontWantToLose, tlm_int); #endif // Notice that after about 2 min of no terminal command, a message will print something like : // "disk variables changed, changes saved to disk" // Even if you reboot the board, this variable will not start from 0, but from the value // that was saved to the disk. return true; }