SMSLib

Table Of Contents

Installation Instructions

Prerequisites

To use SMSLib, you should install the following components:

Important Note

Starting from SMSLib v3.4, the installation procedure has changed a bit. Some SMSServer components that required extra dependencies have been pulled out of the main source tree. This was done in order to reduce the required third party libraries & dependency files for those wanting to use the core library.

The core SMSLib/SMSServer source files can now be compiled with only two dependencies: the Simple logging facade for Java and the Apache Commons/NET for the IP modem driver.

All other add-on SMSServer components are moved in the /misc/SMSServer/Interfaces/ directory, organized by development status. Installation instructions for these specific components are given in the relevant SMSServer documentation pages.

Java Communications Library

You have two options:

Java Comm Installation

The installation procedure for both the old Java Comm v2 and the new Java Comm v3 is identical.

Java Comm v2 is for Win32 systems and it is available on the Download page.

Java Comm v3 is for Linux systems and it is available for download directly from SUN downloads (registration is required)

To install it, unzip the downloaded archive file in a temporary place and do the following copies:

If you have a separate JRE directory, do the same copies for the JREDIR directory!

RxTx Installation

The official RxTx binary pack is available here. The provided link will download the distro with some standard binaries (for linux 32bit, 64 bit, etc). If binaries for your specific operating system are not included, you may consider recompiling RxTx yourselves.

For a custom Win64 RxTx distro, have a look at the CloudHopper's web site.

To install it, unzip the distribution file in a temporary place and do the following copies:

If you have a separate JRE directory, do the same copies for the JREDIR directory!

Apache ANT

Download and install Apache Ant from here.

Simple logging facade for Java (slf4j)

Java logging facade (slf4j) acts as the middle layer between an application and the various logging systems. Download slf4j from here. You need to have the slf4j-api-1.5.6.jar file (1.5.6 was the current version at the time of this writing) somewhere in your classpath or in Java's lib/ext directories, together with one of the following files, depending on which logging system you use:

Logging SystemRequired .jar
JCLslf4j-jcl-1.5.6.jar
Apache log4jslf4j-log4j12-1.5.6.jar
JDK loggingslf4j-jdk14-1.5.6.jar

Apache Jakarta Commons - NET

Download Apache Jakarta Commons/NET from here. You need to have the commons-net-2.0.jar file (2.0 was the current version at the time of this writing) somewhere in your classpath or in Java's lib/ext directories.

Building SMSLib

The ANT build file provides the following targets:

compile-smslibCompiles the core library.
build-smslibBuilds the core library.
docCreates the javadoc pages for the core library.
build-smsserverBuilds the SMSServer application together with SMSLib core library in one jar, making SMSServer as the startup application in the jar.
build-smsserver-standaloneBuilds the SMSServer application without the SMSLib core library in one jar, making SMSServer as the startup application in the jar.
cleanCleans the temporary compile / javadoc / class directories.

Running

ant

(i.e. without a target) will give you a help screen.

Now what?

If you are new to SMSLib, spend some time with the two examples ReadMessages and SendMessage (located in the src/java/examples/modem folder) to find out the basics of how to read / send messages via your phone.



Do you have something to add? Is something wrong?
Please leave a comment on the wiki page (note: Google account required)