A VelBus server-mode tool

[quote=“GertSt”]Man, this is exact what I needed!
I’m not able to create one myself, since I’m not a .NET developer.

I will use it for my Flex tool at forum.velleman.eu/viewtopic.php?f=26&t=1710&start=0&st=0&sk=t&sd=a.

I just tested is and it seams to work :slight_smile: I’ll keep you informed about issues. And let you know if all works just good also :wink:

Thanks a lot![/quote]

I’m glad you like it. If you find anything that’s not working quite as it’s supposed to or if you have some feature requests let me know.
Your Flex tool looks interesting to me as I see a lot of potential in web interfaces for Velbus. Certainly when it prevents running loads of software on all clients and especially when it’s flex. : )

Anyway, let me know if I can help you with the socket server part of your project. I’m definitely taking a look at your project.

Cheers,
David

Your socket server is running for about a month now and it never crashed till now and I never had an issue with it.
So it looks pretty stable and has no memory leaks. :slight_smile:

i downloaded
:
1-now playing plugin
2-velbus-server.exe
3-VelbusSocket.exe

couldnt make it work, can you give me a step by step tutorial pls!

Launched :
velbus-server.exe
VelbusSocket.exe
named a play list “wolf”

having this message:
trying to connect to 127.0.0.1:3788
playlists found: 2
currentPlayList:[Playlist wolf]
Unable to connect: socket error.
lcd: wolf
lcd: Not playing

Hi Ciceron,

Try the following steps and let me know if it made a difference.

  1. On Windows, open the start menu and click on “Run…”.
  2. Next type ‘cmd’ without the quotes and enter. A black command prompt will popup.
  3. Find out what the path is to ‘velbus-server.exe’ (e.g. ‘C:\directory\anotherone\velbus-server.exe’).
  4. Type the following with the path substituted with your own:
    ‘cd C:\directory\anotherone’ (again without quotes) and hit enter.
  5. Next type ‘velbus-server.exe’. A list of port names should show up.
  6. Choose the right port and type:
    ‘velbus-server.exe portname portnumber’
    e.g.: ‘velbus-server.exe COM1 3788’
  7. Run ‘VelbusSocket.exe’ as you normally would.

This is the right way of launching it. If this works, you can put the complete command in a batch file. Create a text file and save it as ‘socket server.bat’ on your desktop. To do this, you would put the following line, adapted with your values, in the file:
‘C:\directory\anotherone\velbus-server.exe COM1 3788’
Save it. Now you can doubleclick the file to launch the program.

This might be to simplistic for you, but a step-by-step guide might be usefull for anyone. : )

Let me know if this makes a difference for you.

Cheers,
David

thank you david for the prompte reply, will test it tomorrow and get back to you ASAP!

:slight_smile:

All the above worked, but:

no playlist, I see my vmb4ry, but how could I interact…?
http://www.andalussyat.com/sc.jpg

[quote=“Ciceron”]thank you david for the prompte reply, will test it tomorrow and get back to you ASAP!

:slight_smile:

All the above worked, but:

no playlist, I see my vmb4ry, but how could I interact…?
http://www.aknari.com/sc.jpg[/quote]

I can’t reach the server where the image’s on. I’m not to familiar with VelbusSocket, but I believe that you can’t interact with the modules listed in the interface. To interact with channels of certain modules you have to add the necessary data in the ‘data.xml’ file in the same directory. This will make the commands for each channel show up in the uppermost list in VelbusSocket.exe. You can then activate or deactivate each channel by clicking the right command. You can visit code.google.com/p/flexvelbussocket/ for more info on the ‘data.xml’ file.

Or did you adapt the xml-file already? If you can’t figure it out, you can ask here again and I’ll try and explain that bit too.

EDIT:
Now I see the picture. As I figured, you didn’t adapt the xml-file. Visit the website, visit this thread, give it a try and if it didn’t work we’ll try to clarify things for you.

I adapted the xml file perfect!

I can command the vbm4ry!!

