ArrayArrayArrayArrayArray BrainModular BrainModular Users Forum 2011-08-31T18:22:54+02:00 https://brainmodular.com/forums/app.php/feed/topic/3111 2011-08-31T18:22:54+02:00 2011-08-31T18:22:54+02:00 https://brainmodular.com/forums/viewtopic.php?t=3111&p=21041#p21041 <![CDATA[New sript issue]]>
//////////////////////////
// Test
/////////////////////////
// parameters declaration

Var InA : tParameter;
Var OutA : tParameter;

// initialisation : create parameters
procedure init;
begin

InA := Createparam('Entrée', ptButton);
SetIsOutput(InA, False);
OutA := Createparam('Sortie', PtButton);
SetIsInput(OutA, False);

end;

//////////////////////////////
// main proc
//////////////////////////////
Procedure Process;
begin
If Getvalue (InA)= 1 then SetValue (OutA,1);
If Getvalue (InA)= 0 then SetValue (OutA,0);
end;

Statistics: Posted by Ken29 — 31 Aug 2011, 18:22


]]>
2011-08-31T13:44:26+02:00 2011-08-31T13:44:26+02:00 https://brainmodular.com/forums/viewtopic.php?t=3111&p=21038#p21038 <![CDATA[New sript issue]]> the toggle module work this way, each time he receive an impulsion (like button) he toggle, this mean he change the value
if you use a switch with a fixed value your force the module to always toggle..?

Statistics: Posted by nay-seven — 31 Aug 2011, 13:44


]]>
2011-08-31T13:16:30+02:00 2011-08-31T13:16:30+02:00 https://brainmodular.com/forums/viewtopic.php?t=3111&p=21037#p21037 <![CDATA[New sript issue]]>
You're right, I've just add a switch to a toggle and tried. When the switch goes to 1, toggle out should be 1, then the switch goes to 0 and then to 1 again, the toggle out should be 0. But it doesn't work and I don't understand why.

Kenan

Statistics: Posted by Ken29 — 31 Aug 2011, 13:16


]]>
2011-08-30T23:38:03+02:00 2011-08-30T23:38:03+02:00 https://brainmodular.com/forums/viewtopic.php?t=3111&p=21033#p21033 <![CDATA[New sript issue]]> as the toggle module receive 1, he toggle..
and as long as it receives a 1 he will toggle

Statistics: Posted by nay-seven — 30 Aug 2011, 23:38


]]>
2011-08-30T23:00:45+02:00 2011-08-30T23:00:45+02:00 https://brainmodular.com/forums/viewtopic.php?t=3111&p=21032#p21032 <![CDATA[New sript issue]]>
I'm trying to get better in the art of scripting. I have this problem I do not understand...

Image

On this simple patch, when the "switch" change from 0 to 1, "data out" change from 0 to 1 but not the Toggle... Here's the script. Thanks

//////////////////////////
// Changement de nom
/////////////////////////
// parameters declaration

Var InA : tParameter;
Var OutA : tParameter;

// initialisation : create parameters
procedure init;
begin

InA := Createparam('Entrée', ptSwitch);
SetIsOutput(InA, False);
OutA := Createparam('Sortie', PtButton);
SetIsInput(OutA, False);

end;

//////////////////////////////
// main proc
//////////////////////////////
Procedure Process;
begin
If Getvalue (InA)= 1 then SetValue (OutA,1);
If Getvalue (InA)= 0 then SetValue (OutA,0);
end;

Statistics: Posted by Ken29 — 30 Aug 2011, 23:00


]]>
BrainModular BrainModular Users Forum 2011-08-31T18:22:54+02:00 https://brainmodular.com/forums/app.php/feed/topic/3111 2011-08-31T18:22:54+02:00 2011-08-31T18:22:54+02:00 https://brainmodular.com/forums/viewtopic.php?t=3111&p=21041#p21041 <![CDATA[New sript issue]]>
//////////////////////////
// Test
/////////////////////////
// parameters declaration

Var InA : tParameter;
Var OutA : tParameter;

// initialisation : create parameters
procedure init;
begin

InA := Createparam('Entrée', ptButton);
SetIsOutput(InA, False);
OutA := Createparam('Sortie', PtButton);
SetIsInput(OutA, False);

end;

//////////////////////////////
// main proc
//////////////////////////////
Procedure Process;
begin
If Getvalue (InA)= 1 then SetValue (OutA,1);
If Getvalue (InA)= 0 then SetValue (OutA,0);
end;

Statistics: Posted by Ken29 — 31 Aug 2011, 18:22


]]>
2011-08-31T13:44:26+02:00 2011-08-31T13:44:26+02:00 https://brainmodular.com/forums/viewtopic.php?t=3111&p=21038#p21038 <![CDATA[New sript issue]]> the toggle module work this way, each time he receive an impulsion (like button) he toggle, this mean he change the value
if you use a switch with a fixed value your force the module to always toggle..?

Statistics: Posted by nay-seven — 31 Aug 2011, 13:44


]]>
2011-08-31T13:16:30+02:00 2011-08-31T13:16:30+02:00 https://brainmodular.com/forums/viewtopic.php?t=3111&p=21037#p21037 <![CDATA[New sript issue]]>
You're right, I've just add a switch to a toggle and tried. When the switch goes to 1, toggle out should be 1, then the switch goes to 0 and then to 1 again, the toggle out should be 0. But it doesn't work and I don't understand why.

Kenan

Statistics: Posted by Ken29 — 31 Aug 2011, 13:16


]]>
2011-08-30T23:38:03+02:00 2011-08-30T23:38:03+02:00 https://brainmodular.com/forums/viewtopic.php?t=3111&p=21033#p21033 <![CDATA[New sript issue]]> as the toggle module receive 1, he toggle..
and as long as it receives a 1 he will toggle

Statistics: Posted by nay-seven — 30 Aug 2011, 23:38


]]>
2011-08-30T23:00:45+02:00 2011-08-30T23:00:45+02:00 https://brainmodular.com/forums/viewtopic.php?t=3111&p=21032#p21032 <![CDATA[New sript issue]]>
I'm trying to get better in the art of scripting. I have this problem I do not understand...

Image

On this simple patch, when the "switch" change from 0 to 1, "data out" change from 0 to 1 but not the Toggle... Here's the script. Thanks

//////////////////////////
// Changement de nom
/////////////////////////
// parameters declaration

Var InA : tParameter;
Var OutA : tParameter;

// initialisation : create parameters
procedure init;
begin

InA := Createparam('Entrée', ptSwitch);
SetIsOutput(InA, False);
OutA := Createparam('Sortie', PtButton);
SetIsInput(OutA, False);

end;

//////////////////////////////
// main proc
//////////////////////////////
Procedure Process;
begin
If Getvalue (InA)= 1 then SetValue (OutA,1);
If Getvalue (InA)= 0 then SetValue (OutA,0);
end;

Statistics: Posted by Ken29 — 30 Aug 2011, 23:00


]]>