The Device Network
Your IP Address is:


  • How to connect your device to the KSduino Device Network?

    Posted on Thu December 6, 2012

    imageYou can connect your Arduino device with Arduino Ethernet Shield w5100 or enc28j60 to the KSduino Device Network for free.
    When you connected to KSduino you can send any Parameters of your controller to this web server and monitor it in graphic and text mode in real time.

    To connect your device to KSduino device network you should:

    see also: I try to use standard KSduino example sketch but my Arduino does not online

  • Comments

  • How to create simple sketch to connect to KSduino?

    Posted on Thu December 6, 2012

    To create simple KSduino sketch download latest KSduino Library for Arduino from the DOWNLOADS page and install the library to your Arduino IDE.

    1. Start your Aduino IDE and select Examples -> KSduino -> simple_01:

    There are some simple examples for beginners. They are described in the KSduino documentation. These simple examples are similar each other, they show the performance of different KSduino functions. We’ll take the first to create the simple sketch.

    2. Then perform some changes in the sketch to connect the Arduino to your local network and to connect to the KSduino network:

    • change the deviceID and devicePwd - there are parameters you specify when you add new device to KSduino
      see: How to add new device
    • change the ip to free ip addresss in your local network

    This examle uses D1 parameter, so add D1 parameter to your device at the KSduino web site.

    see: How to add new parameter to device

    3. Upload sketch to Arduino. The example program starts and the default device parameters graph will shows values which send your Arduino:


  • Comments

  • I try to use standard KSduino example sketch but my Arduino does not online

    Posted on Thu December 6, 2012

    If you followed all the advice of the “How to connect your device to the KSduino Device Network?" article and your Arduino does not online try to check your KSduino and Network parameters:

    First of all you should use right Device ID and Device password parameters. Check it first.

    Then check the Network parameter: IP address.

    Read the next advices if previouse does not helped you:

    In the KSduino examples we have used simple setup function. We use only one network parameter for Arduino - its IP. Your local network can use more difficult connection type. The is another variants of setup Arduino network.

    Please try next functions to check it:

    void 	begin (byte *mac, unsigned int port)
    void 	begin (byte *mac, byte *ip, byte *dns, byte *gateway, 
                   byte *subnet, unsigned int port)

    See description of this functions at KSduino documentation

    First one function uses DHCP mode to connect your arduino to your local network. It’s very easy but it takes more bytes in Arduino sketch. Change ksd.begin (…) if you like to use DHCP mode:

    ksd.begin (mac, port);

    The next one function uses all network parameters, but you should create some new variables to use it:

    byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0x0D };
    byte ip[] = { 192, 168, 0, 222 };
    byte dns_address[] = { 192, 168, 0, 1 };
    byte gateway[] = { 192, 168, 0, 1 };
    byte subnet[] = { 255, 255, 255, 0 };
    unsigned int port = 58833;

    If you know your DNS and Gateway than try to use the long one function. Just change the “192, 168, 0, …” to your values. And replace ksd.begin (…) with this code:

    ksd.begin (mac, ip, dns_address, gateway, subnet, port);

    Then change the

    unsigned int port = 58833;
    unsigned int port = 40000 + deviceID;

    it will help to detect your Arduino at the KSduino UDP server by this number.

  • Comments

  • How to add new device?

    Posted on Fri November 30, 2012

    To add new device:

    Parameter Description

    • sign in to KSduino at Login Page
    • go to the DEVICES page and click Add new Device link
    • fill the opened ADD DEVICE form and press Save button

    In this form:

    • Device ID - is unique digits id of this device;
    • Name of this device to show in pages, tables and graps;
    • Password - will be used in communication with KSduino (only digits uses);
    • Device name - is name of your device;
    • Short description - is a short description of your device.
    The ID and Password are used in the sketch to identify this device.
    The ID and Name shows at the web site pages and uses in search engine.
    The short description shows as tooltip at the Device page and uses in search engine too.

  • Comments

  • How to add new parameter to device?

    Posted on Thu November 29, 2012

    To add new parameter to your Arduino Device go to the Device page, press ‘Add new parameter’ button and fill the ‘ADD DEVICE PARAMETER’ form.

    In this form:

    • Type - parameter type, see What is the device parameters for additional information about KSduino parameters;
    • Number - parameter number, for example: d1, b1, etc.
    • Parameter name - name of parameter to show in tables, graphs, page help and description;
    • Safe range - a range of operating parameter values. All values less than first Safe range value and greater than second Safe range value will be market as alarm and selected with red color in tables and graps;
    • Online parameter - is a parameter which sends at least one value for the online interval;
    • Online interval (sec) - time of online interval in seconts;
    • Parameter description - short parameter description, see How to add description of the device parameter for additional information.

  • Comments

  • What is the device parameters?

    Posted on Thu November 29, 2012

    There is 6 types of KSduino parameters:
    1. D - Discret
      lenght is 1 bit,
      used to send Discret values: 0 or 1
    2. B - Byte
      lenght is 1 byte,
      used to send Short unsigned integer values: 0 to 255;
    3. I - Integer
      lenght is 2 byte,
      used to send Integer values: -32,768 to 32,767
    4. U - Unsigned integer
      length is 2 byte,
      used to sent Unsigned integer values: 0 to 65,535
    5. L - Unsigned long
      lenght is 4 byte,
      used to send Unsigned long values: 0 to 4,294,967,295
    6. F - Float
      lenght is 4 byte,
      used to send Float values: -3.4028235E+38 to -3.4028235E+38

    It is possible to define all Arduino parameters with these types. Parameters type sets when parameter created and can not be changed later.

  • Comments

  • How to add description of the device parameter?

    Posted on Wed November 28, 2012

    Parameter Description

    Parameters description used as Tooltips in the Parameters list at the Device Page.

    It used as part of page description for search engine sistems at the Device Page and Parameter page also. Using of Parameter Description is very usefull.

    see Device 3305 as example

    So try to describe all of your device parameters.

    To add or modify Parameter Description go to the EDIT DEVICE PARAMETER page by clicking the Edit icon at the Device page. Then fill or edit the Parameter Description field.

  • Comments

  • How to send parameters from one to another Arduino Device?

    Posted on Tue November 27, 2012

    There is possible to send parameters from one Arduino to another Arduino Device through KSduino service or connect two Arduinos.

    To do this:

  • Comments

  • How to skip repeated parameter values?

    Posted on Tue November 27, 2012

    to make your sketch more professional

    The sensors which we use in our Arduino projects often sends the same value. For example a temperature sensor can sends the same value in a few hours because the temperature does not change.


    So we always send the same values​​, we spend traffic on local network and the Internet. Using of controller and server resources are not economical in this mode. We fill the database with unnecessary values.

    There is a simple solution of this problem. We have subclass KSduinoParameter in KSduino library. This class help us to send unique values only.

    KSduinoParameter class constructor has parameters ‘accuracy’ and ‘repeat time’. With this parameters we can set accuracy of sending parameter. For example our sensor sends not unic but similar values: 2.31, 2.32, 2.33, 2.31 and we don’t like to send this similar values to server. To do this we can set ‘accuracy’ value to 0.05 and KSduino library will send values which different to 0.05 or -0.05.

    On the other hand, we need to send at least one value per hour then KSduino calculate our hours average values. For this case we can use the ‘repeat time’ parameter of KSduinoParameter class. Set it to 15*60 and your device will send value every 15 minute despite the fact that the value ​​have not changed.

    KSduinoParameter i3 (&ksd, "i1", 0.05, 15*60);

    So if we set parameter accuracy to 0.05 and repeat time to 15*60 then we will send only changed to 0.05 values and one value after 15 min of omission period.

    The KSduinoParameter class is described at Documentation:

    And demonstated in KSduino library examples. See the simple_06 example:

    Switch the ‘Online parameter’ off at the Edit device parameter page for parameter which uses KSduinoParameter class.


    The parameters online circle will be yellow when we are waiting value, green when we are receiving value and gray if device is offline.

  • Comments

Created with KSNews


Copyright © 2012-2013, The KSduino Project