How to Create a Pulse Stream using Siemens TIA Portal WITHOUT Clock Memory!

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
what's going on everybody and welcome back to another video today we're gonna be having a look at how to create a poll stream inside of a siemens s7 1200 PLC using Siemens TIAA portal without using the clock memory that's already been pre assigned to the PLC now the reason why we might want to do that is because we might be work with a PLC that doesn't have the ability to have clocked memory assigned to it so how do we do it when we don't have that facility well we'll show you in this video now before we can actually get started what I like you to do is give the video like comment below let me know you're watching and if you're watching us on youtube hit the subscribe button if you're not watching us on YouTube go over to YouTube now and hit the subscribe button anyways it helps us out a lot and I thank you for doing so anyways let's get back to the day's video all right so I've got Siemens Ti portal open already and what I'm gonna do is I'm just gonna create a brand new project and then what we're gonna do is set up the hardware configuration and setup clock memory inside of the PLC and just show you how we actually set that up first of all but we're not gonna use it what we're then gonna do is jump into ob1 and then actually create that clock memory using lana logic just in case we don't have clock memory available in the plc or we're working with so first so I'm just gonna give this a name I'm just gonna call this Chris pulse stream program and I'm just gonna then say create I'm not gonna go too in depth of how we actually create the project that there is covered on other videos if you just go to our YouTube channel you'll see how to create a Siemens Ti a portal program from scratch you can just watch that video there so here we're just gonna select configure a device add new device and then what we're gonna do is I'm just gonna have the laptop pull up the information from the PLC in terms of its hardware so do this just an organ unspecified CPU select the PLC that we're working with and just selected as a version 3 as that's the PLC that I've got over here that's connect to the laptop I'm then just gonna say add and then what they will do is will then open up our hardware configuration with the blank CPU I'm then gonna upload that system information from our PLC into the laptop so there we go you'll see now we've got a yellow notification I'm just gonna say detect and it'll then open up our Hardware detection and now what it's gonna do is using our Ethernet cable here it's then gonna hunt out that PLC that's on this Ethernet network and there it is there and you'll notice the IP address 192.168.1.1 our laptop is currently set to 192.168.1.5 I'm then gonna select detect and what it's now going to do like I mentioned before it's going to upload our hardware information into this PLC program right now that that's done what we're going to do first of all is set up the actual clock memory itself and to do this beginning the double-click on the CPU or we can right click and go to properties and a bottom window pin will open up here and on the left hand side oh just halfway down is an area called system o'clock member if we just select that you actually see here system memory bit and clock memory this we're going to ignore system memory bits and we're gonna go down to clock memory better you'll notice that it's not selected it's not enabled now this means that no clock memory is being assigned to the CPU what I'm gonna do here is I'm gonna check this box which will now enable clock memory once we download this project to the PLC and you'll see inside of here address of clock memory byte is set to 0 which means memory byte 0 M 0.02 M 0.7 is now assigned to clock frequencies what a clock frequency is it's simply just a bit that will turn on and off in a set clock frequency so you can see here we've got M 0 dot 0 as our 10 Hertz clock pulse M 0 dot 1 is our 5 Hertz clock pulse M 0.5 is our 1 Hertz clock pulse our 1 second clock pulse all the way down to M 0 dot 7 which is our half Hertz clock pulse now what you can't do is you can actually change this memory but you do have to keep it at zero to change it and just click inside the box and type in another value let's say 20 for example and then say enter and the bits will actually change inside of the clock memory you've got to be careful when you're working with this what you don't want to do is just modify the clock memory to any round the memory byte because that memory byte might already be used inside of the program and what you don't want to do is set that up to now be clock memory and then have your outputs flashing on and off every half a second because that's what you've set it to inside of the clock memory itself you've got to be careful when you're working with this now I'm currently just gonna leave this unchecked because we're not going to use the clock memory that's the easy way out what we're gonna do is we're gonna show you how to create a pulse stream using Lara logic because that our PLC's out there which don't have the functionality of clock memory so how would we do it when we don't have access to these bits well what we could do is we can then open up our program blocks open up ob1 and write a program now the way that I want this program to work is I'm gonna have a contact here and my contact is gonna be tighter m 0.0 which is gonna be my enable signal and what I want this enable signal to do is when it's on my output coil will turn on from one second off for one second on for one second off for one second and it's gonna keep on repeating that process on off on off on off until M 0 dot 0 turns off I'm just gonna rename this tag I'm just going to call it enable and then say it change now if I just add in here my output coil and I'll tie this to cue 0.0 and I just left it at that that's not going to work what's going to happen here is when M 0 dot 0 turns on so is Q 0 dot 0 and that's it what I need to do is I need to have some sort of instruction that's gonna create a delay from turning it on and it's delayed for turning it off how do we create delay well I hope everybody said timers we can use a timer so what I want to do is I want to drop down our timer operations and I want the drag and drop our T o n in between the contact and the coil it's gonna ask me for a date a block I'm just gonna select that date a block them just gonna leave it as default that's fine and then what I'm gonna do is I'm gonna create another timer so what this will allow me to do is it'll give me a timer for the on period and a timer for the off period I'm then gonna branch down again create a normally open contact and then drag my coil into that third room so what we've got so far is our enable signal controlling two timers we then have a contact controlling our output now what I'm going to do is I'm going to tie this contact here to the output of my first timer so to do this just double click inside of the address drop down the little menu icon and I'm gonna look for my first time which is DB 1 expand that and select a queue there we go now what I'm gonna do here is I'm gonna have our timers controlling each other I want this timer DB 1 first of all to run as soon as our enable signal turns on and then want that timer to then control our second timer after it's finished so to do that we're just going to put a normally closed contact before this timer and a normally open contact before this timer here now what we need to do is assign these to the opposite timers don't worry it'll all make sense once we start but run it and I'll start to explain how this works so for this I'm just gonna drop this menu down select my second timer and select it's queue there we go and for this contact I'm going to tie this to the first timer and select it's cute and that there is effectively the program designed so how is this going to work well when the enable signal turns on this contact will close and because these two timers are off these contacts here will remain in their default State so this contact will be closed and these two contacts will be open meaning this timer will begin to run and our output coil is currently off the timer will run for one second and then after one second it'll then turn on and enclose both of these contacts this contact will then turn on our output so it's gonna run for one second and then turn on our output and then what its gonna do is wait another second after the second timer has elapsed one second later what it will do is then turn on its output which will open this contact here therefore turning off our first timer turning off these two contacts here turning off my output coil turning off my second timer turning off this contact here turning off my second timer which therefore resets my entire network back to zero the output will now be off this contact will be closed again it'll run this timer for another second after the second has elapsed these two contacts will turn on turning on my output coil running my second timer again my second time will run for a further 1 second after that it'll reset everything back to zero again so let's save our work and then what we're gonna do is download this to the PLC and what I'm gonna do is I'm gonna right click my neighbour flag and then modify to 1 when I modified the one watch my cue 0.0 here it'll remain off for one second then it will turn on for 1 second then it'll turn off for 1 second then it will turn on for one second and I'll keep on repeating as long as our enable signal is on and there we go it begins to flash so like I say what's happening here is we're having these two timers controlling the on and the off state so like I say initially both timers are going to be off that means that all of these contacts will be in their default state allowing this timer to begin to run as you can see there after the one second is elapsed it'll then turn on these two contacts and turn on this timer allowing it to run for one second creating that on period of one second whilst turning on my output coil after the one second that it's been on for this timer then turns on opening this contact here which therefore resets this entire network back to zero closing this contact and allowing this timer to run again for a further one second now how do we create a pulse stream for two seconds three seconds four seconds half a second all we do is we modify the two timer values so instead of us having it for one second we would then change that to half a second would then change it for two seconds three seconds and this now gives us complete flexibility because if I want this to be off for three seconds on for two seconds I can just change the individual timers if I just come offline here select yes and if I say I wanted to be off for three seconds I would change this timer here to three seconds as this is controlling this contact which controls the output turning on and then after the three seconds I wanted to run for two seconds so I set the second time at the two seconds which controls the on period save that work there download that to the PLC so it's currently on one two one two three one two one two three and that's it that's our pulse stream designed inside of a PLC without using the actual clock memory it gives us a lot more flexibility as well because clock memory is on and off for the same time so if we want to have a variant on time to our off time all we would do is just change our two timers and this gives us the ability to do this now that design there is universal to all PLC's so we can design this in Seema's carry port or we can design it in step seven we can then transfer it over to rslogix 500 or studio 5000 Mitsubishi GX works to this design here will work in every PLC so if your PLC doesn't have the functionality of memory built internally then all we need to do is just create it using lana logic using two timers and that's it guys I hope you've enjoyed this quick tutorial of how to create a pulse stream using Lara logic and I hope to see you again next time enjoy your week
Info
Channel: Scantime Automation & Training
Views: 3,246
Rating: undefined out of 5
Keywords: scantime, siemens, tia portal, step7 professional, clock memory, plc training, plc courses, mitsubishi, omron, keyence, schneider, allen braldey, ladder logic
Id: Xi8fBHD5p7k
Channel Id: undefined
Length: 13min 24sec (804 seconds)
Published: Fri Jul 17 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.