SoMachine Basic Loop

Beau79AU

Member
Join Date
Feb 2018
Location
NSW
Posts
11
Hi, can anyone please help with logic for looping in SoMachine basic? I have a hopper that i need to open and close a valve until it reaches a certain weight.

Thanks.
 
Welcome to the PLCTalk forum community !

In general, most PLC operating systems run designated programs repeatedly, in a constant "loop" or "scan". You don't have to do jumps or GOTO statements, but rather simply configure the routines to be executed by a repeating operating system task.

What model of Schneider controller are you using ?

My understanding is the SoMachine Basic is essentially a re-skinned version of CoDeSys, so you're going to have Tasks, and you're going to put your ladder logic routine (POU, in CoDeSys terminology) into one of those.

Describe your programming challenge in as much detail as you can, and practice with making screenshots with the Windows Snipping tool, then cropping them and attaching them to your posts as PNG files.
 
Im using an M221 controller. I have a hopper on load cells, receiving a 0-10v signal. I need to open the valve to release a bulk lot of material until it reaches a slow feed weight, then open and close the valve on 3 sec intervals until it reaches the final weight. I have the bulk section sorted i just need to do the last slow feed. I have attached what i have for the bulk side. Please note MF0 is just a dummy for the analog input for using in the simulator.
 
I have come up with the attached. When i do not have the Final Dumps POU, it works. The valve opens until i get below the weight it is set for. But as soon as the Final Dumps POU is added the valve wont open at all.

SNIP1.jpg SNIP2.jpg SNIP3.jpg
 
I have managed to get it to work with the attached, however i am having to use 2 outputs to open same valve, one output to open and close in the bulk dump and then another output to open and close on the light dumps. When i try to use the one output it does not open and close. Is there any way to use the one output?

Thanks.

SNIP1.jpg SNIP2.jpg SNIP3.jpg
 

Similar Topics

Hi all, I've been trying to develop modbus rtu program between uv balasts and plc ı'have 6 slave balast.I am reading fault run voltages etc...
Replies
0
Views
1,168
hello eveyrone I want to make an application with M221 PLC in SOMACHINE BASIC program. I request your valuable help. I have a 50 ms pulse...
Replies
1
Views
1,581
Hi Guys, I'm using M221(TM221CE24R) PLC and SoMachine Basic from Schneider and having a bit of problem. 1. I can't able to read the data from...
Replies
1
Views
1,729
Hello, I am new to plc programming. I am trying to program a flow meter (E&H promag 50) in somachine basic to achieve the following: 1...
Replies
5
Views
2,370
I downloaded SoMachine Basic, I'm looking to maybe use an M241 in an upcoming project. It seems that the basic vs, doesn't offer Tag based...
Replies
2
Views
3,011
Back
Top Bottom