How to Use TiniHttpServer on your TINI

Return to Index

These instructions assume you have obtained all of the required hardware and software. If you run into problems, please make sure you have the proper versions of the various software pieces before you ask for help.


  1. Make sure that you have all of the required items listed in the Using TiniHttpServer as Distributed section of the System Requirements page.

  2. Extract the TiniHttpServer distribution file, TiniHttpServer10.zip. Be sure to maintain the directory structure.

  3. Open a Command Prompt (shell) window and change to the TiniHttpServer1.0 directory that should have been created in Step 1.

  4. Run the batch file deploy.bat (Windows derivatives) or the shell script deploy.sh (UNIX derivatives), passing three or four parameters:

    1. The hostname or IP address of your TINI (e.g. kumquat)

    2. A user name (e.g. root)

    3. The password for that user (e.g. tini)

    4. (Optional) The amount of RAM (in KB) on your TINI.

    Specifying the fourth parameter as 512 or 1024 will deploy TiniHttpServer512.tini or TiniHttpServer1024.tini, respectively. Specifying any other value (or no value at all) will deploy TiniHttpServer.tini, which starts out the same as TiniHttpServer512.tini, but may be different if you have rebuilt TiniHttpServer. Regardless of which copy is deployed, the file name on TINI will always be TiniHttpServer.tini.

    TiniHttpServer512.tini is a smaller file containing no 1-Wire containers except those needed by the sample servlets.

    TiniHttpServer1024.tini contains all of the 1-Wire containers, making OneWireServlet much more interesting, but is much larger and might not run on a 512 KB TINI.

    The 1024 option is recommended only if your TINI has 1 MB of RAM.

    For example, if your TINI with 1 MB of RAM is named kumquat and you have not changed the default users or passwords, you would type:

    Windows: deploy kumquat root tini 1024

    UNIX: sh deploy.sh kumquat root tini 1024

    After this is finishes, your TINI should have the following files:


  5. Using telnet, login to your TINI. You can use JavaKit to login to your TINI, but then you will not see the output when TiniHttpServer is run in the background.

  6. Type: source /bin/TiniHttpServer

    After a short while, you should see the following:

    SSC Web Server/1.0
    Copyright (C) 1999-2002  Smart Software Consulting
    
    OneWireServlet: init
    

    If you instead see a message containing "OutOfMemoryError" or "Insufficient Heap", you should re-deploy without using the 1024 option. If you see one of these messages after deploying with the 512 option, your heap is probably too fragmented for TiniHttpServer to run. To fix this try these steps (listed easiest to hardest) one-by-one until the problem goes away:

  7. Point your web browser at your TINI. For example, if your TINI is named kumquat, you should go to the following URL:

    http://kumquat/

  8. If you want to serve other documents from your TINI, FTP them to the /docs directory (or below it). The file /docs/foo/bar.html can be accessed from a web browser via the following URL:

    http://kumquat/foo/bar.html


Copyright © 1999-2002 Smart Software Consulting