<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Zachary Gracia, Author at DMC, Inc.</title>
	<atom:link href="https://static.dmcinfo.com/blog/author/zacharyg/feed/index.xml" rel="self" type="application/rss+xml" />
	<link></link>
	<description></description>
	<lastBuildDate>Fri, 24 Jul 2026 20:25:51 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.2</generator>

<image>
	<url>https://static.dmcinfo.com/wp-content/uploads/2025/04/site-icon-150x150.png</url>
	<title>Zachary Gracia, Author at DMC, Inc.</title>
	<link></link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Using Dropdowns to Set Tag-Paths in Ignition</title>
		<link>https://static.dmcinfo.com/blog/20251/using-dropdowns-to-set-tag-paths-in-ignition/</link>
		
		<dc:creator><![CDATA[Zachary Gracia]]></dc:creator>
		<pubDate>Thu, 06 Feb 2020 15:21:56 +0000</pubDate>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[Ignition]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/20251/using-dropdowns-to-set-tag-paths-in-ignition/</guid>

					<description><![CDATA[<p>Ignition is a versatile SCADA platform from Inductive Automation that is quickly becoming one of the top choices for industrial automation solutions. Ignition can run on a variety of platforms and interfaces easily with many field IO devices using its built-in drivers. Ignition has many powerful and useful features that can be utilized for making [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/20251/using-dropdowns-to-set-tag-paths-in-ignition/">Using Dropdowns to Set Tag-Paths in Ignition</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">Ignition is a versatile <a href="https://static.dmcinfo.com/services/manufacturing-automation-and-intelligence/hmi-and-scada-programming/rockwell-factorytalk-programming/" target="_blank" rel="noreferrer noopener">SCADA </a>platform from <a href="https://inductiveautomation.com/">Inductive Automation</a> that is quickly becoming one of the top choices for industrial automation solutions. Ignition can run on a variety of platforms and interfaces easily with many field IO devices using its built-in drivers.</p>



<p class="wp-block-paragraph">Ignition has many powerful and useful features that can be utilized for making screens with dynamic animations and control. Some of these features are custom screen properties, parameterized templates, and expression building. This blog will explore how to create a screen that allows the user to navigate easily between configuration settings for similar devices.</p>



<p class="wp-block-paragraph"><strong>Using Dropdown Lists</strong></p>



<p class="wp-block-paragraph">One object that can be very useful and intuitive to implement is the dropdown list component. The dropdown list comes with a built-in, two-column dataset where one column displays a label and the other corresponds to a selected value.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Station-Selector-Dataset.png" alt=""/></figure>



<p class="wp-block-paragraph"><em>Figure 1: Station Selector Dataset</em></p>



<p class="wp-block-paragraph">This is useful because a more detailed description is displayed to the user while something as simple as an integer can be set to a parameter in the background. For example, in situations where the system has individual stations that use similar equipment, it is likely that the only thing differentiating these units from a software perspective would be the number assigned to that station. Since the value and label are independent from each other, the developer can use any label they want (such as a number or a relative position) to convey the station’s identity to the user.</p>



<p class="wp-block-paragraph"><strong>Modular Tag Structure</strong></p>



<figure class="wp-block-image size-full"><img fetchpriority="high" decoding="async" width="900" height="568" src="https://static.dmcinfo.com/wp-content/uploads/2020/02/image.png" alt="" class="wp-image-32686" srcset="https://static.dmcinfo.com/wp-content/uploads/2020/02/image.png 900w, https://static.dmcinfo.com/wp-content/uploads/2020/02/image-300x189.png 300w, https://static.dmcinfo.com/wp-content/uploads/2020/02/image-768x485.png 768w" sizes="(max-width: 900px) 100vw, 900px" /></figure>



<p class="wp-block-paragraph"><em>Figure 2: Example Tag Setup</em></p>



<p class="wp-block-paragraph">In the above tag structure, each station has many sub-devices with the same underlying tag structure. If each station has four devices, then each will have its own integer and double value with two devices sharing a float value. For example, <strong>Device 1</strong> would correspond to <strong>Int1</strong>,<strong> Double1</strong>, and <strong>SmallFloat</strong> (<strong>Devices 1</strong> and <strong>2</strong> share <strong>SmallFloat</strong>, while <strong>3 </strong>and <strong>4 </strong>share <strong>BigFloat</strong>).</p>



<p class="wp-block-paragraph"><strong>Device Configuration Example</strong></p>



<figure class="wp-block-image size-full"><img decoding="async" width="900" height="384" src="https://static.dmcinfo.com/wp-content/uploads/2020/02/image-1.png" alt="" class="wp-image-32687" srcset="https://static.dmcinfo.com/wp-content/uploads/2020/02/image-1.png 900w, https://static.dmcinfo.com/wp-content/uploads/2020/02/image-1-300x128.png 300w, https://static.dmcinfo.com/wp-content/uploads/2020/02/image-1-768x328.png 768w" sizes="(max-width: 900px) 100vw, 900px" /></figure>



<p class="wp-block-paragraph"><em>Figure 3: Calibration Screen Initial</em></p>



<p class="wp-block-paragraph">In this example, I set up a calibration screen with two dropdown lists. One of the dropdown lists is used to set the selected station (see <strong>figure 1 </strong>for the dataset configuration and<strong> figure 2 </strong>for the tag structure). The second dropdown list is used to select a device within that station. The <strong>Device Selector </strong>dataset can be set up in a very similar fashion to the <strong>Station Selector </strong>with the biggest difference being that it needs to have an extra column added to account for the <b>float </b>values&#8217; tag-paths.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Device-Sector-Dataset.png" alt=""/></figure>



<p class="wp-block-paragraph"><em>Figure 4: Device Sector Dataset</em></p>



<p class="wp-block-paragraph"><strong>Indirect Tag Mapping</strong></p>



<p class="wp-block-paragraph">After the dropdown lists were configured, I used indirect tag bindings to map the selected integers and double values to their respective IO fields.</p>



<figure class="wp-block-image size-full"><img decoding="async" width="900" height="47" src="https://static.dmcinfo.com/wp-content/uploads/2020/02/image-2.png" alt="" class="wp-image-32689" srcset="https://static.dmcinfo.com/wp-content/uploads/2020/02/image-2.png 900w, https://static.dmcinfo.com/wp-content/uploads/2020/02/image-2-300x16.png 300w, https://static.dmcinfo.com/wp-content/uploads/2020/02/image-2-768x40.png 768w" sizes="(max-width: 900px) 100vw, 900px" /></figure>



<figure class="wp-block-image size-full"><img decoding="async" width="900" height="496" src="https://static.dmcinfo.com/wp-content/uploads/2020/02/image-3.png" alt="" class="wp-image-32690" srcset="https://static.dmcinfo.com/wp-content/uploads/2020/02/image-3.png 900w, https://static.dmcinfo.com/wp-content/uploads/2020/02/image-3-300x165.png 300w, https://static.dmcinfo.com/wp-content/uploads/2020/02/image-3-768x423.png 768w" sizes="(max-width: 900px) 100vw, 900px" /></figure>



<p class="wp-block-paragraph"><em>Figure 5: Indirect Tag Mapping</em></p>



<p class="wp-block-paragraph">In this dynamic mapping, the tag-path is automatically set to the correct double by taking the selected value of the station and device selectors. An almost identical indirect tag expression can be used to set the integer field to the correct tag. The only difference between the two being that I replaced <strong>Double </strong>with <strong>Int</strong>.</p>



<p class="wp-block-paragraph"><strong>Accessing Custom Dataset Values</strong></p>



<p class="wp-block-paragraph">As unfortunate as it is, we cannot use indirect tagging to access the custom column that we added to the device selector. Fortunately, with a few extra steps, we can still use that value to point the float input/output field to the correct tag in our tag browser. The first step to achieving this is to create a string custom property on the screen that will hold the tag path for our float IO field. A screen’s custom properties can be accessed by right-clicking the screen and selecting the <strong>Custom Properties</strong> item under the <strong>Customizers </strong>menu.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/custom-properties-location.png" alt=""/></figure>



<p class="wp-block-paragraph"><em>Figure 6: Custom Properties Location</em></p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Custom-Property-Setup.png" alt=""/></figure>



<p class="wp-block-paragraph"><em>Figure 7: Custom Property Setup</em></p>



<p class="wp-block-paragraph">The next step is to create a property binding on that string parameter so that it accesses the <strong>FloatName </strong>column that has been configured on the <strong>Device Selector</strong> dropdown.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Expression-Setup.png" alt=""/></figure>



<p class="wp-block-paragraph"><em>Figure 8: Expression Setup</em></p>



<p class="wp-block-paragraph">Once that expression is set up, we can implement an indirect tag for the float IO field.</p>



<p class="wp-block-paragraph">Now, the screen will update its values to the correct tags as the user shifts between the different stations and devices. This dynamic tag pathing is just one example of how Ignition can be a flexible and powerful SCADA solution.</p>



<p class="wp-block-paragraph"><strong>Learn more about DMC&#8217;s <a href="https://static.dmcinfo.com/services/manufacturing-automation-and-intelligence/hmi-and-scada-programming/ignition-programming/" target="_blank" rel="noreferrer noopener">Ignition </a>capabilities.</strong></p>
<p>The post <a href="https://static.dmcinfo.com/blog/20251/using-dropdowns-to-set-tag-paths-in-ignition/">Using Dropdowns to Set Tag-Paths in Ignition</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>MQTT Ignition Communication with an Edge Gateway</title>
		<link>https://static.dmcinfo.com/blog/20331/mqtt-ignition-communication-with-an-edge-gateway/</link>
		
		<dc:creator><![CDATA[Zachary Gracia]]></dc:creator>
		<pubDate>Thu, 23 Jan 2020 15:00:37 +0000</pubDate>
				<category><![CDATA[Application Development]]></category>
		<category><![CDATA[Ignition]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/20331/mqtt-ignition-communication-with-an-edge-gateway/</guid>

					<description><![CDATA[<p>Supervisory control and data acquisition, or SCADA for short, is a widely used control system architecture that allows for operators to control industrial processes both locally and remotely. One SCADA platform DMC has significant experience with is Ignition. One of the major benefits to using Ignition is that it is very versatile regarding the types of [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/20331/mqtt-ignition-communication-with-an-edge-gateway/">MQTT Ignition Communication with an Edge Gateway</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">Supervisory control and data acquisition, or SCADA for short, is a widely used control system architecture that allows for operators to control industrial processes both locally and remotely. One <a href="/services/manufacturing-automation-and-intelligence/hmi-and-scada-programming">SCADA platform</a> DMC has significant experience with is <a href="https://static.dmcinfo.com/services/manufacturing-automation-and-intelligence/hmi-and-scada-programming/ignition-programming/">Ignition</a>. One of the major benefits to using Ignition is that it is very versatile regarding the types of devices it can connect to. Further, all of Ignition’s features are separated into individual modules and users only pay for the ones they need.</p>



<p class="wp-block-paragraph">In most applications, Ignition uses industrial Ethernet to connect and communicate to field devices. This may not be possible if the devices are isolated in a way that it makes it impossible to connect over a network. However, there are other methods to set-up communication between the main Ignition server and field devices which I will outline below.</p>



<p class="wp-block-paragraph"><strong>Message Queuing Telemetry Transport (MQTT)</strong></p>



<p class="wp-block-paragraph">One such method involves using the MQTT protocol. MQTT stands for Message Queuing Telemetry Transport and works by using a publish subscribe based messaging procedure. During this procedure, one device publishes a string to the topic as a second device takes that string and parses it into useful information. What is nice about Ignition’s implementation is that the string and tag parsing is done for us by Ignition’s MQTT modules. Therefore, once these modules have been set up through Ignition’s gateway, the rest of the implementation should be straightforward.</p>



<p class="wp-block-paragraph"><strong>Process</strong></p>



<p class="wp-block-paragraph">In a full implementation, the central gateway can communicate with any number of edge devices. For this demo, I am using a central gateway on my computer and an edge gateway on a raspberry pi. In addition to the standard Ignition modules, the MQTT distributor and the MQTT engine modules should be added to the central gateway. All edge gateways should have the MQTT transmission module added.</p>



<p class="wp-block-paragraph">Modules can be added to a gateway by going to the configure tab of the gateway, clicking the modules page on the system group, and selecting the desired mod1 file to upload. These files can be acquired from the<a href="https://inductiveautomation.com/downloads/third-party-modules/8.0.6"> inductive automation website</a>.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/MQTT_Ignition-1.png" alt=""/></figure>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/MQTT_IGNITION-2.png" alt=""/></figure>



<p class="wp-block-paragraph"><strong>Configuring MQTT Engine</strong></p>



<p class="wp-block-paragraph">Once the MQTT Engine module has been added to the desired gateway, it can be configured by clicking on the settings item of the MQTT engine group on the configure tab. This will bring up a page that has three separate tabs: general, servers, and namespaces. Located on the general settings page is an input field for the primary host ID. For this implementation I set this as TestMQTT, but it can be set to anything. This value will be used again when configuring the MQTT transmission module on the Ignition edge gateway.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/MQTT_Ignition-3.png" alt=""/></figure>



<p class="wp-block-paragraph">Next, under the miscellaneous section of the page, I unchecked the boxes labeled block node commands and block device commands. This will allow access for the main gateway to write to the tags that are being shared by the Edge gateway. After that I navigated to the servers tab. There should be a default server set up.&nbsp; This will be the server we use for our implementation.</p>



<p class="wp-block-paragraph">When you click the edit button, it will bring up the connection settings for this server. Under URL, type in the address and port of the MQTT distributer either in the form of tcp://mydomain.com:1883, for tcp connections, or ssl://mydomain.com:8883, for ssl connections (1883 and 8883 are the default ports for Ignition’s TCP and SSL connections). Since the MQTT distributor and MQTT engine are on the same gateway, you can use localhost as the domain. TCP is the default server type on the distributor, so I used that type of connection during this process.</p>



<p class="wp-block-paragraph">The last tab is the namespaces tab, which you can leave at the default values. If you want your engine to subscribe to topics published by third party devices, this is where you would configure those connections. The MQTT disturber can also be set up from the configure tab of the gateway’s home page, but the default values should work fine for this implementation.</p>



<p class="wp-block-paragraph"><strong>Setting up the MQTT Transmission Module</strong></p>



<p class="wp-block-paragraph">After the MQTT engine has been configured on the main Ignition gateway, it is time to set-up the MQTT transmission module on the Ignition edge gateway. As before, this is done through the MQTT modules settings page under the configuration tab. This settings page has 5 tabs: general, servers, sets, transmitters, and records. First, select the servers tab and set the URL to point towards the main Ignition gateway in the form of tcp://[ip address of gateway computer]:1883.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/MQTT_Ignition-4.png" alt=""/></figure>



<p class="wp-block-paragraph">Next, set the server to default. Under the sets tab, press the edit button for the default set and set the primary host id to the same host id used in the configuration for the MQTT Engine.</p>



<p class="wp-block-paragraph"><strong>Create Edge Tags</strong></p>



<p class="wp-block-paragraph">After the default set has been configured appropriately, it is time to create the edge tags. To do this, launch the designer from the Ignition edge gateway. In the designer’s tag browser, under all providers -&gt; edge, there will be a folder called Edge Nodes that will have been auto generated by the MQTT Transmission module. Create folders using this structure: Edge Nodes -&gt; Group folder -&gt; Edge Node Folder -&gt; Device Folder. For this implementation, I named these folders Group 1, Edge Node 1, and Device 1.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/MQTT_Ignition-5.png" alt=""/></figure>



<p class="wp-block-paragraph">In this device folder above, I added a few UDTs with memory tags to be mapped to the MQTT Engine on the main gateway. This folder can contain a variety of tag types, UDTs, and lower level folders as well. All of which would be mapped to the MQTT Engine on the main gateway.</p>



<p class="wp-block-paragraph"><strong>Verifying the Connection&nbsp;</strong></p>



<p class="wp-block-paragraph">Once this is completed, the transmitter is started by setting the refresh tag in the MQTT Transmission -&gt; Transmission Control folder to&nbsp;true.&nbsp;After this tag is set (it will automatically reset itself),&nbsp;the connection can be verified from the edge gateway by going to the server’s tab of the MQTT Transmission settings.&nbsp;If everything is working properly, connected&nbsp;in the tab&nbsp;servers tab&nbsp;should&nbsp;be&nbsp;“1 of 1”.&nbsp;If it doesn’t,&nbsp;check your port and firewall settings&nbsp;to&nbsp;verify&nbsp;it&nbsp;allows&nbsp;incoming data transmission.&nbsp;&nbsp;</p>



<p class="wp-block-paragraph">Once it has been confirmed that the transmitter is connected, the tags that were created in the device folder should be visible to the main&nbsp;Ignition gateway.&nbsp;This can be checked by opening&nbsp;a&nbsp;designer&nbsp;for the main gateway project.&nbsp;In the designer’s tag browser,&nbsp;navigate to the&nbsp;folder&nbsp;All Providers -&gt;&nbsp; MQTT Engine.&nbsp;The folder structure that was created in the edge project should be replicated here (as well as tags from other MQTT Transmission modules connected to this engine).</p>



<p class="wp-block-paragraph">Learn more about DMC’s <a href="https://static.dmcinfo.com/services/manufacturing-automation-and-intelligence/hmi-and-scada-programming/ignition-programming/">Ignition Expertise</a> and <a href="/contact">contact us</a> with any inquiries.</p>
<p>The post <a href="https://static.dmcinfo.com/blog/20331/mqtt-ignition-communication-with-an-edge-gateway/">MQTT Ignition Communication with an Edge Gateway</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>DMC&#8217;s Custom Bootloader</title>
		<link>https://static.dmcinfo.com/blog/21075/dmcs-custom-bootloader/</link>
		
		<dc:creator><![CDATA[Zachary Gracia]]></dc:creator>
		<pubDate>Thu, 22 Aug 2019 13:44:10 +0000</pubDate>
				<category><![CDATA[Circuit Design]]></category>
		<category><![CDATA[Embedded Development & Programming]]></category>
		<category><![CDATA[Embedded Systems]]></category>
		<category><![CDATA[Microcontroller Programming]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/21075/dmcs-custom-bootloader/</guid>

					<description><![CDATA[<p>For anyone who has worked on an embedded project, you can understand the hassle of loading code onto a microcontroller. To alleviate this issue and cut down on the extra time that comes from this process, DMC designed and built a custom boot loading tool. This boot loader communicates with MCUs using UART (Universal Asynchronous [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/21075/dmcs-custom-bootloader/">DMC&#8217;s Custom Bootloader</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p class="wp-block-paragraph">For anyone who has worked on an <a href="/services/embedded-development-and-embedded-programming">embedded project</a>, you can understand the hassle of loading code onto a microcontroller. To alleviate this issue and cut down on the extra time that comes from this process, DMC designed and built a custom boot loading tool. This boot loader communicates with MCUs using UART (Universal Asynchronous Receiver/Transmitter). UART communication uses physical circuitry to send and receive serial data between two devices.</p>

<figure class="wp-block-image"><img decoding="async" alt="dmc custom bootloader" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/dmc-custom-bootloader-edited.png"  /></figure>

<p class="wp-block-paragraph">The DMC boot loader has three important features that help improve its use. The first of which is it has an onboard micro USB port. This port allows for serial communication with a CPU via a USB to micro USB cord (like you would use to charge a phone).</p>

<p class="wp-block-paragraph">The second important feature of the boot loader is that it has onboard reset and boot buttons. This allows for the user to easily put their MCU into boot loading mode by resetting the MCU while pressing the bootloader button.</p>

<p class="wp-block-paragraph">The third feature of this board that is important is the five-pin connector. This connector is how the bootloader communicates with the target MCU.</p>

<p class="wp-block-paragraph">For most DMC embedded projects, there is a standard 5 pin header that is compatible with the boot loader&rsquo;s connector. Through this mounting, we can send and receive the serial data, as well as reset and put the board into boot loading mode. Even if a board doesn&rsquo;t have a compatible mount, you can manually connect the boot loader&rsquo;s TX, RX, boot, ground, and reset pins to the appropriate locations on the target board to achieve the same functionality.</p>

<p class="wp-block-paragraph">This tool is one example of many internal initiatives DMC has undertaken to be more efficient and profitable.</p>

<p class="wp-block-paragraph">Learn more about <a href="/services/embedded-development-and-embedded-programming">DMC&apos;s Embedded Development and Programming Solutions</a>. <a href="/contact">Contact us</a> for additional information.</p>
<p>The post <a href="https://static.dmcinfo.com/blog/21075/dmcs-custom-bootloader/">DMC&#8217;s Custom Bootloader</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Dynamically Specifying the Folder for Importing &#038; Exporting Siemens HMI Recipes</title>
		<link>https://static.dmcinfo.com/blog/21522/dynamically-specifying-the-folder-for-importing-exporting-siemens-hmi-recipes/</link>
		
		<dc:creator><![CDATA[Zachary Gracia]]></dc:creator>
		<pubDate>Mon, 20 May 2019 13:42:40 +0000</pubDate>
				<category><![CDATA[PLC]]></category>
		<category><![CDATA[How To]]></category>
		<category><![CDATA[Recipe Management]]></category>
		<category><![CDATA[Scripting]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/21522/dynamically-specifying-the-folder-for-importing-exporting-siemens-hmi-recipes/</guid>

					<description><![CDATA[<p>One way to implement tasks when using Siemens products is to utilize the built-in recipe functionality. For applications in which the same PLC/HMI code is used across multiple standalone projects, it can be useful to configure a recipe on one PLC and then transfer it to other devices. To effectively transfer recipes between the PLC [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/21522/dynamically-specifying-the-folder-for-importing-exporting-siemens-hmi-recipes/">Dynamically Specifying the Folder for Importing &#038; Exporting Siemens HMI Recipes</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">One way to implement tasks when using Siemens products is to utilize the built-in recipe functionality. For applications in which the same PLC/HMI code is used across multiple standalone projects, it can be useful to configure a recipe on one PLC and then transfer it to other devices. To effectively transfer recipes between the PLC and HMI, please refer to <a href="/latest-thinking/blog/id/9770/importing-csv-recipe-files-into-siemens-hmi-and-iteratively-downloading-multiple-data-records-from-hmi-into-plc">this blog</a> instead. This blog will cover dynamically setting the location of import files and export folders.</p>



<p class="wp-block-paragraph"><strong>It is important to note that this implementation will not work with basic panels!</strong></p>



<h2 id="h-exporting-and-importing-files" class="wp-block-heading">Exporting and Importing Files</h2>



<p class="wp-block-paragraph">Siemens HMI’s have built-in functions for importing and exporting files that are relatively easy to implement. Both functions are triggered by events that are named<strong> ExportDataRecords</strong> and <strong>ImportDataRecords, </strong>which are built-in Siemens functions.&nbsp;The events can trigger on a large variety of actions, but for this example, I had them trigger on HMI button presses.&nbsp;</p>



<p class="wp-block-paragraph">These events can be set by going to a component&#8217;s properties and clicking on the events tab (shown below).&nbsp;</p>



<p class="wp-block-paragraph"><img decoding="async" alt="recipe components" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Recipes-4-R.png"><br>
<em><span style="font-size:12px">Component Properties on the HMI interface</span></em></p>



<p class="wp-block-paragraph"><img decoding="async" alt="Figure 1" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Recipes-1-R.png"><br>
<em><span style="font-size:12px">Sample Configuration for ExportDataRecords</span></em></p>



<p class="wp-block-paragraph"><img decoding="async" alt="Figure 2" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Recipes-2-R.png"><br>
<em><span style="font-size:12px">Sample Configuration for ImportDataRecords</span></em></p>



<p class="wp-block-paragraph">For both importing and exporting data records, the input that specifies the desired pathing is the <strong>filename</strong> input. This parameter is the system path to the file in the form of a string. The string containing the <strong>import</strong> variable, and the string containing the <strong>export</strong> variable can be set using the same built-in HMI event function called <strong>OpenFileBrowser</strong>. Note that for this implementation, the export path and the import will need to be held in separate variables.</p>



<p class="wp-block-paragraph"><img decoding="async" alt="Figure 3" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Recipes-3-R.png"><br>
<em><span style="font-size:12px">Sample Configuration for OpenFileBrowser</span></em></p>



<p class="wp-block-paragraph">This event lets the user navigate to a desired folder/file and save the computer pathing of that file to the tag passed into the Path input. In this application, a specific file is used for importing recipes, and a folder is specified for exporting recipes. To do this, toggle the file input of the open file browser event.</p>



<p class="wp-block-paragraph">When this parameter is set to true, the file browser will return a path to a file, when it is false it will return the path to a folder. When this field is set to true, you can also mask the browser to only show specific file extensions such as .csv or .ap by using the mask field. This can be useful for ignoring irrelevant files.</p>



<p class="wp-block-paragraph">The event that exports recipes needs a file pathing to export, and since our file browsing event is grabbing a folder pathing, some basic scripting is needed to create an export file path we can use. The script below concatenates the folder pathing we got from the file browser with a name tag I created for the current recipe. This script should be triggered on the value change of either the folder path or the recipe name.</p>



<div class="wp-block-kevinbatdorf-code-block-pro cbp-has-line-numbers" data-code-block-pro-font-family="Code-Pro-JetBrains-Mono" style="font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;--cbp-line-number-color:#D4D4D4;--cbp-line-number-width:calc(1 * 0.6 * .875rem);line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)"><span style="display:flex;align-items:center;padding:16px 0 0 16px;width:100%;text-align:left;background-color:#1e1e1e"><span style="background:#c7c7c7;padding:0.3rem 0.5rem 0.2rem;border-radius:1rem;font-size:0.8em;line-height:1;height:1.25rem;text-align:center;display:inline-flex;align-items:center;justify-content:center;color:#1e1e1e">VB</span></span><span role="button" tabindex="0" style="color:#D4D4D4;display:none" aria-label="Copy" class="code-block-pro-copy-button"><pre class="code-block-pro-copy-button-pre" aria-hidden="true"><textarea class="code-block-pro-copy-button-textarea" tabindex="-1" aria-hidden="true" readonly>Sub ExportPathing()

    HmiRuntime.SmartTags("sExportPath") = _
        HmiRuntime.SmartTags("sExportPathFolder") &amp; _
        HmiRuntime.SmartTags("dbRecipes_udtCurrentRecipe_sRecipeName") &amp; _
        ".csv"

End Sub</textarea></pre><svg xmlns="http://www.w3.org/2000/svg" style="width:24px;height:24px" fill="none" viewBox="0 0 24 24" stroke="currentColor" stroke-width="2"><path class="with-check" stroke-linecap="round" stroke-linejoin="round" d="M4.5 12.75l6 6 9-13.5"></path><path class="without-check" stroke-linecap="round" stroke-linejoin="round" d="M16.5 8.25V6a2.25 2.25 0 00-2.25-2.25H6A2.25 2.25 0 003.75 6v8.25A2.25 2.25 0 006 16.5h2.25m8.25-8.25H18a2.25 2.25 0 012.25 2.25V18A2.25 2.25 0 0118 20.25h-7.5A2.25 2.25 0 018.25 18v-1.5m8.25-8.25h-6a2.25 2.25 0 00-2.25 2.25v6"></path></svg></span><pre class="shiki dark-plus" style="background-color: #1E1E1E" tabindex="0"><code><span class="line"><span style="color: #569CD6">Sub</span><span style="color: #D4D4D4"> </span><span style="color: #DCDCAA">ExportPathing</span><span style="color: #D4D4D4">()</span></span>
<span class="line"></span>
<span class="line"><span style="color: #D4D4D4">    HmiRuntime.</span><span style="color: #DCDCAA">SmartTags</span><span style="color: #D4D4D4">(</span><span style="color: #CE9178">&quot;sExportPath&quot;</span><span style="color: #D4D4D4">) =</span><span style="color: #9CDCFE"> _</span></span>
<span class="line"><span style="color: #D4D4D4">        HmiRuntime.</span><span style="color: #DCDCAA">SmartTags</span><span style="color: #D4D4D4">(</span><span style="color: #CE9178">&quot;sExportPathFolder&quot;</span><span style="color: #D4D4D4">) &amp;</span><span style="color: #9CDCFE"> _</span></span>
<span class="line"><span style="color: #D4D4D4">        HmiRuntime.</span><span style="color: #DCDCAA">SmartTags</span><span style="color: #D4D4D4">(</span><span style="color: #CE9178">&quot;dbRecipes_udtCurrentRecipe_sRecipeName&quot;</span><span style="color: #D4D4D4">) &amp;</span><span style="color: #9CDCFE"> _</span></span>
<span class="line"><span style="color: #D4D4D4">        </span><span style="color: #CE9178">&quot;.csv&quot;</span></span>
<span class="line"></span>
<span class="line"><span style="color: #569CD6">End Sub</span></span></code></pre></div>



<p class="wp-block-paragraph">Once the correct path is specified for importing and exporting, the import and export event are ready to be triggered. By using the tips outlined for importing and exporting recipes, you should be able to specify computer locations for importing and exporting recipes easily. I hope this will help in your future endeavors.</p>



<p class="wp-block-paragraph">Learn more about DMC&#8217;s <a href="/services/manufacturing-automation-and-intelligence/hmi-and-scada-programming">HMI and SCADA Expertise</a> and our partnership with <a href="/about/partners/siemens-solution-partner">Siemens</a>.</p>



<p class="wp-block-paragraph"></p>
<p>The post <a href="https://static.dmcinfo.com/blog/21522/dynamically-specifying-the-folder-for-importing-exporting-siemens-hmi-recipes/">Dynamically Specifying the Folder for Importing &#038; Exporting Siemens HMI Recipes</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
		<item>
		<title>Using a High-Speed Counter’s Hardware Interrupt to Peripherally Write to an Output on a Siemens 1200 PLC</title>
		<link>https://static.dmcinfo.com/blog/21967/using-a-high-speed-counters-hardware-interrupt-to-peripherally-write-to-an-output-on-a-siemens-1200-plc/</link>
		
		<dc:creator><![CDATA[Zachary Gracia]]></dc:creator>
		<pubDate>Tue, 26 Feb 2019 10:47:57 +0000</pubDate>
				<category><![CDATA[Manufacturing Automation & Intelligence]]></category>
		<category><![CDATA[PLC]]></category>
		<category><![CDATA[Siemens PLC]]></category>
		<guid isPermaLink="false">https://static.dmcinfo.com/blog/21967/using-a-high-speed-counters-hardware-interrupt-to-peripherally-write-to-an-output-on-a-siemens-1200-plc/</guid>

					<description><![CDATA[<p>The built-in high-speed counters on Siemens PLCs are very useful for applications in which a machine needs to move material a specified distance. In these instances, the scan time of the program can add inconsistency to this distance. Reduce this inconsistency by using a built-in hardware interrupt associated with high-speed counters. Reduce the variance due [&#8230;]</p>
<p>The post <a href="https://static.dmcinfo.com/blog/21967/using-a-high-speed-counters-hardware-interrupt-to-peripherally-write-to-an-output-on-a-siemens-1200-plc/">Using a High-Speed Counter’s Hardware Interrupt to Peripherally Write to an Output on a Siemens 1200 PLC</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<p class="wp-block-paragraph">The built-in high-speed counters on Siemens PLCs are very useful for applications in which a machine needs to move material a specified distance. In these instances, the scan time of the program can add inconsistency to this distance.</p>



<p class="wp-block-paragraph">Reduce this inconsistency by using a built-in hardware interrupt associated with high-speed counters. Reduce the variance due to a program&#8217;s scan time by passing a reference point to the high-speed counter&nbsp;and peripherally writing to the desired output bit.</p>



<p class="wp-block-paragraph"><strong>This tutorial demonstrates how to set up a high-speed counter interrupt, peripherally write to the desired output, and set its reference point in the PLC.</strong></p>



<h2 id="h-setting-up-the-high-speed-counter-interrupt" class="wp-block-heading">Setting up the High-Speed Counter Interrupt</h2>



<ol class="wp-block-list">
<li>To set up a reference interrupt for a high-speed counter, go to the <strong>device configuration</strong> of the PLC. From there, navigate to the high-speed counters tab and select the desired counter.<br>
 <br>
 <br>
 &nbsp;
<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Setting-up-the-High-Speed-Counter-Interrupt-Step-1-Clean.png" alt="Navigate to the high-speed counters tab and select the desired counter."/></figure>
</li>



<li>From here, select <strong>event configuration </strong>and check the box for <strong>Generate interrupt for counter value equals reference value event</strong>. Checking this box will autogenerate&nbsp;an event name and priority.<br>
 <br>
 <br>
 &nbsp;
<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Setting-up-the-High-Speed-Counter-Interrupt-Step-2-Clean.png" alt="2.	From here select event configuration and check the box for “Generate interrupt for counter value equals reference value event.”"/></figure>
</li>



<li>To specify the OB that this interrupt will call, press the button that contains the <strong>…</strong>&nbsp;on the far right of the configuration window. Pressing this button will open a dropdown that allows the programmer to either select a preprogrammed interrupt or to&nbsp;create a new one specifically for this event by using the add new button located on the bottom right of the drop-down.<br>
 <br>
 
<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Setting-up-the-High-Speed-Counter-Interrupt-Step-3-Clean.png" alt="Use the add new button located on the bottom right of the dropdown."/></figure>
</li>
</ol>



<h2 id="h-peripherally-writing-to-an-output-in-the-interrupt" class="wp-block-heading">Peripherally Writing to an Output in the Interrupt</h2>



<p class="wp-block-paragraph">The code used in the interrupt is not all that complicated in this specific instance, but there are a few things that you should keep in mind when implementing it.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Peripherally-Writing-to-an-output-in-the-Interrupt-1.png" alt=""/></figure>



<p class="wp-block-paragraph">The main functionality is in <strong>network one</strong>, and all it does is write the output bit low if it is already high. The important thing to note with this section of code is <strong>how </strong>the bit is written low. To peripherally write to that output, the tag needs to be followed by <strong><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f61b.png" alt="😛" class="wp-smiley" style="height: 1em; max-height: 1em;" /></strong>.</p>



<p class="wp-block-paragraph">Following the tag with <strong><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f61b.png" alt="😛" class="wp-smiley" style="height: 1em; max-height: 1em;" /></strong> will immediately write the output bit low instead of waiting until the creation of the <strong>process image</strong>. This is how the variability due to the scan time is eliminated. The output is immediately written low when the condition is met, instead of waiting the variable amount of time from when the condition is met in the program, and the scan reaches the point in which it writes to the outputs.</p>



<p class="wp-block-paragraph">The second thing to note in this interrupt is contained within the <strong>second network</strong>. Note that in this network, a global bit is set high. The reason that this is necessary is that depending on when this interrupt is triggered, logic in the main code may overwrite the peripheral write.</p>



<p class="wp-block-paragraph">To avoid this, the output is buffered by this global bit. Whenever the output would be written, it is preceded by a normally closed gate tied to this global variable. This ensures that if this interrupt is triggered, there is no way the output can be written high unless the status bit is written low again.</p>



<p class="wp-block-paragraph">One last important thing to note is that this status bit is only written high during this interrupt. The main program writes it low again when it has been high for a quarter of a second.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Peripherally-Writing-to-an-output-in-the-Interrupt-2.png" alt=""/></figure>



<p class="wp-block-paragraph">This is more time than is needed but it ensures that the main logic reaches the point where it would have written this output low by itself.&nbsp;</p>



<h2 id="h-setting-the-reference-point-for-the-high-speed-counter" class="wp-block-heading">Setting the Reference Point for the High-Speed Counter</h2>



<p class="wp-block-paragraph">Now that the interrupt has been configured, the reference point for the interrupt must be set in the main program. This is done by using the <strong>CTRL_HSC function block</strong>.</p>



<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Setting-the-Reference-Point-for-the-High-Speed-Counter-1.png" alt=""/></figure>



<p class="wp-block-paragraph">For this implementation, there are three crucial inputs.</p>



<ol class="wp-block-list">
<li>The first is the HSC input. Pass the hardware ID to this input to&nbsp;connect this block to the desired counter. The IDs for the high-speed counters can be found in <strong>PLC Tags &gt; System Constants</strong>.<br>
 &nbsp;</li>



<li>The next input of importance is the <strong>NEW_RV</strong> input. This is the value the counter will use as a reference to trigger the interrupt. It is important to note that this input is a <strong>Dint data type</strong>, so some conversions may be necessary. In this situation, the stop position was being tracked in mm as a real. To convert it the desired position it was first divided by a pre-calculated mm per count, and the result of that was converted into a Dint. This Dint value can then be passed to the NEW_RV input of the CTRL_HSC block.<br>
 <br>
 <br>
 &nbsp;
<figure class="wp-block-image"><img decoding="async" src="https://static.dmcinfo.com/wp-content/uploads/2025/05/Setting-the-Reference-Point-for-the-High-Speed-Counter-Step-2.png" alt=""/></figure>
</li>



<li>The last input of importance for this application is the <strong>RV input</strong>. This is a Boolean input that sets the counter’s reference value whenever it is set to high. The program can constantly be updating the reference value passed to this block, but that value will only be set if this RV input is high.</li>
</ol>



<h2 id="h-conclusion" class="wp-block-heading">Conclusion</h2>



<p class="wp-block-paragraph">This tutorial is not an overly complicated example of how to use a high-speed counter’s reference interrupt, but it shows some key details and methods needed to write to PLC outputs peripherally. I hope that the information presented here will be helpful in your future endeavors.</p>



<p class="wp-block-paragraph"><strong>Learn more about DMC&#8217;s&nbsp;<a href="https://static.dmcinfo.com/services/manufacturing-automation-and-intelligence/plc-programming/siemens-s7-plc-programming">Siemens S7 PLC Programming services</a>. Or,&nbsp;<a href="https://static.dmcinfo.com/contact">contact us</a>&nbsp;to get started on a project today.</strong></p>



<p class="wp-block-paragraph"></p>
<p>The post <a href="https://static.dmcinfo.com/blog/21967/using-a-high-speed-counters-hardware-interrupt-to-peripherally-write-to-an-output-on-a-siemens-1200-plc/">Using a High-Speed Counter’s Hardware Interrupt to Peripherally Write to an Output on a Siemens 1200 PLC</a> appeared first on <a href="https://static.dmcinfo.com/">DMC, Inc.</a>.</p>
]]></content:encoded>
					
		
		
			</item>
	</channel>
</rss>
