03

Preparations for App Development

SDK Download and Installation

Configuration

Summary

Chapter 3 will demonstrate downloading the Samsung SmartTV SDK and configuring an actual development environment on a Windows-based system.

SDK Download and Installation

Previewing the SDF

As mentioned previously, the Samsung SmartTV SDK can be downloaded and installed from the Samsung Developers Forum (http://www.samsungdforum.com). Select the SDK menu from the site's top-most menu bar to open the next page.

images

Figure 3-1. The SDK Page on the SDF

Select the SDK menu's submenu, the “SDK Download,” to open the download page for the SDK.

images

Figure 3-2. The SDK Download Page

The SDK Download page provides the latest SDK 4.5 version, as well as previous versions, for Windows and other operating systems. It also provides system requirements on hardware and software for SmartTV application development, and release notes.

The SDF had supported only the Windows operating system in the past, but started also supporting Linux and Mac since SDK version 4.0. However, it is still better to use the Windows version since the Linux and Mac versions have limitations on functions and APIs.

The SDF also provides an Emulator image for Oracle VirtualBox to support running the Emulator on Linux and Mac operating systems, and a local cloud development environment to support collaboration of developers using multiple platforms.

SDK Download and Installation

Chapters 1 and 2 defined the development environment used in this book. As such, only Windows examples for SDK downloading and installing the SDK will be discussed, and Linux and Mac operating systems will not be covered.

Click the “SDK Download for Windows 7” link as shown on Figure 3-3 to download the SDK.

images

Figure 3-3. Downloading the SDK

The SDK download is a large file size because it includes an IDE. Please make sure that there is enough available hard drive space. Execute the downloaded installation file to open the installation window as shown in Figure 3-4.

images

Figure 3-4. SDK Installation Step 1

Click the “Next” button to proceed to the next screen on Figure 3-5, selecting components for the Editor, which is an IDE, and the Emulator. Select all components for now and continue the installation.

images

Figure 3-5. SDK Installation Step 2 – Select Components to Install

Next, choose the installation folder and continue the installation.

images

Figure 3-6. SDK Installation Step 3 – Choose the Installation Folder

After the SDK installation is complete, continue to the Apache web server installation, which acts as the local web server for applications to be tested. You may skip this step if an Apache web server is already installed on the PC.

images

Figure 3-7. Installing the Apache Web Server

The installed SDK can be accessed on the Windows Start menu or directly in the “Samsung TV SDK 4” subfolder of the installation folder entered in Step 3. Also, look below for the shortcut icon created on the Windows Desktop.

images

Figure 3-8. SDK Desktop Shortcut

Configuration

There are a few additional configuration steps for a smoother development environment.

Configuring the Project Workspace

The default Eclipse workspace is “C:UsersAdministratorworkspace.”

images

Figure 3-9. Configuring the Eclipse Workspace

For the fast execution of an application on the Emulator, enter “SDK Installation Folder app” as the workspace. This enables an Emulator to only check project folders on the Windows file system and quickly run without the delayed loading time associated with Eclipse.

Eclipse developers normally set an easily maintainable location as the workspace. However, this practice causes the above problem when using an Emulator.

Another common practice is selecting a project and pressing Ctrl+1 to run the application in the Emulator. However, this requires the IDE to first synchronize the project before running the application, which causes delay and occasionally errors.

images

Figure 3-10. Application IDE - Eclipse

Configuring the Apache Folder

Apache web server's installation folder must be entered into the SDK to locally publish an application. Please skip the next step if this was done by default.

To configure the Apache folder, select “Samsung SmartTV SDK > Samsung SmartTV SDK Preference” in the order from the Eclipse's top menu bar. Then enter the Apache folder in the “Root Folder” option on the “Apache” tab.

images

Figure 3-11. Configuring the Apache Folder in the SDK

Summary

The Samsung SmartTV SDK can be downloaded at the SDF. Although the Samsung SmartTV SDK supports multiple operating systems, it is recommended to use a Windows environment. The download includes the SDK IDE, an Emulator, and the Apache web server. There are a few additional configurations to set up, such as setting the Apache folder and the workspace, after installing the SDK.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset