Author Archive for xcosminel

How to add a MediaWiki article to a category

Assigining your articles to corresponding categories is very important for helping your visitors navigate your MediaWiki site with ease. Thankfully, MediaWiki comes with an included system for handling categories.

To add an article to a category:
Simply edit the article you want to add to the category, and add the following line at the end of the contents:

[[Category: Nameofcategory]] (where Nameofcategory is your category name)

It doesn’t matter if the category does not exist or was never used before. MediaWiki will create a new page for each category containing all of the articles that were added to it.

Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have

Pasting from Word into Wordpress (Paste from Word)

There is a common issue when posting from Word into the Wordpress editor which causes problems when trying to view the article using the Internet Explorer browser (it simply won’t display).

The reason behind this is because Word uses some unstandardized tags for its formatting, and those tags are not recognized by IE.

Quick Fix (and a really bad way to do it):

To quickly fix an article where the issue occurs, follow these steps:

  • Go back and edit the article.
  • Switch from Visual view to HTML view.
  • Remove any text occuring before the tag, including the tag itself.
  • Switch back to Visual view and see if the article was fixed.
  • Update the article.

Currently a few different plugins for WordPress are being developed which should stop the issue from occuring. I haven’t found a working one yet. If anyone does please comment away!

Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have

Get to know your Power Meter – What is Real, Apparent and Reactive Power

First – a simple question

  Right or Wrong? Power = Voltage x Current

That statement is correct for DC systems but there are two major complications for AC systems.

  • The value of current and voltage keeps changing. Which value do you use ?
  • The voltage and the current may not be in phase. Multiplying the current and the voltage when they are not in phase requires and adjustment to compensate for the phase. It is this phase shift that forces us to define Real, Apparent and Reactive Power.
    This phase shift occurs when a power source feeds an inductive or capacitve load”. Most loads are either inductive (motors) or resistive (heaters) and therefore the phase shift is typically in one direction.

    • A motor has a winding. A wound conductor essentially defines an inductor. Thus the winding presents the resistance of the wound wire and the inductance resulting from the winding.

 

 

 

RMS or Effective Value

  Peak values in the alternating voltage or current curves only lasts a short instant. They are not really representative of the ability of the voltage and current to do work and thus they are not used in Power Calculations.Scientists use a statistical method to define the effective values. It is called the RMS or Root-Mean-Square values. The result of the definition is that:Veff / rms = 0.707 x Vpeak

The same applies to current too.

TIP: You can reasonably assume that all the Voltages and Currents reported by a Power Meter are reported as RMS or Effective values unless otherwise indicated.

TIP: Most multi meters report RMS values

 

 

 

Apparent Power

  Apparent Power is the power delivered by a power source to a load like a motor. In almost all real world situations that use AC, you need to supply more power (Apparent Power) to a device than it will do work (Real Power).The (vector) difference between the two represents the work done to overcome the inductive and capacitive effects of the load.Apparent Power is measured in units of VA – Volt-amperes. These are actually Watts but we use the new unit name to reduce confusion. Thus when you see VA on a data sheet you can reasonably conclude that they are talking about Apparent Power.

Apparent Power is calculated:

S(Common symbol for Apparent Power) = Veff / rms x Ieff / rms – Single Phase Calc

 

 

Power Factor and Phase

  Power Factor is calculated: PF = Cosine ( phase angle in radians)Power factor has no engineering units.The value of PF ranges from -1 to 0 to 1 (lagging – none – leading)

Loads that only present a resistive load (no capacitance or inductance) have a PF of 1.

Inductive Loads

 
Current phase lags the VoltageTypical – Transformers and motors (wound conductors) 

Capacitive Loads

 
Current phase leads the VoltageTypical – Buried Cables, capacitor banksThere is nothing ‘wrong’ with having a power factor that isn’t 1.0.

 

 

Real Power and Reactive Power

  Think of Real Power as useful power – a measure of how much work is being done.The units of Real Power are Watts.Real Power is calculated : P(Real) = S(Apparent Power) x pf

