To update JANOS, the JNIOR Series 4 Operating System, you will need to do two things.
- Get the UPD file on the JNIOR in the
- Execute the
jupdatecommand. To force the update to happen immediately upon entering this command we will type
jrupdate -fup /temp/janos_filename.upd
The easierst way to update the unit remotely is using the DCP The DCP is most likely to be available on a remote JNIOR because it uses a single port for all of the features. Without the DCP you might need port 23 for telnet, port 21 for FTP commands and many other ports for FTP data.
If the DCP is available follow the this procedure.
- Once the DCP is open, navigate to the Console tab.
- Login to the command console.
- Drag and drop the JANOS .upd file into the console window. This automatically stores the file in the
- Issue the
jrupdatecommand. Like above, t o force the update to happen immediately upon entering this command we will type
jrupdate -fup /temp/janos_filename.upd
At some point you may want your JNIOR to always have an output close or pulse, and when you reboot a JNIOR, they get reset. This post will show you how to have your JNIOR automatically close outputs from startup. If you’re looking for different information on the DCP, or don’t know how to access it, you can look here.
To start, make sure you are able to access the DCP (Dynamic Configuration Page) of your JNIOR. Then you’ll want to go to the Configuration tab of the DCP. Here we will be accessing the outputs section.
Here is where you can close or pulse outputs on startup. Simply add a zero to the Initial Action section for whichever channel you wish to close, and it will now always close that input on startup. To pulse the output on startup, simply add any positive value and it will pulse for that many milliseconds instead.
Analog Presets is an application that lets you control and automate expansion modules such as 4-20ma Module, the 10v Module, or the 3 channel LED module. To get started, you’ll want to download the analog presets application from the all downloads page on integpg.com. After updating your JNIOR with the application, you’ll want to go to the URL containing the IP of your JNIOR with /analogpresets after it to access the application on your JNIOR. Here you can add levels containing different commands you want to create for your modules. You can name the command, what you want it to do, how long it should last, and if you want other commands to start once it starts or finishes. You can also use these as macros by defining a port number and termination string on the general tab.
To send a macro to the analog presets application, first we’ll configure the analog presets application. Here is an example using the 3 Channel LED Dimmer. We’ll start by adding a new level at the bottom middle of the first tab in analog presets, and giving it a name. (For this example we named ours MacroTest) Once that is added, we’ll want to go to setting level and add the brightness of each output we want set. For this example, since the 3 Channel LED Dimmer has 3 outputs, we’ll set each of them to 100 by typing in the field 100,100,100. We’ll also want to go the 3 Channel LED Output Channel field and type 1,2,3 to represent the channels we want to set the brightness of. If in the setting level field we set the brightness to 50,75,100, and the 3 Channel LED Output Channel was still 1,2,3, then channel 1’s brightness would 50, 2’s would be 75, and 3’s would be 100. For this example though, we’ll set them all to 100. If you have the 3 Channel LED Dimmer plugged into your JNIOR and the 3 Channel LED Output Channel field is still grayed out, then reboot your JNIOR and it then should be configurable.
We’ll then click on the General tab of the Analog Presets application. Here we can set the TCP port that the macro will send to. (In this example we have 9700) Make sure the Termination string is \r\n.
After that you’ll need the cinema application. You’ll download the Cinema.jar application and using the update tab in the support tool load it onto your JNIOR. Once its on your JNIOR, we’ll want to go to the support tool and create a device in the device tab. We need to do this so that the macro will know what information to send. At the bottom of the Device tab, click add Device. From there, we’ll want to name our device (You can name it anything), set the device type to RAW ETHERNET, set the IP Address to the JNIOR you are using, and the port number to the one you set above in the analog presets application. (Mine for this example is 9700).
Once you have set this up, you’ll want to click “publish to JNIOR” and it will prompt you to save the device configuration as a file. Once this is done, select the JNIOR you are using as the one to publish to. Once its published, you’ll then go to the Macro tab. The first thing we’ll do here is click “link devices”, and select the device file we previously created. After this we will go to the Action view and add a new action. Here you’ll name your action (It can have any name), the device we’ll set the to the one we previously created, the action should be send, and the data should be formatted as follows:
trigger “Name of level from analog presets application”\r\n.
Once this is done, we will then add a Macro in the Macro view. First we name the macro and then we can add the action to this macro, by selecting the Macro we created, the action we created, and then clicking <- button.
Once you have done this, you’ll want to click “publish to JNIOR” like we did previously for the device tab, and create a macro file. Once that is created select the JNIOR you are using as the one to publish to. Now to test this, we’ll want to go to the tools tab of the support tool and click command line.
Once the command line is open, we need to configure the command line to create the right connection, at the bottom of the command line we’ll set the values to our IP and then the TcpPort value in our JNIOR’s Registry. You’d find this by opening the JNIOR’s web page in beacon, and then after going to the registry tab look for the path: AppData/Cinema/CinemaServerClient/TcpPort
Make sure that the value is not -1 like it is above. If it is, change that registry key. (An example value to change it to is 5000). Once you find this value, set it as the port number next to the IP address at the bottom your command line. The IP address should be the one your JNIOR has.
Also, go the options drop down list and check each option.
Now all you should have to do is click the connect button at the bottom right and type:
run “Name of macro from support tool”
This will run the macro you wanted to send to the 3 Channel LED Dimmer!
The problem: You get the following screen when trying to go to the DCP or any web page on the JNIOR.
In this image we tried to go to the
IP Address of the JNIOR. This should present us with the DCP web page. In this case we are presented with the “Page not found” response page.
This means that the file cannot be found in the filesystem for this page resource.
To troubleshoot this we need to look at the filesystem. Since the DCP is not available we need to use FTP or a telnet session.
Open Windows Explorer. In the address bar type ftp://IP ADDRESS. You might see the message that Windows Explorer cannot access your folder.
Most likely this is because you need to provide credentials. To do that you need to right click in the white-space in the window and select Login As…
Once you log in navigate to the flash directory.
If the the DCP or default web page is missing then all of the following must be met:
www/directory is missing or there is not an
index.phpfile in the
public/directory is missing or there is not an
index.phpfile in the
We can use Telnet to look at the filesystem as well. To do this, open your favorite Telnet application. Make a connection to the JNIOR. Log in. You will then use either the
dir command or the
ls command. Both commands are the same and will list the directory contents.
Use the command of your choice, whichever command is easier to remember, and add “flash” as a parameter. This wil cause the command to list the contents of the flash directory. If the the DCP or default web page is missing then all of the following must be met:
www/directory is missing or there is not an
index.phpfile in the
public/directory is missing or there is not an
index.phpfile in the
MODBUS is a communications protocol used to communicate between a master and a slave or several slaves. The JNIOR implements MODBUS TCP. MODBUS TCP is the form for this protocol over the Ethernet network. The JNIOR acts as a slave by accepting requests and forming responses. Since Ethernet networks call devices clients or servers, the JNIOR is a server. Therefore the JNIOR has an application called MODBUS Server to handle the MODBUS TCP requests.
The MODBUS Server application is NOT enabled by default. It must be enabled before MODBUS masters or clients can send requests to the JNIOR. Once enabled the JNIOR will begin listening to TCP connections on port 502.
To enable the MODBUS Server you should go to the DCP (Dynamic Configuration Page).
Then navigate to the ‘Configuration’ tab.
Now, select ‘Applications’ halfway down the left side. Make sure the MODBUS Server application is checked
Reboot the JNIOR.
You can then optionally make a telnet connection to verify. The
ps command to make sure the
modbusserver application is running. Then you can use the
netstat command to see that port 502 is listening.
Once a JNIOR is up and running in an application it rarely needs attention. In fact many users forget that it is even there. It is however good practice to check the system logs once and a while. Fortunately there are a number of ways that you can do that. If you open the DCP (Dynamic Configuration Pages) by accessing the unit with a browser there is a ‘Syslog’ tab. This displays the log with the most recent events right at the top. You can also go to the ‘Console’ tab or otherwise open the Command Line through a Telnet connection or the serial port where you can list the log content directly to the screen or window. In this case the latest entries are the last listed.
If you are developing a new application and testing it on the JNIOR you may wish to monitor the log more closely. Naturally you can leave the DCP open on the ‘Syslog’ tab and new events would just pop up when they are logged. That might not be as convenient as it sounds especially if you are building a network-facing application and are constantly testing and working with the JNIOR using various browsers. Perhaps you are rebooting the unit causing the DCP to reconnect far too often. More typically we periodically make a Command Line connection through Telnet and manually list the log. Here we make use of the CAT command.
mqtt-test /> help cat CAT filespec Options: -H Dump file in hex -J Formats JSON -P Displays last page Displays the contents of a file. Aliases: CAT, TYPE mqtt-test /> cat -p jniorsys.log
jniorsys.log file is limited to about 64KB characters. That can represent a lot of lines. Do you really want to list those every time? Here we see that the CAT command also provides the -P option which will show only the last page (25 lines) of the file. Of course you do have to remember to include the option. One side note here is that with JANOS you can supply the options anywhere on the line. So if you at first forget to include the -P you can place it after the filename. No problem.
We can improve on this by making use of JANOS batch file capabilities. A batch file is a kind of script file that can contain commands to be executed one after another. Most operating systems, JANOS included, provide some facility for batch execution. But you might be wondering how do you create batch files or if you do that externally how do you get them onto the JNIOR? Well here’s a tip: You can create them on the fly. Of course, the simpler the file the easier that can be accomplished.
For example we will create a simple batch file called
log.bat as as kind of short hand that we can use when we want to display the System Log. Here we simply ECHO the command routing the text to the file. Immediately we can use the short batch file name to execute the command.
mqtt-test /> echo cat -p jniorsys.log > log.bat mqtt-test /> log cat -p jniorsys.log 10/03/18 18:54:15.850, FTP/10.0.0.27:58531 uploaded /flash/MQTT.jar [325.8 kbps] 10/03/18 18:54:24.571, ... (etc.)
Here we see that we used the ‘>’ pipe character to route the output to the specified file. If you need to build a batch file with more than one command you can append to it using ‘>>’ as well. The power here comes in combining commands to achieve some goal. The advantage being that you can repeat the procedure easily using the batch file name as shorthand. While batch files in JANOS are not as fully featured as you will find in Linux or MS-DOS systems most of the basics are there.
Suppose instead we want to list only today’s events. Here we create our batch file in way that lists only those entries with today’s date. Check it out.
mqtt-test /> echo grep %DATE% jniorsys.log > log.bat mqtt-test /> log grep 10/04/18 jniorsys.log 10/04/18 12:10:48.657, Ending session Command/10.0.0.27:64514 (pid 132) 10/04/18 12:37:53.642, Command/10.0.0.27:64075 login 'jnior' (pid 405) 10/04/18 12:38:05.179, FTP/10.0.0.27:64118 login 'jnior' 10/04/18 12:38:05.711 ... (etc.)
And there you go. You now have a simple way to check recent System Log activity. Now I bet that you are thinking how you might alter this to be even more helpful. Well, if you find that you cannot achieve what you have in mind just let us know. An advantage that you have with INTEG is a direct link to the technical team and the advantage we have is the power to implement what you need.
DCP stands for “Dynamic Configuration Pages”. This is just a fancy name for the default website served by the Series 4 JNIOR out of the box. Once you have powered your JNIOR, connected it to the network, and assigned it an IP Address you can access the DCP using your favorite browser. This website is contained in, and served from, the
/flash/www.zip file on the JNIOR.
You can use the DCP to monitor your JNIOR. Through the Input/Output tab you can see the status of each Digital Input and Output Relay. This tab offers two pages (listed down the left column). These are the Internal I/O and External I/O pages. If you log into an account with sufficient permissions you can control the relays. The appearance of this page can be configured through the Configuration tab. The labels can be redefined as might be appropriate for your application. You can remove unused inputs and outputs and even mask features such as usage metering if not of use.
The External I/O refers to external modules that you may optionally use with your JNIOR. INTEG can supply a Power Relay module, analog modules for 10V or 4-20ma, and even temperature sensors. One or more of these may be daisy-chained on the Sensor Port. If you have any of those they can be monitored and controlled in the External section of the Input/Output tab.
The Configuration tab is available only to Administrator accounts. This provides a dozen and a half pages covering most every aspect of your JNIOR.
The Display page configures settings that affect the appearance of the Input/Output Internal page. Here you may disable any channel which simply removes the channel from view on the Input/Output tab. This does not disable the function of the input or output. It merely allows you to hide unused or background channels. Similarly you can hide Counters, Usage Meters, Alarm indications and Controls. For relay outputs you can select the Pulse control instead of Toggle if appropriate. You may even alter the coloring used in showing the input or output state.
Note that each item of configuration is associated with a Registry Key. If you hold the mouse over a setting the related key is displayed in a Tooltip. Configuration settings that differ from default will appear in the Registry which can be viewed and edited directly using the Registry tab. More on that in a bit. While the mouse is hovering you may hit F1 to view the built-in Registry documentation.
The Labels page provides the ability to configure the text displayed on the Input/Output Internal page. In addition to Descriptions and I/O State labels you can change the units for the Counter.
This page is shown for the Model 410 which has 8 inputs and 8 outputs. The DCP will display different arrangements for the Model 412 and 414. The former having 12 relay outputs and only 4 inputs. The latter with 12 inputs and only 4 outputs.
The Inputs page affects the function of each input. Here you can configure inversion, debounce and a number of other characteristics for each of the available inputs.
A Block Diagram is available through the provided link to help in visualizing input configuration. We can cover the details under another topic.
The Counters page sets counter configuration for each input. The JNIOR counts each activation of an input. Here you can configure how that is to happen and how it is displayed. You can scale a counter if each activation represented a number of items or a fractional amount of something. Here you can see the value of changing the displayed counter units which are configured on the Labels page.
Here you can also configure two different Alarm levels. Alarms are displayed on the Input/Output Internal page. They are also Events that can issue email notifications.
On this page you can also mouse over an input and click the displayed “X” to easily reset a counter to 0.
The Outputs page provides state configuration for Usage Metering. The JNIOR tallies time for each activated input or output. This would potentially be useful for Preventative Maintenance. Here you can also set the default Pulse duration that would be used if you elected to configure a Pulse control (button) for the output on the Input/Output Internal page. If you want more information on this section, click here.
The Metering page displays the accumulated time for each Usage Meter. Like the Counters page you can mouse over a Channel and click the displayed “X” to reset the usage. Here you can also set the active usage state and configure alarms. This alarm can be set to send an email notification on the Events page.
The JNIOR has two serial ports. The Serial I/O page can be used to set communications parameters for each port. The defaults are shown.
Generally an Application Program is used to perform communications over a serial port. The program itself may configure communications parameters. There are times where you may wish to set the parameters outside of an application. The IOLOG command provides access to a Transmission Log for the AUX port. You can set the Baud Rate and then check the IOLOG to see if data has been received properly.
The Applications page lists Registered Applications. Applications are automatically Registered during boot provided that a JAR file exists in the
/flash folder containing a properly formatted
appinfo.ini file. The content of the Applications page then may vary significantly from one JNIOR to another.
An application may be set to run at boot. When you check the box associated with the application the appropriate Registry Run Key is created. On reboot the application will automatically start. If available a link is displayed that can lead to additional configuration pages specific to the application.
Note that the checkbox only affects the status of the application after boot. The starting and stopping of applications at any other time is performed at the Command Line which can be accessed through the Console tab.
Each JNIOR has the ability to send email notifications. Applications can be written to generate emails and potentially received them. Outgoing email requires a valid client account. The Mail-Account page is used to configure the outgoing email capability.
Here the Mail Server is something like
smtp.comcast.net and the From Address would be the email address for a Comcast account. When you enter the SMTP Username you will be asked for a valid Password. The password is securely stored in the Registry. The remaining settings define the SMTP port, security and other characteristics for the communication. These are the credentials use in submitting outgoing emails.
Email notifications can be generated for a number of Events if enabled. JANOS has default structures for those notifications. You can optionally define any number of custom email messages as Profiles using the Mail-Profiles page. When the default content is insufficient these profiles can be referenced by name to define custom email recipients and content.
There is a small set of built-in events. The Events page is used to configure the actions associated with those events. For the most part this involves enabling an email notification and defining an optional email profile.
Beyond those listed here an unlimited number of events and actions can be accommodated through application programming or direct configuration of the Registry.
Note that the automatic starting of application programs can be disabled here without need for removing the Run keys.
The JNIOR is shipped configured with an IP Address of 10.0.0.201. This likely will not work for you.
To configure the network addressing you can run the Support Tool. The Support Tool is a Windows application that you can download for free from the INTEG website http://www.integpg.com/support/jnior/. You can also make a serial connection to the RS-232 (COM) port and use the IPCONFIG command at the command line.
Once you can access the DCP you can modify settings through the Network page.
The Security page offers a couple of settings.
The Series 4 JNIOR can perform secure communications using Public Key encryption and SSL/TLSv1.2. By default a 1024-bit RSA key pair is used in concert with automatic self-signed certificates. This means that you can access the DCP using a HTTPS connection. You can also perform secure FTP transfers and Telnet connections. The latter is best done with a client program available from us. Of course, you do not need either FTP or Telnet as the DCP offers most of that functionality.
While it doesn’t seem prudent you can disable the SSL capability here by deselecting SSL Enabled. Perhaps more appropriate is enabling SSL Required. In this case FTP and Telnet connections must perform STARTTLS and proceed securely. The standard HTTP port (Port 80) is closed. You can continue to make the secure connection using HTTPS (Port 443). Email will only be transmitted securely.
IP Address filtering is available. The Allowed IP Addresses field can be set with a comma delimited list of IP addresses that can make connection to the unit. This field can also contain a sophisticated filter string. It is recommended that the documentation (use F1) be viewed before setting this field. You can block yourself. In that case you will need to make the serial Command Line connection and remove the filter through the REGISTRY command.
The Telnet page simply lets you relocate the port. You may want to do that to hide it from casual connections. You can also disable the server entirely. You can do that since you can access the Command Line through the Console tab of the DCP.
The WebServer page is used to configure the Web Server. Here you can relocate either the HTTP or HTTPS ports or both. You can disable the Web Server entirely. That also prevents use of the DCP but your application might demand the limited access.
By default web access requires a login. You can disable the login requirement and to do so you must also define a user account for anonymous access. If your JNIOR is physically secure and the network is isolated from the larger network you might disable the login. If otherwise you have some pages that you wish to share publicly you can place them in the
/flash/public root. Pages are served from that area without the need for authentication.
You can relocate or disable FTP using the FTP page. You can disable FTP and still manage the JNIOR’s file system through the Folders tab of the DCP.
Anonymous FTP access is not recommended. You can allow that by defining a user account to be used for that.
The JNIOR Protocol is deprecated and not recommended for new applications. The Series 4 offers a more modern Websockets interface which performs all of the same function and much more. It is also not binary. The JNIOR Protocol is still supported.
The Protocol page can be used to relocate the JNIOR Protocol port. The server can also be disabled.
We would recommend disabling the JNIOR Protocol unless you know that it is used. It is also highly recommended that the login requirement not be disabled. If you do so you must then define a user account for the anonymous access.
And finally for the Configuration tab is a page for the configuration of external modules. If you use an external module it will be listed here on the Modules page. If you have recently connected a module and don’t see that one you can select ‘rescan’ to update the list.
If the external module has configuration setting those can be seen by expanding the module. Click the triangle shape. For instance the 4ROUT labels can be altered for use on the Input/Output Externals page.
The Console tab provides access to the Command Line interface. This is similar to a Telnet connection but performed entirely through the web interface (Websockets). Note that an additional login is required here.
You can cut and paste here. That would be one advantage over a Telnet client. You can also drag a file to this window. That will place the file into the
/temp folder convenient for further use from the command line. You might drag a UPD here and once it transfers use the JRUPDATE command to update the operating system as an example.
You can navigate through folders by clicking on the left tree or double-clicking folders on the right as you might expect. Files can be selected and downloaded. You can also delete files and create folders. Drag and Drop is supported both into and out of the folder. Although in that case there is some variation in availability depending on the browser you are using. I use Chrome extensively. That seems to provide all of the needed capability.
If you need to move entire folders including subfolders then FTP is a better bet. Here I recommend FileZilla. https://filezilla-project.org/
The Registry tab provides an explorer view into the Registry. Here you can edit and remove keys as needed. Each setting found in the Configuration tab is associated with a Registry Key. You can make settings here if you know the proper key and format.
It is recommended that you become familiar with the Registry, There are some settings that are not accommodated by the DCP GUI. You will need to enter those here. The Registry can also be manipulated from the Command Line.
The DCP contains built-in and detailed Registry documentation.
The Syslog tab displays the System log detail in chronological order with the most recent event at the top. This is the content of the
/jniorsys.log.bak files concatenated. You can scroll then through all of the available log history in order from most recent to the oldest.
Here I’ll show a segment of the HoneyPot Syslog since my development unit sees a lot of crazy use and its log is full of confusing stuff. In fact you can see in this log where JANOS was recently updated. The infected.json file that keeps getting updated is the database for the http://honeypot.integpg.com/map.php application running on that unit. The HoneyPot JNIOR is connected directly to the Internet.
The Peers tab provides quick link access to other JNIORs that you may have on the network. The Series 4 JNIOR is aware of nearby peer products. Here you can move to the DCP on these other units using the link provided. That can be convenient if you have many JNIORs. Okay, so here at INTEG the Peer list gets crazy.
For many this list will be short if there are any at all.
And FINALLY! We have the About tab. This actually contains some text and potentially useful information.
When you open your browser and point it to your JNIOR you should get the DCP by default. If you still get the old applets then you need to update your JNIOR. We highly recommend that you always run the latest version of JANOS and DCP.
But what if you are running a special application and you want your own web page to come up by default. How do you then get to the DCP or get it out of the way?
The DCP is stored within and served directly from the
/flash/www.zip library. You can move that file into the
/flash/www folder and rename it something like
config.zip. So now you have the file
Now since the default root for the WebServer is /flash/www if you point your browser to the JNIOR and add
/config to the URL you should get the DCP. The URL will be something like the following:
Did you know that the DCP includes documentation in the form of Help?
Many of you have seen the Registry Key Assignments document. Well we no longer maintain the PDF of that. The most current Registry documentation is distributed with every JNIOR as part of the DCP.
Every configuration setting is associated with a Registry Key. Simply by placing your mouse over a setting a Tool Tip will display the associated Registry Key for you. You can make use of that if you want to access the Registry by some other means.
A link will also display at the bottom of the page as shown above. If you can remove your mouse from a setting without mousing over another you can then click the link to access the documentation. You can also use the F1 key while holding you mouse over a setting to access the documentation.
A form of context help is provided by opening the distributed Registry Key Assignments document and indexing to the referenced key.
Note that you might need to update your operating system (JANOS) to the latest to get access to all of these features. If you update manually (use JRUPDATE) then you will also need to update
/flash/www.zip to install the latest DCP. And if you still get the old applets when you open your browser, then there is probably a
/flash/www/index.php or similar index file in that folder that you will need to remove.
If you update using an update project in the Support Tool it is likely that the project takes care of these steps for you.
If you are working at the Command Line through a Telnet connection and want information on a particular Registry Key or setup, simply open your browser to the DCP and hit F1. If you are working in the Console Tab (DCP access to the command line interface) the F1 keystroke gets you to that document as well.
Or you can enter a URL to read it directly as follows:
Okay, so you might search all through your JNIOR’s file system and not find any
RegistryDoc.html file. That is because it is contained within the
/flash/www.zip library and JANOS knows how to serve files directly out of a compressed library. It can locate the files using the path to the library, the name of the library and any path therein up to the filename. And since the default root for the Webserver is
/flash/www it knows to look right in there.
The Series 4 supports a built-in Websockets interface. Websockets operates through the standard HTTP ports and is supported by all browsers. The JNIOR Websockets interface supports all of the same functionality of the JNIOR Protocol and much more. The JNIOR Protocol is a binary protocol and challenging to implement. Websockets is JSON based and much more straight forward.
If your Series 4 is still presenting you with the applet issue, you need to update. We recommend always that you run the latest JANOS release. The update project for that will replace the applets with the DCP.
You should be running at least JANOS v1.6.2. If you update JANOS manually using a UPD. The DCP is installed by copying the
www.zip file into the
/flash folder. You should also make sure that any
index.php file is removed from the
www.zip folder should not be expanded as JANOS serves files directly from the compressed library.
This is what the DCP looks like.