modified macro to enable running in three modes: mLocal mLocalPAR and mLocalSource