Indigo Rose Software

Professional Software Development Tools

 
+ Reply to Thread
Page 1 of 2 1 2 LastLast
Results 1 to 15 of 27
  1. #1
    Join Date
    Apr 2005
    Location
    São Paulo, Brazil
    Posts
    2,451

    Socket Object Plugin

    Hello,

    after some weeks of development, I think that now my new plugin is stable enough to be announced publicly here in the forum. With the help of this object plugin, you can build full featured network-enabled applications with AutoPlay Media Studio. With a few lines of Lua script and by dropping a single socket object on the page, you may build server or client projects, communicate with remote servers, exchange messages, check or send mail, chat, etc. Several example projects are included in the documentation, that were used during the development, to make sure that all functions work, and that no essential functionality is missing. That doesn't mean that the plugin can't get further enhancements - just that right now it already can do a lot.

    The plugin ships with documentation in CHM format, which contains links to three example projects, so far. These are the projects:

    1. A POP3 client


    This example will show you how to connect to a remote POP3 mail server, retrieve the number of messages that are currently stored in the mailbox, the size of the mailbox in bytes, and information (sender, subject) of the 12 most recent messages that you received. The screen shows what you should expect to see if you run the demonstration project, and query a spammed mailbox, like mine (which I actually don't monitor at all).


    2. A multi-user chat server


    This example shows a working chat server for a multi-user chat room. I may have a chat server running with the parameters used in this example project, so you should change at least the nickname of the server before trying to run your own instance of it. The server announces itself to the internet and the connection parameters (ip address, port number) may be retrieved by the chat clients using the same nickname.

    In other words, I implemented a mechanism that would allow you to host a chat server, even if you are on a dynamic IP address. Upon start, the server will try to announce its nickname, IP address and port on what it is listening, to a public database. The chat client will be able to retrieve these connection informations just by knowing the nickname, which of course should be the same in the server and client project.

    Of course, if you run a server on the local network, you shouldn't announce it publicly. And if you are behind a proxy or a firewall, the IP address reported to the database may be wrong. You might to know a bit about NAT, port mapping, etc. if you plan to use this feature in such scenarios.

    New messages received from any client are immediately echoed to all connected chat clients, in the same order as they are received. The server interface shows the connected clients (handle number and remote ip address), and offers the possibility to kick (disconnect) users individually.

    The server re-publishes itself after 5 hours and 50 minutes, before the initial announcement expires (which happens automatically after 6 hours). If you don't re-validate your nickname, this info will be removed from the public database. Another server will be able to use the same nickname after the expiration. A good reason to use unique nicknames.


    3. A chat client for the multi-user chat server


    This is, of course, just a demonstration. You should implement your own protocol, show the chat in a pleasant interface. My intention was not to build the best chat client, but to get the communication working as it should. However, you might want to look at the code of these projects, to see how things were done. If you fire up this demo project, you may be able to connect to the demo chat server from item 2. But I won't keep this running for a long time - you should be able to fire up your own servers with ease.

    Well, those are the demo projects currently available. I am going to implement a SMTP client soon, and include it as an additional example, so next you will be able to send mail directly from AutoPlay Media Studio. But give me a few days to gather my breath first.

    This is not a free plugin, but you may try it for two weeks, so you can see if it fits your needs without any risk. All info about licensing can be found in the documentation. Finally, you will find a link to download the installer here.

    Ulrich

  2. #2
    Join Date
    Jun 2000
    Location
    Indigo Rose Software
    Posts
    1,934
    Nice work Ulrich!

    This is a very cool plugin. I can't wait to see what people come up with using this one.

    mark.
    MSI Factory The Next Generation Intelligent Setup Builder

  3. #3
    Join Date
    Apr 2007
    Location
    Raalte, OV, Netherlands
    Posts
    3,277
    that's a ni.... wait wut!?!?! SOCKET!~!!

    Thanks Mr. Peters, this is amazing!

    **Edit, nice setup aswell.
    Bas Groothedde
    Imagine Programming :: Blog :: Familiar people here

    My AMS Plugins:

  4. #4
    Join Date
    Apr 2004
    Location
    Vancouver, Canada
    Posts
    1,790
    Wow! this is fantastic. Great job.
    Dermot

    I am so out of here

  5. #5
    Join Date
    Apr 2009
    Posts
    277
    and about time too!, lol

    nice one Ulrich , this means i can do away with my .NET socket lib, and i just know now my boss will have me updateing some of our software products ... i see some overtime coming!

  6. #6
    Join Date
    Oct 2007
    Location
    Gensokyo
    Posts
    1,324
    Oh great, just when I was saving up my money this came along. :(

    Looks like I'll have to buy this one though.

  7. #7
    Join Date
    May 2006
    Posts
    1,375
    good work

    i saw all your inbox
    ★ ★ ★ ★ ★

  8. #8
    Join Date
    Apr 2005
    Location
    São Paulo, Brazil
    Posts
    2,451
    Hello,

    I have completed the SMTP client example project. This demonstration project shows you how you can send email directly from AutoPlay Media Studio, using this plugin.



    For the sake of simplicity, I had to cut some corners in the demo. Normally, you should use the mail servers that your ISP has assigned to you, instead of delivering email directly to a remote SMTP server. So, while the example project may work correctly, you may encounter some difficulties because the messages might be classified as junk. I try to find out the mail server where the test message has to be delivered to, and this attempt may fail, of course. Anyway, this is just an example, not pretending to be a complete mail sending solution.

    For those who already downloaded the plugin installer, just fetch the updated help file, from here, where a link to the new example project can be found.

    Ulrich
    Last edited by Ulrich; 05-03-2009 at 09:53 AM. Reason: Changed download link

  9. #9
    Join Date
    Oct 2007
    Location
    Gensokyo
    Posts
    1,324
    Hey, read my PM please. :3

    Also, Do you think you could make an IRC example?

  10. #10
    Join Date
    Oct 2007
    Location
    Gensokyo
    Posts
    1,324
    Double post, sorry.

    As long as I didn't miss anything and it's already there could we could get a Socket.SetPort for server sockets and Socket.SetMaxClients?

  11. #11
    Join Date
    Apr 2005
    Location
    São Paulo, Brazil
    Posts
    2,451
    Quote Originally Posted by ShadowUK View Post
    As long as I didn't miss anything and it's already there could we could get a Socket.SetPort for server sockets and Socket.SetMaxClients?
    Hello,

    yes, this should be possible. As these are parameters that (I thought) normally would not change in runtime, currently they can be set only through the Socket properties dialog. I'll update the plugin to include these functions.

    Ulrich

  12. #12
    Join Date
    Oct 2007
    Location
    Gensokyo
    Posts
    1,324
    Quote Originally Posted by upeters View Post
    Hello,

    yes, this should be possible. As these are parameters that (I thought) normally would not change in runtime, currently they can be set only through the Socket properties dialog. I'll update the plugin to include these functions.

    Ulrich
    Thanks. This is by far my favourite plugin after playing around with it. It's defiently what I'm looking for to continue an old project.

  13. #13
    Join Date
    Jul 2002
    Location
    Taiwan
    Posts
    65

    I have a question

    When I testing POP3Client example.
    It seens Show inaccuracy.
    like the attachment I post.
    Attached Images

  14. #14
    Join Date
    Apr 2005
    Location
    São Paulo, Brazil
    Posts
    2,451
    Quote Originally Posted by coffeeworm View Post
    When I testing POP3Client example.
    It seens Show inaccuracy.
    like the attachment I post.
    Hello Cheng,

    this is normal, and shouldn't be understood as an error in the example code. See, the email protocol was originally developed to work with ASCII only, and only ASCII characters were used in the first email messages. Only later support for other character sets was added, like big-5 Chinese as in your case, ISO-8859-1 to allow accents and diacritics for Spanish and Portuguese languages, KOI8-R for Cyrillic messages, and so on. However, the email still is stored in plain ASCII on the mail server, and a real email client would need to perform correct character encoding / decoding to display the text in all fields (sender, recipient, subject, message body) properly. However, this example just shows the source code of the message in your mailbox, without the decoding part - you could certainly add this, if you need.

    Ulrich

  15. #15
    Join Date
    Oct 2007
    Location
    Gensokyo
    Posts
    1,324
    Hey, upeters.

    I've been playing around with this plugin non-stop and I love it!

    I managed to connect to the IRC protocol after a lot of reading the RFC 1459.

    Here's an example, It connects to a server and channel and you can input raw commands like "PRIVMSG ShadowUK Hello!".

    Enjoy. (if it works.)

    http://shadiku.com/IRC.zip (1mb limit :O)


Similar Threads

  1. FREE : Matrix Object Plugin
    By reteset in forum AutoPlay Media Studio 7.5 Plugins
    Replies: 13
    Last Post: 09-20-2009, 02:37 AM
  2. FREE : Timer Object Plugin
    By reteset in forum AutoPlay Media Studio 7.5 Plugins
    Replies: 29
    Last Post: 04-23-2009, 08:00 AM
  3. Free Plugin: Media Player Object
    By Ted Sullivan in forum AutoPlay Media Studio 5.0
    Replies: 7
    Last Post: 09-24-2004, 03:54 PM
  4. INFO: Difference between the Media Player Object and the AVI Object
    By Support in forum AutoPlay Media Studio 4.0 Examples
    Replies: 0
    Last Post: 10-29-2002, 03:15 PM
  5. HOWTO: Make a Media Player Object Go Full Screen
    By Support in forum AutoPlay Media Studio 4.0 Examples
    Replies: 0
    Last Post: 10-23-2002, 12:23 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts