Support

If you have a problem or need to report a bug please email : support@dsprobotics.com

There are 3 sections to this support area:

DOWNLOADS: access to product manuals, support files and drivers

HELP & INFORMATION: tutorials and example files for learning or finding pre-made modules for your projects

USER FORUMS: meet with other users and exchange ideas, you can also get help and assistance here

NEW REGISTRATIONS - please contact us if you wish to register on the forum

Users are reminded of the forum rules they sign up to which prohibits any activity that violates any laws including posting material covered by copyright

incorrect trigger behavior, possible a bug

For general discussion related FlowStone

incorrect trigger behavior, possible a bug

Postby tester » Fri Mar 08, 2013 12:29 am

Here is following problem.

"Text Load" primitive should open a text file from relative path (important) when app/schematic starts. "After Load" primitive shows, that trigger is sent. But nothing is loaded. Manual trigger shows, that this text can be loaded from the relative path.

I tried it in various ways, even with links order (first - refresh the string presence, second - load), but nothing seems to work. Even if the trigger order is correct (see test 2; direction of log is from up to down). So - what is the problem here? How it can be solved?
Attachments
trigger-problem-test2.zip
(5.09 KiB) Downloaded 914 times
trigger-problem.zip
(4.98 KiB) Downloaded 951 times
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
tester
 
Posts: 1786
Joined: Wed Jan 18, 2012 10:52 pm
Location: Poland, internet

Re: incorrect trigger behavior, possible a bug

Postby trogluddite » Fri Mar 08, 2013 12:51 am

There's no bug - loading from the relative path is an undocumented "feature" which is not to be relied on. The lfile primitive and component guide explicitly state that the full path should be used (for reliability). Though it must be said, relative loading would be rather more convenient much of the time (maybe a bool input on the prim'' to choose).

You'll need to use the "start folder" primitive to construct the full file path - that will work for .exe and .dll exports reliably Note that the '\' symbol needs adding between the folder and filename as the folder path is 'bare'.
But it does have one sometimes annoying quirk - it doesn't work when you're inside FS, you have to provide a 'default' path that gets used during editing sessions.
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
User avatar
trogluddite
 
Posts: 1730
Joined: Fri Oct 22, 2010 12:46 am
Location: Yorkshire, UK

Re: incorrect trigger behavior, possible a bug

Postby tester » Fri Mar 08, 2013 12:52 am

What's interesting - time based solution seems to work, but... will it work under heavy load? Or to be precise - are these time based solutions working, because something else than the order of connections separates trigger 1 from trigger 2?
Attachments
timebased-solution.zip
(5.08 KiB) Downloaded 876 times
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
tester
 
Posts: 1786
Joined: Wed Jan 18, 2012 10:52 pm
Location: Poland, internet

Re: incorrect trigger behavior, possible a bug

Postby trogluddite » Fri Mar 08, 2013 12:54 am

Yes, it's weird - as if they intended to have that feature, but didn't quite finish the programming!
Seems like there is some strange effect where the triggers get intialised before the file path does - yet it works fine using the 'start folder' primitive (I have used this many times) - it is obviously not difficult to implement.
Last edited by trogluddite on Fri Mar 08, 2013 12:56 am, edited 1 time in total.
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
User avatar
trogluddite
 
Posts: 1730
Joined: Fri Oct 22, 2010 12:46 am
Location: Yorkshire, UK

Re: incorrect trigger behavior, possible a bug

Postby tester » Fri Mar 08, 2013 12:56 am

Not documented?

Are you sure? ;-)

I don't care about how it behaves in DLL, because in my projects these are only on the side of the user interface. But thanks for reminding, that there might be an issue related to copied dlls by some hosts.

Can you show what you mean with this start folder primitive?
Will it work with preset manager, i.e. will the preset store a relative path instead of absolute?
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
tester
 
Posts: 1786
Joined: Wed Jan 18, 2012 10:52 pm
Location: Poland, internet

Re: incorrect trigger behavior, possible a bug

Postby trogluddite » Fri Mar 08, 2013 1:01 am

He he, 2006!!
And look at the SM version number - wonder if it ever got reported by the Beta testers!! :lol:
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
User avatar
trogluddite
 
Posts: 1730
Joined: Fri Oct 22, 2010 12:46 am
Location: Yorkshire, UK

Re: incorrect trigger behavior, possible a bug

Postby tester » Fri Mar 08, 2013 1:06 am

Yep, very old, at tat time I didn't even knew about it's existence. :-)

Anyway, I wonder if there can is an easy way of storing relative paths\files to load. Otherwise - manual editing the presets - which works but is boring. Could you show on some example? My brain is somewhat off rght now.
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
tester
 
Posts: 1786
Joined: Wed Jan 18, 2012 10:52 pm
Location: Poland, internet

Re: incorrect trigger behavior, possible a bug

Postby trogluddite » Fri Mar 08, 2013 1:22 am

Here's a rough sketch of what you need from an old SM example. it uses the trigger output of the VST preset to ensure that a file gets loaded automatically whenever the preset changes. Need to test, but I think the preset trigger happens at start-up too, so I don't think an 'After Load' is required.
Preset File Loader.fsm
(1.46 KiB) Downloaded 899 times

NB) It's really still an SM file (edited to '.fsm' to keep the forum attachments happy) - if you re-name to .osm it will load in SM too.

You could also store a sub-folder in the VST string if you needed to - inside the "Trogz Toolz" schematic at the SM site, there are some string modules I made for separating and combining folder, filename, extension etc. that might be useful if you need a more flexible system.
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
User avatar
trogluddite
 
Posts: 1730
Joined: Fri Oct 22, 2010 12:46 am
Location: Yorkshire, UK

Re: incorrect trigger behavior, possible a bug

Postby trogluddite » Fri Mar 08, 2013 1:27 am

tester wrote:I didn't even knew about it's existence

Same here - I was using SynthEdit back then - no code, no assembly, and an awful user interface. Wish I had found SM sooner!
All schematics/modules I post are free for all to use - but a credit is always polite!
Don't stagnate, mutate to create!
User avatar
trogluddite
 
Posts: 1730
Joined: Fri Oct 22, 2010 12:46 am
Location: Yorkshire, UK

Re: incorrect trigger behavior, possible a bug

Postby MyCo » Fri Mar 08, 2013 1:32 am

With ruby, loading on init doesn't work, so it uses "after load"
Attachments
file read (MyCo).zip
(832 Bytes) Downloaded 942 times
User avatar
MyCo
 
Posts: 718
Joined: Tue Jul 13, 2010 12:33 pm
Location: Germany

Next

Return to General

Who is online

Users browsing this forum: No registered users and 69 guests