Control logix Job posting of sorts..

DanYost said:
So you have 7 integers, each being a portion of time and you want to log it in hh:mm:ss and MM//DD//YYYY?

I have attached an example file (just rename it as a .cd2 file) that takes your time variables and converts them to a string. You can then log that string. I used programs that accept arguments and return a value so you only need the 2 programs no matter how many of these items you need.

Regards,
Dan

Dan..when i try and enter my string it tells me unknown function "TimeString"......

(I see your was created for a G310..mine is for DSPGT..not sure if it makes a difference...).....


thanks

D
 
OK...i have it working..and everything looks good..one thing is bugging me...

can someone please explain the line of programming that Dan used?

return IntToText(Arg1, 10, 2) + ":" + IntToText(Arg2, 10, 2) + ":" + IntToText(Arg3, 10, 2);



First..the Return?

second..the IntToText..i understand..turning an int to a "string"...now the argument radix and count i do not understand where those numbers came from..


the rest i do get..

*** Update...i now understand where the numbers come from! (a little bit of reading goes along way!) base 10 2 digits long..now for the arguments...


Thanks

D
 
Last edited:
Sorry for the delay, I was on vacation since last Thursday.

The return is used to have the program return a value. This is done so the program does not need to run all of the time.

The arguments are setup at the bottom of the program. This was done to need only 1 program regardless of how many start time items you have. It just assumes that the first argument is hours, as it uses that as the hour portion of the string it returns. The second is the minutes, and finally the seconds.

You could just as easly run a program On Tick that does something like:

StringTime = IntToText(Hoiurs, 10, 2) + ":" + IntToText(Minutes, 10, 2) + ":" + IntToText(Seconds, 10, 2);

But if you have more than 1 string you need to build like that, then you need a program for each one.

Hopefully that helps.

Regards,
Dan
 

Similar Topics

I am having trouble with getting no control of my analog output signal. I am using the SCL function block to control my analog output. The logic...
Replies
11
Views
253
hi all, i have a plc i need to get info from for a site im working on: I have a 1764 Micro Logix 1500 LSP Series C (See Attached Image) im...
Replies
2
Views
380
I currently have a weird issue involving Ethernet IP communication between a ABB CI873 (EthernetIP Module) and a 1756-L83ES. The Layout is as...
Replies
8
Views
761
Possible for two processors in same rack to have separate motion groups across a single Kinetix Rack using a single EN3TR? One 6500/5700 rack, 8...
Replies
1
Views
426
Hi all! I am hoping to find some help understanding the ABB VFD Connection to my Rockwell PLC. I have set up the VFD parameters based on...
Replies
4
Views
670
Back
Top Bottom