Reactive Power is the (vector) difference between Apparent Power and Real Power. The energy used to produce the Reactive Power is stored in the magnetic/electrical field of the Inductive Load. In the case of the capacitive load the magnetic/electrical field of the Inductive Load produces the Reactive Power. Reactive Power cannot be harnessed to do useful work.

Reactive Power is identified by the symbol : Q

The engineering units of Reactive Power are VAR – Volt-amperes Reactive. These are also Watts but we use VAR so that we know we are talking about Reactive Power.

 

 

Diagram: RMS measurement

diag11

Diagram: Leading / Lagging

diag21

THD – Total harmonic Distortion (also called Distortion)

  In simple terms THD is a measure of distortion reported as %. If a device (any active device but think of rectifiers, variable speed drives … as practical examples) is given a sine wave as in input the output is never a faithful 100% reproduction of the input. A series of harmonics of the original wave distort the original wave form. The THD % is an attempt to ‘numberize’ the degree of distortion to allow for comparison. The % number is somewhat controversial because some harmonics are more important than others and there is no weighting.THD(%) = 100 * SQRT[(V22 + V32 + V42 + ... + Vn2)] / VtWhere V2, V3 are the RMS values of each voltage harmonic and Vt is the total RMS output voltage.

 

 

 

Sag / Swell or Dip / Surge

  Duration is 0.5 cycle and greater. Voltage sags are the most common power disturbance. Voltage sags can arrive from the utility. In most cases, sags are generated inside a building. For example, in residential wiring, the most common cause of voltage sags is the starting current drawn by refrigerator and air conditioning motors.Sags do not generally disturb incandescent or fluorescent lighting. motors, or heaters. However, some electronic equipment lacks sufficient internal energy storage and, therefore, cannot ride through sags in the supply voltage. Equipment may be able to ride through very brief, deep sags, or it may be able to ride through longer but shallower sags. 

 

 

Under / Over Voltage

  Over Voltage is an increase in effective voltage to more than 110% for longer than one minute. Under Voltage is a decrease in effective voltage to less than 90% for longer than one minute. Take care with this definition because it tends to change from vendor to vendor.  

 

Transient Voltages / Spikes / Surges

  Refers to short duration (less than 1 cycle) events. Low frequency transients are often called “capacitor switching transients”. High frequency transients are often called impulses, spikes, or surges. They can be caused when a discharged power-factor-correction capacitor is switched on across the line.High frequency transients are caused by lightning, and by inductive loads turning off. Typical rise times are on the order of a microsecond; typical decay times are on the order of a tens to hundreds of microseconds. Often, the decay will be an exponential damped ringing waveform, with a frequency of approximately 100 kHz.Extremely fast transients, or EFT’s, have rise and fall times in the nanosecond region. They are caused by arcing faults, such as bad brushes in motors, and are rapidly damped out by even a few meters of distribution wiring. Standard line filters, included on almost all electronic equipment, remove EFT’s.

 

 

 

Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have

Hubs vs Switches – Using WireShark to sniff network packets

Gotcha #1 : Use a hub not a switch

 
Why: Switches don’t copy all messages to all ports. They try and optimize traffic so when they learn which port a device is connected to they send all messages intended for that device to that port and stop copying to all ports. (The jargon they use for this function is ‘learning mode’)

How do you know it’s a hub: Just because it calls itself a hub doesn’t mean it is one.

  • If it says full-duplex in the product description it’s probably not a hub.
  • A switch that allows you to turn off the learning mode is effectively a hub.  
  • A switch with a monitored port copies all messages to the monitored port and thus you can use that port as if it were a hub. 
  • If it says ‘switch’ and you cant turn off learning mode and it doesn’t have a monitor port then it is not a hub. 
  • A router is never a hub.

 

