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

Ruby IP Server&Client - exchange data between exe/vst

Post any examples or modules that you want to share here

Ruby IP Server&Client - exchange data between exe/vst

Postby chackl » Wed Jan 08, 2014 4:08 pm

Hello!

One of my latest milestones to the goal was to develope an addon for the FlowStones Network components. I hope DSP-Robotics will do some improovements on them in future to get them save and stable.

Will first i had do develope a new comunication system (Just imagine that you have to pass on all data through one string link and this live)

So what does it?
You will be able to exchange data betweeen 2 Programms via LAN or also local on your PC
You will be able to exchange data betweeen EXEs, VSTs and Schematics at the same time!
You are able to exchange completly ruby-objects
The Data is stored on Client and Server and will only sync if the data has been changed

Advanteges of the normal Flowstone Modules?
IP:Port or DNS:Port or only IP or only Port are supported - a DNS Lookup is done at clientstart
Every Client gets its own unique ID number (0-255 are fixed - 256-65535 for startuprandom)
some extra settings

What is done internal:
* Server starts
* Clients connects with a random ID between 256-65535
* Server fixes the ID to comunicate with different clients at the same time (ID 0-255 counted from 0)
* Clients stores ID and usis it the complet session till disconect

What is done internal with data?
The ruby objects are queued up in an array - an extra procedure takes each object and exports it as Bin-String.
The Bin-String is splitted each 252 bytes and gets the protocolfunctions. After that the complet Data-Load is sended through the LAN to the reciver that splits up the data and loads it back to ruby - if something went wrong the sender will send brocken data again.

Why useable?
Well the Server is now logical able hande up to 255 clients at the same time - Windows PC-Systems will stop at 10 ^^
every client will get the same data - you may not do anything more here ;)
This thing is now the new Variable-Server that i made some months ago.
And YES - As i told above - you are able with it to exchange data also between 2 seperat programms ;)

To get this all i did a verry simple one shown here with HEX data: (Updated V1.1)
Code: Select all
XX XX -     XX   - XXXXXX...XX -     XX
srvID - function -  Datablock  - Endsequence

Funktions:
F0 ... Start a new dataframe
F1 ... continue with old dataframe
F2 ... Framecheck was OK
F3 ... Framecheck went wrong

A0 ... Request new IP
A1 ... New ID in Datablock
A5 ... Check Client (Ping)
A6 ... Client OK (Ping)
A9 ... Client will exit now

Endsequences:
E0 ... Dataframe done
E1 ... Wait for next Datablock


I'll post new developements on this soon - but i think it is now stable ;)

Kind regards
C.Hackl
Attachments
ruby network server client.fsm
Ruby Network V1.3
(22.34 KiB) Downloaded 1228 times
Last edited by chackl on Tue Apr 08, 2014 12:18 pm, edited 3 times in total.
100% accuracy is the guarantee to your success. The value alters if you combine it with musical creativity.
User avatar
chackl
 
Posts: 233
Joined: Tue Aug 17, 2010 8:46 pm
Location: Austria / Salzburg

Re: Ruby IP Server&Client - exchange data between exe/vst

Postby jjs » Wed Jan 08, 2014 7:58 pm

Greatly done!

I thought it was possible to do network without the FS client modules, but it aint.

To me these are buggy, at least in the former last versions of flowstone as the connection sometimes fails with servers while a browser still can access the server.
User avatar
jjs
 
Posts: 142
Joined: Thu Jun 09, 2011 12:15 pm

Re: Ruby IP Server&Client - exchange data between exe/vst

Postby chackl » Wed Jan 08, 2014 8:11 pm

You're right ;)

There is a lot of work to do in the Server modules

One Thing that gets me up each time - If you want to send individual data to each Client from the Server, the Server will send them to all - so this causes a lot of traffic in LAN - Not good

And the reason why it is not secure enough:
The Server is not able to disconect from any Client ift the Client does any sh**t in it

So this may be some work in future for DSP-R ;)

Regards
100% accuracy is the guarantee to your success. The value alters if you combine it with musical creativity.
User avatar
chackl
 
