Jump to content

Recommended Posts

I can find no information on the string function usage. This seems to be not included in the manual.

I need to do string manipulation.

Sifting thru all of the internet for answers is making me not happy again.

Time is money.

If someone out there has this information could you please post it.

Thank you in advance.

Edited by Russ Is Not Happy Again
Had more to say

Share this post


Link to post
Share on other sites

Yes, I'm not happy about that missing from the Help, either.

I have found answers to a lot of questions UniLogic functions in the UniLogic Examples.  I'd highly suggest downloading them:

https://unitronicsplc.com/Download/Support/UniLogic/UniLogic_Example_Projects.zip

I have attached one of the examples from the "Strings" directory.

Which block are you having trouble with?

Joe T.

UniStream_070_String_Tools.ulpr

Share this post


Link to post
Share on other sites

Thanks Joe

After some experimentation I got my string manipulation to work.

I am a first time user of Unitronics. I come from the Allen Bradly word. My old bag of tricks don't work well in Unistream world. I get frustrated!!

I have been using the sample files. They help some. But I still find the instruction set a bit lacking on information.

For instance, The documentation did not indicate that not only will the "Store DTI to File" instruction create my .csv file but also a .csv.zip file.

I needed to append the date and time to end of the customers job name. I need a unique file name that I can use to save shift production data to a memory stick.

So this happened.

I take from the customers spreadsheet the job name as found, (5/4 x 8 Rab Trim w Window and Side Pocket)

Correct for the slash and add date and time for this as my file name, (5_4 x 8 Rab Trim w Window and Side Pocket 8-17-19_11-30AM)

Add the extension, (5_4 x 8 Rab Trim w Window and Side Pocket 8-17-19_11-30AM.csv) 61 characters, I made it under the limit.

But this really happens in the instruction unknown to me, (5_4 x 8 Rab Trim w Window and Side Pocket 8-17-19_11-30AM.csv.zip)

If somebody would have just said you also getting a .zip file I could have saved my self a couple of hours figuring it out the hard way.

Now, do you know of a way to make a LIFO Stack not get full. I cant believe this instruction does not have an unload word at it's natural end.

Thanks

 

 

 

Share this post


Link to post
Share on other sites

I've programmed many PLC brands, including Allen Bradly back to the PLC 5.  I still do and have a current Tech Connect Contract.  And I still get sticker shock if the end user specifies it must be an AB system.  If AB is all you've ever known I can totally understand your frustration.  The $3K RSLogix 5000 buy-in and the $900 annual country club dues go a long way for paying for a deep and thorough support system.

UniLogic is a very different and powerful animal.  It's still evolving.  

<rant>

Strings and CSV Files and VNC! Oh, my!  The real challenge is that many people are now demanding that their Programmable Logic Controllers act like a PC.  But still program in ladder logic.  Without nice features like included libraries for complex functions or API calls.  So they come up with function blocks that try to cover the bases faster than their limited Technical Writing Staff can document everything.  Test it.  Ship it.  Invoice it.  We'll document it later.  This is not unusual in the corporate world.  Somehow we've got to pay those R&D people.

With all that, UniLogic is still free and the UniStream is a really good bang for the buck.  There's just pain from time to time.

</rant>

11 hours ago, Russ Is Not Happy Again said:

Now, do you know of a way to make a LIFO Stack not get full. I cant believe this instruction does not have an unload word at it's natural end.

I'm guessing you already know that data tables are the easiest way to make a stack.  If you use a DTI type data table and use the Insert Row to DTI instruction and insert your new data struct at row 0 it will push all the data down and drop the bottom one off.  

Is this what you're trying to do?

Joe T.

Share this post


Link to post
Share on other sites

Thanks Joe

I did find the DTI Insert instruction. That let me buffer data while I let the real save to file instruction execute. I'm writing 3600 row files and I didn't want to chance data loss during the save.

I've been on many PLC platforms During the course of my career. Got my feet wet on Texas Instruments 5TI Sequencer. You Haven't lived until you lugged an Allen Bradley 1770-TA thru an airport. Then ICOM came along and solved that.

I just revealed my age. Dammit

Anyway, Long story short. My predecessor for this project dropped the ball. I started 2 weeks behind. But I think I'm 90% done.

It's been an adventure.

On the HMI side I just built the ugliest thing I ever built. There has to be a better way. I miss embedded variables, Maybe a drop down list. I don't know.

I end up with 17 screens to get the customer to the part they wish to run. UGLY!! - I HATE IT!! - TOOK WAY TO LONG TO BUILD!!

When I am in the HMI side I can see this layers thing. What are they and how do you use them.

I could ask a million questions.

Thanks for you time Joe

Russ @maybe a little bit happier now .wtf

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...