Gotcha #2 : Mixing 10 and 100 mbits/sec can cause problems.

 
Not all hubs copy 10mbit messages to 100mbit ports and vice versa.Use a 10mbit/sec hub if you are on a mixed network – almost all other faster devices are speed sensing and will downgrade themselves to 10mbits/sec and thus you will see all the packets. This is not true of some building automation engines where the speed of the port is configured.

You can work around this problem by connecting higher speed devices to a self sending switch/hub and then connect that switch/hub to the 10mbit hub.

Recommended Hubs

  • 10Mbit/sec Networks – DX-EHB4 – 4 Port 10 Mbps HUB
  • Netgear – DS104 Dual Speed HUB
  • 10Mbit/sec Networks – D-LINK DE-805TP
Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have

BACnet BBMD

The BACnet discovery uses two services – called ‘Who-Is’ and ‘I-Am’. They rely on the use of broadcasts.

Routers join IP networks together so messages from one network can be sent to another. Most routers do not forward broadcast messages and this means discovery cant discover devices on another network.

To solve this problem BACnet provides a technology called BBMD – BACnet/IP Broadcast Management Device.

In overview the technology is simple. You install a BBMD (might be a physical device or just a software application on a computer) on each network. You can configure the BBMD by specifying the IP Address and mask of the each BBMD. This makes both BBMD configs identical. When the one BBM receives a broadcast, it forwards the messages to the other BBMD which in re-broadcasts on the other network. They are configured by BDT files and these may be modified on the fly using selected Bacnet services.

The technology also provides for foreign device registration. This allows a device on one network to communicate with a device on another network by using the BBMD to forward and route the messages.

Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have

RS485 on a Scope

Using an oscilloscope on a RS485 network. For reference purposes we present some scope captures of a typical RS485 line.

plus_gnd_connected_bytes

In this capture we had our scope leads connected to the positive signal conductor and ground.

Zone A: Idle State

Zone E: Idle State with Noise
This is the state of the network when all the transmitters have released the line. In this state the conductors float. In many ways this is the most dangerous state for a 485 network to be in since the voltage levels are not defined and vary depending on factors such as the ground potential between devices. If the voltage floats to a level where it looks like a signal then you will see noise bytes on the line. Once a device starts transmitting it pulls the line to a known voltage level so the floating problem is eliminated. Its usually quite easy to recognize these noise bytes because all messages look good but there is noise that precedes the message. Idle state biasing can be used to eliminate this problem because it has the effect of holding the line at a ‘known’ voltage for the duration of the idle state. Another source of idle state noise is not using the 3rd conductor – the so called signal reference common.

Zone B: The device has enabled it transmitter but has not started transmitting. The line is driven to a known state. The duration of this phase can be controlled by configuration in some devices. If it is too short then it is possible that some of the front of the message may be lost.

Zone C: Unless you have a very high speed scope and the scope can takes a huge number of samples you are unlikely to see each bit in the message. In this capture we can see the bytes (roughly speaking) but not the bits. We were forced to accept this compromise because the number of samples we could capture at a sampling rate high enough to see the bits would mean that we could only capture the 1st couple of bytes of the message and we would have to set the trigger to ignore zone B. Except with a very expensive scope you will be unlikely to be able to see the whole message and all the bits.

Zone D: We have finished transmitting but the transmitter is still enabled. Normally the device should disable its transmitter as soon as possible after transmitting the last stop bit of the message but since that can be difficult to achieve in the hardware, many devices run a timer to make sure they don’t disable the transmitter too soon. The problem with this approach is:
1) The longer the time the more potential bandwidth is lost.
2) The receiving device may have already processed the message and try to send a response by enabling its own transmitter causing collisions.

plus_minus_connected

Probes on plus and minus conductors. Segment connected to slave device.

plus_minus_not_connected

Probes on plus and minus conductors. This chart represent the capture from a master device with no slaves connected to the network leaving the cable ends to float.

Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have

CAS Modbus Explorer

Modbus communications not working ? How do you know what’s wrong – is it the baud rate, the parity or even the address? There are so many things that can affect communications.