Posts: 233
Joined: Tue Aug 17, 2010 8:46 pm
Location: Austria / Salzburg

Re: Ruby IP Server&Client - exchange data between exe/vst

Postby jjs » Wed Jan 08, 2014 10:48 pm

Hopefully the devs will take a look into it, so networking is more reliable.
User avatar
jjs
 
Posts: 142
Joined: Thu Jun 09, 2011 12:15 pm

Re: Ruby IP Server&Client - exchange data between exe/vst

Postby chackl » Thu Jan 09, 2014 2:07 pm

V1.1:

I did a new schematic Layout and conected the Rubylink wireless - so it is working now paralell like the preset-modules.

New things:
Ping System - Server has now an Arrayoutput with all clients and pings shown
Added example for a knob

File is in first Post!!!!

Regards, C.Hackl
100% accuracy is the guarantee to your success. The value alters if you combine it with musical creativity.
User avatar
chackl
 
Posts: 233
Joined: Tue Aug 17, 2010 8:46 pm
Location: Austria / Salzburg

Re: Ruby IP Server&Client - exchange data between exe/vst

Postby tester » Thu Jan 09, 2014 8:08 pm

Thanks!
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: Ruby IP Server&Client - exchange data between exe/vst

Postby chackl » Fri Jan 10, 2014 1:28 pm

Little Update:

Added an error count - after 5 Oject Parsing errors the client is forced to disconect
Added more Messages to Client and Server
Added Message Log module

File is in First Post!

Regards
100% accuracy is the guarantee to your success. The value alters if you combine it with musical creativity.
User avatar
chackl
 
Posts: 233
Joined: Tue Aug 17, 2010 8:46 pm
Location: Austria / Salzburg

Re: Ruby IP Server&Client - exchange data between exe/vst

Postby tester » Fri Jan 10, 2014 2:33 pm

Okay, so how to combine such stuff with some sort of coordinator website (php?), so that two separate programs can contact with each other over the internet? I suppose:

- receiver would have to send it's ID (ip plus some sort of codename identifier) to the website/pool,
- these parameters would have to be stored on the website,
- sender would have to get the ID list from the website, so that ypu can select the receiver,
- thus - receiver's list would have to be refreshed from time to time (and receiver would have to send indication of it's presence).
- then sender and selected receiver could communicate in a direct p2p mode.

Is my thinking correct?

p.s.: I have zero knowledge on php, any help (working script) appreciated.
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: Ruby IP Server&Client - exchange data between exe/vst

Postby chackl » Fri Jan 10, 2014 3:23 pm

Well the thin is at PHP you have no Option to create a FlowStone-Server.
Ony by HTTP Post it would be an acceptable solution if a good SQL and Server PHP script is behind it.

Next ist, that PHP will never send updates to the client - the client has to request updates from it - so the Server Needs an Option to know what data Needs to be sended... and all this will do it verry laggy and slow - so no Option for a realtime based program.

So if you Need some sort of Server you Need your own Windows Server running.
And also this will get you Problems - the Internet is evil and there are quite stupid persons online - so one hacker just hase to lisen on your Server and will get out all data that is send by the Server. FlowStone does not provide any security on this module - ans eaven if you hav found a hacker on the Server you have no Option to disconect him and bann him from your Server, otherwise you are able to set this up to your Firewall.

So this is quite no Option for Internet at the Moment.

Regards
100% accuracy is the guarantee to your success. The value alters if you combine it with musical creativity.
User avatar
chackl
 
Posts: 233
Joined: Tue Aug 17, 2010 8:46 pm
Location: Austria / Salzburg

Re: Ruby IP Server&Client - exchange data between exe/vst

Postby tester » Fri Jan 10, 2014 4:12 pm

I'm just thinking about easy way to connect virtual devices "on demand" (time window), without need of manually digging on what is the ip (we mostly have dynamic ip structures here) and without need to coordinate via external coordination (emails, IM's, etc). I have no worries on "evil internet". These virtual devices would either transmit low stream data and/or commands data ("push the button, set the value" type).
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

Next

Return to User Examples

Who is online

Users browsing this forum: No registered users and 71 guests