How can I commande the vmb1dm?
how can i display the song status?
can you send me the .fla file so I can skin the swf?

many thanks again

I am planing on creating an automated xml file and batch file with my PHP program online…

You might have noticed that GertST is the actual creator of the Flex Velbus Socket tool, not me. But you can check here for the source of the program. Maybe you can recompile it with an adapted lay-out or something.

About controlling the vmb1dm. You can only send preset commands. So the only thing you can do is use VelbusLink to give the dimmer certain commands (e.g. on, off, 50%, …), capture the data of the commands in the log window and put it as commands in the xml file. There is a command the example XML that dims lights slowly, you could check it out.

I suggest you examine the example xml-file and the homepage for more info on implementing the song status and other things in the program.

Cheers

OK
i will contact GertST!

I programmed" switch all" and “switch off all.”

I have a bug when I switch off all , it execute and freez…
http://www.andalussyat.com/sc2.jpg
http://www.andalussyat.com/sc3.jpg

any clue?

I would like to change the kinggnare skin: ntt.cc/ext/KingnareStyle-Skin/Ki … -App.html#

It would be fun to play with colors and and pictures… :slight_smile:

velbus-server.exe says that the connection had been closed from the other side and keeps on working besides that. It’s the flex tool that closes the connection, probably because of an error. I will investigate the packet you send, can you tell me how you obtained it? (Tout éteindre: 0FF80004002000000D504)

EDIT:
I can’t seem to reproduce your error. Maybe you should check whether your button is correctly configured to activate all lights or something?

Actually it happened when i switched all on and off from the flex tool.

EDIT:
may be packet collision, since I was to fast??
just reproduced the problem, when i click to fast to change status!

And server doesnt crash until flex is closed since freezed…

obtained 0FF80004002000000D504, from velbuslink log
http://www.andalussyat.com/sc4.jpg

But you’ve configured a button to activate or deactivate all lights, right? Then it’s only one command and therefore not enough packets to collide…

try to switch between ON an OFF faster, it will crash…

may be it is the wrong commande?

No,

I programmed 2 buttons:

1-all on
2-all off

[quote=“Ciceron”]

No,

I programmed 2 buttons:

1-all on
2-all off[/quote]

Yes, that’s what I meant, so putting all the lights on equals one command, which equals one packet, right? I don’t see how you could get packet collision that way, but maybe I’m not seeing something…

When you keep VelbusLink open while sending the command and thus freezing VelbusSocket.exe, do you see the exact same packet in the log?

normally a ‘All On’ or ‘All Off’ pushbutton will send to each module the command to switch off the relays and dimmers. So when you have i.e 5 relaymodules and 5 dimmodules you have to address each module with his address and command. i think you can’t do it with one packet.

So where’s that list stored then? I figured that the memory map of the push button module, for example , had only room for the push button name and the response time? And the memory maps of the relay module, for instance, has room for a couple of button addresses and channel numbers per action (on/off/…). So I believe the pushbutton broadcasts a signal that it’s just been pressed/released and the other modules receive it and know what to do with it. I might still be wrong though…

So where’s that list stored then? I figured that the memory map of the push button module, for example , had only room for the push button name and the response time? And the memory maps of the relay module, for instance, has room for a couple of button addresses and channel numbers per action (on/off/…). So I believe the pushbutton broadcasts a signal that it’s just been pressed/released and the other modules receive it and know what to do with it. I might still be wrong though…
I think you are right, commande is sent telling a button is pressed and modules know how to interprete it…

Tryed to get into your flex project, it is painstaking, dont know where to look (since no comments in your code) :wink:

And never worked with flex, the learning curve is going to be a steep one! if you dont take my hand!!

:wink:

Probably, but really the Flex Velbus Socket is a piece of software written by GertST, not me. So I can’t really help you with the source code.
I guess it’s sufficient to send the command that the push button sends when it’s pressed, but the ‘All on’/‘All off’ command isn’t even working at all for me, so I can’t really try it.