The Modbus protocol does not support discovery. There is no broadcast message that you can send that will make a slave respond with its port and address settings. The protocol allows for broadcast messages to be sent but doesn’t demand that every vendor supports this feature.

modbusexplorer

Use the CAS Modbus Explorer to find the correct port settings and the correct slave address.
The tool automates the process of trying all the combinations and reports the results. We provide burst and standard mode. In burst mode we send messages to all the possible slave address before waiting for a reply from any of them. This dramatically improves the time required to do the discovery.

The tool works for RS232 and RS485 by allowing you to search for a single device or multiple slaves. To connect to a RS485 network from your laptop you simply need a USB-to-485 converter.

Here is the problem – there are thousands of combinations:

 

Baud 300, 600, 1200, 2400, 4800, 9600, 19200, 38400, 57600, 115200
Parity, None, Odd, Even
Stop Bits 1, 2
Data Bits 7, 8
Address 1-254

 

If you had to manually search/test all these combinations it will take you ages. Relax, go for lunch and let the CAS Modbus Explorer do all the work for you.

Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have

FieldServer’s Web Server

In a nutshell:

  • The FieldServer reads data from field devices.
  • This data can be used to animate web pages that can be served by the FieldServer.
  • Using a browser, a customer or user can monitor data from field devices and also control them.

july08art2pic1

A little more detail:

The FieldServer Web Server allows you to display and change data in a FieldServer. The FieldServer’s data is obtained by communication with remote devices such as gas Detectors, Lighting Controllers and many more.

The web server is a front end HMI (human machine interface) that can serve screens and data to any web browser such as Internet Explorer. Amongst other things, it allows your users to view and change values on your devices with out having to install any special software or be anywhere near the site.

Since the system is built in to a webpage, most of your users should already have the required skills to operate the system (click the link, push a button, flip a switch), a lower learning curve and less training. So simple that just about anyone can operate the system.

Your users can connect and change values on your devices from anywhere that has an internet connection and a web browser. Imagine sitting down in the comfort of your own home, and browsing to your site, viewing the status and making any changes that are needed, then rolling over and going back to sleep, with having to set one foot on the site.

The values on your device can be displayed in a number of ways from simple text and progress bars to animated images and sliders, its up to you how you want to display your data and the system is flexible to do just about anything you can think of, while remaining simple enough for anyone to use.

The system uses a simple template tag system to display and change the data on your devices; these tags can be inserted in to any html document and placed on the FieldServer. The server will then will run thou and strip out these tags and replace them with the data from your device. Its much simpler then it sounds, put this tag where you want to show your data. The template tags are built with web designers in mind, there simple to use and simple to debug.

 

How it all works:

This system works by creating a mini web server on our FieldServer that the users can browse to. When a user browses a webpage, the FieldServer searched the html document for special template tags, if the FieldServer finds these special template tags in the html document, it replaces them with data from your device. When you push a button on one of these web pages, the value is sent from your webpage to the FieldServer, to your device.

july08art2pic2

Step 1: FieldServer is configured to read data from field devices using RS232/ RS485/ Ethernet, Controlnet, DeviceNet, DH+, Modbus+ and any combination of drivers from the extensive protocol library. Over 100 protocols are available.

Step 2: A browser surfs the FieldServer. Pages served are just like any other html pages except that they can include animations based on the real time data obtained from the field devices. The pages can also contain elements to change the data in the FieldServer. These changes then get sent back down to the field devices, if this is what you require.

Step 3: Data read from the field devices can also be served to other field devices using another protocol. It depends on your requirements.

 

Examples

 
These are some of the examples you can produce with this system, the system is only limited by your imagination.
 

Simple Example

In this simple example we are only using the very basics of the template system, (display text and action buttons) but you can instantly see the power of this system, its easy to read, it’s easy to operate, it provides all the information that the user needs about the building.

july08art2pic3

Sleek and Pretty Example

In this example we put an information tag on an image of the factory; the loading doc has two tags associated with it, Lights and AC. You can see that the lights are on and the AC is off, the boarder is flashing red indicating a panic, the user then could click on this tag and get a screen similar to the one above where they can get more information and acknowledge the alarm.

