Support Forums
Timed Email

My application involves logging data for varying ESS cycles. Depending on the product, the lengths of these tests vary. Once the user starts the logging, I'd like to send out an email (create an event) after a certain amount of time has elapsed. How is this done? I read about time triggers, is that the way to go?

If I did a Timed Trigger with Synchronize to Midnight disabled, could I have a schedule like this;

RA15H
{
......send email.
}

Would I get an email 15 hrs after the operator initiated the job?

Thanks in advance,
Frank

My application involves logging data for varying ESS cycles. Depending on the product, the lengths of these tests vary. Once the user starts the logging, I'd like to send out an email (create an event) after a certain amount of time has elapsed. How is this done? I read about time triggers, is that the way to go? If I did a Timed Trigger with Synchronize to Midnight disabled, could I have a schedule like this; RA15H { ......send email. } Would I get an email 15 hrs after the operator initiated the job? Thanks in advance, Frank

Hi FrankI,

Your schedule will enable you to get an email every 15 hours with a reference point of job initialization (only if you disable Synchronize to Midnight).

Your previous statement said that the length of tests may vary. Do you want to have different interval for email transmission?
If yes, you can use conditional statement based on time.
Example: you want to have the first email sent in 15 hours, the second email in 5 hours etc.

RA1H
1CV(W)=1CV+1
IF(1CV==15){XB}
IF(1CV==20){XB}

RBX
...send email

There are many ways of doing this and the above code is one example.
I might be able to help you with the code if you explain the workflow of what you want to achieve in detail.

Best regards,
Rudy Gunawan

Hi FrankI, Your schedule will enable you to get an email every 15 hours with a reference point of job initialization (only if you disable Synchronize to Midnight). Your previous statement said that the length of tests may vary. Do you want to have different interval for email transmission? If yes, you can use conditional statement based on time. Example: you want to have the first email sent in 15 hours, the second email in 5 hours etc. RA1H 1CV(W)=1CV+1 IF(1CV==15){XB} IF(1CV==20){XB} RBX ...send email There are many ways of doing this and the above code is one example. I might be able to help you with the code if you explain the workflow of what you want to achieve in detail. Best regards, Rudy Gunawan

Rudy,

I have 4 toggle switches that are tied to the DT85's Digital inputs (4D 3D 2D 1D)
I will use the switch that is tied to 3D to select product type.

1) Run Schedule 'G' every hour
2) Store in 8CV
3) If Product type A (3D input high)
'>>4) Test the counter, run schedule 'H' if cnt=15 send email
5) Otherwise, if Product type B, test counter, if cnt=24 send email

Is the syntax below correct?

RG1H
8CV(W)=8CV+1
IF(9CV AND 4)
'>>IF(8CV==15){XH}
IF(8CV==24){XH}
RHX
....Send email

Thanks,
Frank

Rudy, I have 4 toggle switches that are tied to the DT85's Digital inputs (4D 3D 2D 1D) I will use the switch that is tied to 3D to select product type. 1) Run Schedule 'G' every hour 2) Store in 8CV 3) If Product type A (3D input high) '>>4) Test the counter, run schedule 'H' if cnt=15 send email 5) Otherwise, if Product type B, test counter, if cnt=24 send email Is the syntax below correct? RG1H 8CV(W)=8CV+1 IF(9CV AND 4) '>>IF(8CV==15){XH} IF(8CV==24){XH} RHX ....Send email Thanks, Frank

Hi FrankI,

I assumed that you want to test the counter and product type at the same time.

Then your code should contain multiple condition:

RG1H
8CV(W)=8CV+1
IF(3DS==1)AND IF(8CV==15){XH} 'product type A (3DS=1) and counting equal to 15, start schedule H
IF(3DS==0)AND IF(8CV==24){XH} 'product type B (3DS=0) and counting equal to 24, start schedule H

RHX
....Send email

Best regards,
Rudy Gunawan

Hi FrankI, I assumed that you want to test the counter and product type at the same time. Then your code should contain multiple condition: RG1H 8CV(W)=8CV+1 IF(3DS==1)AND IF(8CV==15){XH} 'product type A (3DS=1) and counting equal to 15, start schedule H IF(3DS==0)AND IF(8CV==24){XH} 'product type B (3DS=0) and counting equal to 24, start schedule H RHX ....Send email Best regards, Rudy Gunawan

