FSM Quardruple Limitation

Hi!

Two little questions regarding vvvv’s Automata concept:

  1. How to implement boolean AND for transitions? Meaning, two or more events have to happen simultaneously to fulfill a condition and lead to the next step.

  2. How to generate multiple output bangs from one single action?

Thanks in advance!
Sven

Hi guest,

Not sure I can answer these questions in regards to Automata (Animation) but maybe process-(animation) from tonfilm can help you?

why not do the AND in the patch?

Hmm… Looks like I fell for some evil advertising…

Quote from help patch: "Graphical programming is fine for data flow, but it gets in your way when dealing with complex if-then-else structures evolving over time. Sooner or later your patches tend to have counters, flipflops, framedelays and lots of logic nodes.
The main idea of the automata node within vvvv is being able to distill complex logic into a textual description into one node."

But how? I really don’t get it - maybe I’m a bit dumb, but to me it seems like as soon as the system gets a bit more complex I’m forced to outsource most of the logic elements, switches etc…
Been playing around with Qfsm as well but it only supports my assumption that the whole approach is actually not suitable for implementing really complex flowcharts.

I did some really basic state machines from qfsm to vvvv ages ago, but also had the same feeling that I was maybe missing something or not using it properly. Would really love to see some advanced tutorials on this topic.

in all of my latest bigger interactive projects automata was the main control unit. the patch structure was like this:

user inputs -> logic -> graphical elements

it is always the best to do a strict destinction between the logic and the graphics in a big patch. that means you have one complicated patch with an automata, which processes the real world input and has all states your patch can be in. from this patch you have many outputs that fade, enable or move all of your graphical elements. you can also just send the current automata state and receive it where ever you need to react on it.

i find it rather comfortable to layout the state logic in qfsm. of course you don’t do all tiny animation state changes with it, but the global menu logic and such things.

what tf said.

Thanks, but now how would I deal with my two opening questions?
I have the suspicion that this only works for very simple interactions with singular inputs (one keypad, one sensor etc…), and few conditions. But, as everyoneishappy said, I as well might be missing something.
A little example Qfsm chart covering the problem outlined above might help a lot I think.

To make things a bit clearer, here is a simple example setup:

  • 2 possible states (State 1, State 2)
  • 3 Transitions (In A,In B, In C)
  • 2 Outputs (Out X, Out Y)

3 rules of interaction:

  1. In A toggles between both states
  2. If, at any time, In A and In B are triggered simultaneously not only the state toggles but also Out X sends a bang
  3. If, at any time, In A and In C are triggered simultaneously not only the state toggles but also both Out X and Out Y send bangs

I would love to see this outlined in Qfsm as I’m sure this would make things a lot easier to handle and overview. But is it possible?

P.s.: Sorry for the typo in this threads headline…

as i dont know if it is possible to do this in qfsm(im used to it but never saw a boolean function) i suggest you to create a separate input for your automata.
like for simultaneously and . I think its easy to check simultaneous inputs and generate an input for qfsm within vvvv.

sven, is this the kind of behaviour you’re describing? From what I understand it’s really easy to do with 4 nodes and a few IOBoxes.

auto.v4p (8.7 kB)

I’m pretty sure sven could manage to patch this if he wanted :) Would still be really nice to know what the optimal way to approach this example with automata would be though

Ah ok, I guess you can always do it a different way out of preference. Wasn’t sure if this was actually a question of ‘help me do this in vvvv’ or just ‘is it possible to make a patch in this particular way?’.

@bjoern, where is that big picture? i’v seen it tonight… or is my dns buggy?

Mh I removed it because it isn’t really helping svens’ question. Only wanted to somehow illustrate that it is possible to use automata to deal with complex logic.

all things are said i guess, so there are two ways to do it… with a toggle like automata and it looks like the patch from Lightmare or you include the outputs in the automata:

sven automata.v4p (30.8 kB)

Hey guys, thanks for all the feedback!
I had a long conversation with our in-house mathematician yesterday and finally got the picture…
To make a long story short: It is possible to implement my example with vvvv’s Automata, but it doesn’t make sense because it’s far too complicated.
In fact, the only logic operation an automata is capable of is “branching”. This means, when designing a circuit, I would need to manually foresee every possible combination of events a user might generate and create a discrete transition for each of them!
Tonfilms diagram (the lower one) illustrates that pretty well.
Additionally one would also need to check for any exception a user might trigger and define an error state for it, but in vvvv’s context this isn’t necessary anyways.
So basically one could agree with the claim that “the automata node within vvvv is being able to distill complex logic into a textual description” - in theory. But it’s absolute nonsense to do so if the possible use cases of your patch are seriously complex.
Actually a smart mixture of predefined automata states and external logic elements (talking about some boolean operations, switches and the like) would probably, in most cases, do the best job.
Still the mentioned recommendation in automata’s help patch to actually implement your logic into one automata node is in a way misleading, especially for unexperienced users.
But again: Thanks for your help to shed some light on this interesting topic!

Automata certainly has it’s uses, but more often then not I prefer to use a simple “State” system that doesn’t require Automata.

Please see attached for a basic example.

State Patching.zip (24.0 kB)