july08art2pic4

Mirror example

In this example we copied the front display of the real device, anyone that has used the device before can quickly and easily navigate this interface.
july08art2pic5

Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have

FieldServer Gateway (Dual Serial)

Dual Serial – Ethernet

FS-B2510

The FS-B2510 Dual Serial-Ethernet gateway provides a wealth of features to enable data transfer between different devices and networks utilizing serial and Ethernet protocols. The extensive library of FieldServer drivers provides easy interoperability with devices and networks used in building automation, HVAC, fire and process control industries. The FS-B2510 is particular cost effective in the integration of two devices/systems utilizing serial protocols such as a fire alarm control panel to BACnet MSTP.

The FS-B2510 is one of the FS-X30 Series FieldServers designed to meet the needs of system integrators in designing a complete interoperable system. The FS-B25 Series brings together the powerful FieldServer driver library with state-of-the-art gateway design. This FieldServer includes twi serial connections (RS-232 or RS-485, software selectable) and one 10/100BaseT Ethernet ports. The multiport design allows for serial-to-serial interfaces or interface from mulitple serial products to an Ethernet or LonWorks network. The Ethernet port enables the integrator to connect a PC to download configuration changes without disturbing the system connections and without the additional cost of an external hub.

CAS sell, support, install, configure and develop custom drivers for FieldServers. With every FieldServer purchased from CAS that includes a BACnet protocol we provide a free license to the CAS BACnet Explorer which can be used to test / prove the BACnet interface is working.

Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have

Ethernet Cables – Cat5 and Cat5e

Where do the terms Cat5 and Cat5e come from?

TIA Telecommunications Industry Association, TIA defined standard TIA-568-B which defines the cables and structured or modular cabling systems and termination standards for building and telecom cabling systems.

Cat5 and Cat5e Cable’s What is the difference?

  • Very simply put: The 5e cable is tested to a higher standard. A manufacturer may produce a single cable and only test some of it to the 5e standard. The physical characteristics of the cable are no different but the Cat5e’s higher specification makes it suitable for Gigabit Ethernet.
  • Whilst we are on the subject what about Cat6 ? Bandwidth is 2.5 greater at 250MhZ and that’s probably the limit with RJ45 connectors. You might be future proofing using this cable but you could also be wasting money. Also remember that Cat6 is a high tech cable and requires connectors and patch cables assembled to meet the standard.
  Category 5 Category 5e
Frequency 100 MHz 100 MHz
Attenuation (Min. at 100 MHz) 22 dB 22 dB
Characteristic Impedance 100 ohms ± 15% 100 ohms ± 15%
NEXT (Min. at 100 MHz) 32.3 dB 35.3 dB
PS-NEXT (Min. at 100 MHz) no specification 32.3 dB
ELFEXT (Min. at 100 MHz) no specification 23.8 dB
PS-ELFEXT (Min. at 100 MHz) no specification 20.8 dB
Return Loss (Min. at 100 MHz) 16.0 dB 20.1 dB
Delay Skew (Max. per 100 m) no specification 45 ns

Source: discountcablesusa.com

Ethernet Cable Color Coding

There are two color coding standards. The color coding standard does not affect whether the cable is a cross-over or straight through patch cable. Color does not affect performance or use of the cable.

Standard 568A   Standard 568B
This is the most commonly used for patch cables.
1 White-Green   1 White-Orange
2 Green   2 Orange
3 White-Orange   3 White-Green
4 Blue   4 Blue
5 White-Blue   5 White-Blue
6 Orange   6 Green
7 White-Brown   7 White-Brown
8 Brown   8 Brown
Did you like this post?

Subscribe To The RSS Feed!
To catch many more articles like this in the future, make it easy on yourself and subscribe to me via RSS. You will not regret it!

Do you have a question?
We will do our best to try and solve any building automation, protocol, integration problem you may have