Rudy,

Please see attached. I get an error message on the Manual Channel whenever I try to Save to Logger.

5cb99856312ed

Adding this manual channel “TestDashNo” causes the error message below.

5cb99874a9405

RG"OneHourTimer"("b:",ALARMS:OV:100KB:W60,DATA:OV:1MB)1H
LOGOFFG
CALC("Increment~",LM)=8CV=8CV+1
' User defined
IF(3DS==1) AND IF(8CV==15){XH}

RH"TestComplete"("b:",ALARMS:OV:100KB:W60,DATA:OV:1MB)5S
LOGOFFH
ALARM((CALC("SendEmail~",LM)=8CV=0)<0)"The Test is Complete"[mailto:fiorio@naii.com?priority=high&interface=ETHERNET&subject="Test Complete"]{}

Thanks

Rudy, Please see attached. I get an error message on the Manual Channel whenever I try to Save to Logger. ![5cb99856312ed](serve/attachment&amp;path=5cb99856312ed) Adding this manual channel &ldquo;TestDashNo&rdquo; causes the error message below. ![5cb99874a9405](serve/attachment&amp;path=5cb99874a9405) RG&quot;OneHourTimer&quot;(&quot;b:&quot;,ALARMS:OV:100KB:W60,DATA:OV:1MB)1H LOGOFFG CALC(&quot;Increment~&quot;,LM)=8CV=8CV+1 &#039; User defined IF(3DS==1) AND IF(8CV==15){XH} RH&quot;TestComplete&quot;(&quot;b:&quot;,ALARMS:OV:100KB:W60,DATA:OV:1MB)5S LOGOFFH ALARM((CALC(&quot;SendEmail~&quot;,LM)=8CV=0)&lt;0)&quot;The Test is Complete&quot;[mailto:fiorio@naii.com?priority=high&amp;interface=ETHERNET&amp;subject=&quot;Test Complete&quot;]{} Thanks

Hi FrankI,

Fortunately you have a screenshot at the right place (otherwise it will be difficult for me to determine your problem). smile

When you write a multiple condition IF with logical operator AND, you cannot use a space between close bracket and AND.
IF(3DS==1)AND IF.....

Best regards,
Rudy Gunawan

Hi FrankI, Fortunately you have a screenshot at the right place (otherwise it will be difficult for me to determine your problem). :smile: When you write a multiple condition IF with logical operator AND, you cannot use a space between close bracket and AND. IF(3DS==1)AND IF..... Best regards, Rudy Gunawan

Rudy,

Please see attached. Almost there, but I can't get the email to fire other than when the job first starts up. On start up the criteria of 4 or 8 should not be met. Also when the email is sent out, it doesn't reset the counter (8CV)

Schedule A – Read Front Panel Switches and store in 9CV to determine Product Type
Schedule B – Test Product Type and set terminal count (4 or 8) is TRUE fire schedule D or E
Schedule C – Increment variable “8CV” every hour (25seconds for debug)
Schedule D - Send Product 1 email and reset “hour counter” (I’d like to halt all schedules here)
Schedule E - Send Product 2 email and reset “hour counter” (I’d like to halt all schedules here)

BEGIN"config"

RS1S

RA"ReadSwitches"("b:",ALARMS:OV:100KB:W60,DATA:OV:1MB)5S
LOGONA
1DN("ReadANibble",=9CV,LM,15)

RB"TestProductType"("b:",ALARMS:OV:100KB:W60,DATA:OV:1MB)5S
LOGONB
' User defined
IF(3DS==1)AND IF(8CV==4){XD}
IF(3DS==0)AND IF(8CV==8){XE}

RC"OneHourTimer"("b:",ALARMS:OV:100KB:W60,DATA:OV:1MB)25S
LOGONC
' User defined
8CV=8CV+1

RD"05TestComplete"("b:",ALARMS:OV:100KB:W60,DATA:OV:1MB)5S
LOGOND
ALARM1((CALC("Send05Email~",LM)=1)>0/1S)"Event triggered on Logger ! at @ on #, ?N value is ?V ?U."[mailto:fiorio@naii.com?priority=high&interface=ETHERNET&subject="05 Test Complete"]{8CV=0;}

