The Integrated Development Environment JControl/IDE
I. Integral Parts of the JControl/IDE
This chapter gives an overview over the integrated development environment JControl/IDE. The menus, icons, the project navigator and the source code and resource editors will be explained.
Figure 1: Screenshot of JControl/IDE
Menus and Icons
Figure 2: Menu and Symbol Bars of the JControl/IDE
The picture above shows the JControl/IDE's menu and icon bars highlighted by a red frame. The menus and icons located here cover the basic functionality of the development environment. This includes the creation of new projects, the alteration of project settings, as well as the configuration of the serial port used for transferring data between the PC and the JControl device. The content of the menu bar may vary, depending on the current state of the IDE. For example, the opening of the JAVA™ source code editor adds a new menu labeled File.
Figure 3: Initial Menu Bar of the JControl/IDE
The menu items are:
- Project
- New: Opens a submenu to create new projects and new files for the currently activated project.
- Open: Opens an existing project.
- Recent Projects: The ten latest projects can be directly accessed through this sub menu.
- Save All: Saves all open and modified files for the current project.
- Close: Closes the active project. If it contains unsaved files, an appropriate warning dialog will be displayed.
- Close All Projects: Closes all opened projects.
- Refresh Project: Re-reads all files from the project's directory and recompiles all JAVA™ source codes. This comes in handy, when files are edited outside the JControl/IDE.
- Properties: Displays all properties of the active project and allows their modification, for example to change the target device type or the used libraries.
- Quit: Leaves the JControl/IDE. If there are unsaved files in any of the open projects, appropriate warning dialogs are displayed.
- Transfer:
- Upload Projekt to JControl device: The selected project will be uploaded to a JControl device which must be in download mode and connected to the PC. Modified files will be saved before the upload.
- Download Project from JControl device: If a JControl device in download mode is connected to the PC, the content of its Flash memory can be downloaded to the PC with this menu item.
- Device Browser: Opens the Device Browser. The Device Browser possesses functionality to change device system settings as well as direct access to the device's memory banks.
- Pack-N-Go Wizard The Pack-N-Go Wizard is used to create project archives to save them to disk. The archives can be uploaded to JControl devices via the Device Browser later on. This function can be useful if e.g. JControl applications should be made available for other JControl users without revealing the source codes.
- Tools:
- Simulator: Starts the active project in the JControl/Simulator.
- Terminal: Starts the integrated terminal program.
- Error Backtracking: Determines the source code location of an error that occurred on a JControl device. To get to the right source code location, the user has to enter the error code (e.g.
3
) and the program counter (JPC, e.g. 3ea5
), which are displayed on the JControl module's display on crashing.
- Extras:
- Connection: Through this menu item it can be selected which serial ports and which driver should be used by the JControl/IDE to communicate with JControl devices. As for the drivers, there are two options: The JAVA Comm API Specification 2.0 http://java.sun.com/products/javacomm/ is more stable on Windows, while RXTX-2.1-7 http://www.rxtx.org offers a better performance, but may fail in some configurations, e.g. on notebooks with an USB to RS232 adapter connected.
- Paths: Opens a menu where various paths (e.g. project paths, library paths, plugin paths, etc.) can be changed. Usually it is not required to do any modifications here.
- Editors: Shows all editors that are registered in the IDE. Some editors are already included by default as e.g. the Java editor. Changing and adding editor is also possible here.
- File Types: Shows a list of all file types known to the JControl/IDE. Further file types can be added and associated with external editors.
- Enter Registration Key: With the registration key further JControl device profiles can be activated if necessary.
- Help:
- About JControl/IDE: Shows some version information about the JControl/IDE.
Figure 4: Icon Bar of the JControl/IDE
The icon bar (fig. 4) contains a number of icons that start the most important tools and functions of the JControl/IDE on mouse click. In detail those are:
| Opens a wizard to create a new project. On pressing the small arrow beside the icon a submenu will appear to create new files for the current project. |
| Open a project |
| Saves all open files of the current project |
| Refresh/recompile the project |
| Upload the selected project to a connected JControl device |
| Download a project from a connected JControl device |
| Open the Device Browser |
| Start the simulator |
| Open RS232 console |
| Error backtracking |
The Workspace
Figure 5: JControl/IDE: Workspace
The workspace shows a list of all currently opened JControl projects. The icons in front of the name have different meanings:
- indicates a JAVA™ project
- indicates a Class project
- indicates an Archive project, i.e. a project that has been downloaded from a JControl device.
By clicking the right mouse button in this area, the
context menu as shown in figure 6 is displayed:
Figure 6: Context menu of the workspace
The option Rename allows to change the name of the selected project. The project file name will also change if the old project name and the filename were equal before. The other items of this menu are equivalent to the items in the Project menu as discussed in the previous section .
The Navigation Panel
Figure 7: JControl/IDE: the navigation panel
Most projects consist of not just a single, but a number of files. A project can contain JAVA™ source code files, images, fonts, melodies or any application specific files. All files of a project are listed in the navigation panel. If only source files (and no class files, for instance) are displayed here, Source navigator is used as an equivalent term for navigation panel.
In some cases it is required to include not only JAVA™ source code, but as well precompiled classes (extension ".class
"), for example if an external compiler is used. To be able to use such class files, the project has to be created with different settings than normal source code projects (see Creating New Files). In such a project, the navigation panel is not called source navigator, but class navigator.
With a click on the right mouse button inside the navigation panel a context menu appears that differs depending on the current state of the navigation panel (source or class navigator mode).
Note: As soon as the navigation panel receives the input focus, the menu bar will be extended by the item Edit.
Figure 8: The context menus of the source (left) and the class navigator (right)
The menu items have the following functions:
- New: Allows the creation of a new file, which can bei either a JAVA™ source code, a picture, a melody or a font.
- Open: Opens the selected file in the associated editor (in class projects only for resource files).
- Open with...: Opens the selected file with an external program, specified by the user.
- Save: Saves the selected file. This item is only available if the the selected file is opened and modified by an editor. This menu item corresponds to the save-function of the editor.
- Include...: Adds a file or a directory to the project. Only files of types known to the JControl/IDE are accepted. This includes JAVA™ source codes or classes (depending on the project type), pictures, fonts and melodies in the formats supported by JControl (JCIF, JCFD, iMelody).
- Copy Into...: Copies a single file or the content of a directory into project source directory.
- Remove from project: Removes the selected file or directory from the project. The files themselves are not deleted from the filesystem and hence can still be copied or readded to a project.
- Delete: Deletes the selected file or directory from the project and from the filesystem.
- Use As Main-Class: Marks the the class that contains the
main()
method to be executed on starting the project. Usually this class is determined automatically by the JControl/IDE, as long as there's only one class with a main method. The current main class is marked in the navigation panel with the symbol in JAVA™ projects or in class projects.
- Properties: Displays a number of properties of the selected file, such as file format or size. This is only available in source projects.
The Editor Panel
Figure 9: JControl/IDE: editor panel
The JControl/IDE contains a number of editors for different file types, all of which are displayed in the editor panel. There are editors for the following file types:
- Source code: The source code editor is opened automatically for editing JAVA™ source code files and offers syntax highlighting, to make reading easier.
- Pictures:PictureEdit is the integrated editor for JControl's JCIF images. It can import pictures stored in other formats and offers a number of tools for creating own picures, such as magnifier, lines or circles.
- Melodies: Melodies can be edited by the integrated MelodyEdit. It allows the creation of own compositions through an easy to use graphical user interface as well as importing MIDI or iMelody files.
- Fonts: Fonts can be created using FontEdit. Next to the possibility to create pixel fonts from scratch through functions similar to those of PictureEdit, it can import True-Type fonts and scale them to the desired size.
Further informations on the different editors can be found in Chapter 3.
The editor panel is used by a range of other programs. These include:
- RS232 Console: A simple RS232 terminal, which can be used to communicate with a JControl device.
- Simulator output console: JControl applications can be faithfully simulated in the integrated simulation environment (ISE). Its output console is used for displaying errors or debug information an application produces during simulation.
© 2000-2006 DOMOLOGIC Home Automation GmbH. All Rights Reserved.