RE"03TestComplete"("b:",ALARMS:OV:100KB:W60,DATA:OV:1MB)5S
LOGONE
ALARM1((CALC("Send03Email~",LM)=1)>0/1S)"Event triggered on Logger ! at @ on #, ?N value is ?V ?U."[mailto:fiorio@naii.com?priority=high&interface=ETHERNET&subject="03 Test Complete"]{8CV=0;}
END

Thanks in advance for your help.

Rudy, Please see attached. Almost there, but I can&#039;t get the email to fire other than when the job first starts up. On start up the criteria of 4 or 8 should not be met. Also when the email is sent out, it doesn&#039;t reset the counter (8CV) Schedule A &ndash; Read Front Panel Switches and store in 9CV to determine Product Type Schedule B &ndash; Test Product Type and set terminal count (4 or 8) is TRUE fire schedule D or E Schedule C &ndash; Increment variable &ldquo;8CV&rdquo; every hour (25seconds for debug) Schedule D - Send Product 1 email and reset &ldquo;hour counter&rdquo; (I&rsquo;d like to halt all schedules here) Schedule E - Send Product 2 email and reset &ldquo;hour counter&rdquo; (I&rsquo;d like to halt all schedules here) BEGIN&quot;config&quot; RS1S RA&quot;ReadSwitches&quot;(&quot;b:&quot;,ALARMS:OV:100KB:W60,DATA:OV:1MB)5S LOGONA 1DN(&quot;ReadANibble&quot;,=9CV,LM,15) RB&quot;TestProductType&quot;(&quot;b:&quot;,ALARMS:OV:100KB:W60,DATA:OV:1MB)5S LOGONB &#039; User defined IF(3DS==1)AND IF(8CV==4){XD} IF(3DS==0)AND IF(8CV==8){XE} RC&quot;OneHourTimer&quot;(&quot;b:&quot;,ALARMS:OV:100KB:W60,DATA:OV:1MB)25S LOGONC &#039; User defined 8CV=8CV+1 RD&quot;05TestComplete&quot;(&quot;b:&quot;,ALARMS:OV:100KB:W60,DATA:OV:1MB)5S LOGOND ALARM1((CALC(&quot;Send05Email~&quot;,LM)=1)&gt;0/1S)&quot;Event triggered on Logger ! at @ on #, ?N value is ?V ?U.&quot;[mailto:fiorio@naii.com?priority=high&amp;interface=ETHERNET&amp;subject=&quot;05 Test Complete&quot;]{8CV=0;} RE&quot;03TestComplete&quot;(&quot;b:&quot;,ALARMS:OV:100KB:W60,DATA:OV:1MB)5S LOGONE ALARM1((CALC(&quot;Send03Email~&quot;,LM)=1)&gt;0/1S)&quot;Event triggered on Logger ! at @ on #, ?N value is ?V ?U.&quot;[mailto:fiorio@naii.com?priority=high&amp;interface=ETHERNET&amp;subject=&quot;03 Test Complete&quot;]{8CV=0;} END Thanks in advance for your help.

Hi FrankI

I saw your code.
You should not set time interval on schedule D and E.
This will cause these schedule to send email the moment you start the program and lose the link to schedule B.

To enable polled schedule you should use X as your interval (replace 5S with X)
RD"05TestComplete"("b:",ALARMS:OV:100KB:W60,DATA:OV:1MB)X

Polled schedule means the schedule will not run until you issue a command.
Example:
RAX will only run with XA command

In dEX, you will need to access the third schedule option "Advance Triggering" and choose Trigger manually.

Best regards,
Rudy Gunawan

Hi FrankI I saw your code. You should not set time interval on schedule D and E. This will cause these schedule to send email the moment you start the program and lose the link to schedule B. To enable polled schedule you should use X as your interval (replace 5S with X) RD&quot;05TestComplete&quot;(&quot;b:&quot;,ALARMS:OV:100KB:W60,DATA:OV:1MB)X Polled schedule means the schedule will not run until you issue a command. Example: RAX will only run with XA command In dEX, you will need to access the third schedule option &quot;Advance Triggering&quot; and choose Trigger manually. Best regards, Rudy Gunawan
43
7
2
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft