<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Hugo Vaz on Medium]]></title>
        <description><![CDATA[Stories by Hugo Vaz on Medium]]></description>
        <link>https://medium.com/@hugo.vaz7881?source=rss-4a1410ba423b------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*SdpIYyTllh9dpcbjVc3YwQ.png</url>
            <title>Stories by Hugo Vaz on Medium</title>
            <link>https://medium.com/@hugo.vaz7881?source=rss-4a1410ba423b------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 24 Nov 2026 16:55:44 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@hugo.vaz7881/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Week 49 Develop with the Community: “Early Elf December”]]></title>
            <link>https://medium.com/coreflux-blog/week-49-develop-with-the-community-early-elf-december-4bdce25b4a6d?source=rss-4a1410ba423b------2</link>
            <guid isPermaLink="false">https://medium.com/p/4bdce25b4a6d</guid>
            <category><![CDATA[iot]]></category>
            <category><![CDATA[flux]]></category>
            <category><![CDATA[coreflux]]></category>
            <category><![CDATA[mqtt]]></category>
            <dc:creator><![CDATA[Hugo Vaz]]></dc:creator>
            <pubDate>Tue, 19 Dec 2023 00:48:38 GMT</pubDate>
            <atom:updated>2023-12-19T12:21:52.934Z</atom:updated>
            <content:encoded><![CDATA[<p>As we step into the festive season, Coreflux is excited to present our “Early Elf December” update. This edition is not just about spreading holiday cheer 🎅; it’s a celebration of a significant leap in our journey — the launch of our very own Cloud MQTT broker. This move into the cloud is a game-changer, promising to revolutionize connectivity and innovation in the IoT space.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JqIblUNkDzjhQJKLVF-wAw.png" /></figure><h4>The Coreflux Cloud MQTT Broker: A Gateway to the Cloud</h4><p>The launch of our <a href="http://mqtt.coreflux.org/">Cloud MQTT broker</a> at mqtt.coreflux.org marks a pivotal moment for Coreflux. It’s not just a new product; it’s the beginning of our journey into cloud-based solutions, expanding our capabilities in the IoT space. This broker is more than a connectivity tool; it’s a data hub, centralizing and managing vast amounts of data from various sources.</p><p>Our broker is designed with high performance in mind, ensuring efficient real-time data management and communication, even during peak loads. We understand the diverse needs of our users, from startups to large enterprises, and have built our broker to scale effortlessly, ensuring the smooth operation of your IoT network.</p><p>Security is paramount in the IoT world, and we’ve integrated top-tier encryption and authentication to protect your IoT ecosystem. The user-friendly interface of our broker makes managing IoT devices and data a breeze, suitable for users of all technical levels.</p><p>Moreover, the concept of our broker as a data hub is crucial. In the age of digital transformation, data has become the lifeblood of businesses. Our Data Hub is not just a storage or message queue solution; it’s a building block of your platform that enables you to integrate and enrich data, making it ready for consumption by different applications, analytics tools, or machine learning models. Learn more about our <a href="https://docs.coreflux.org/data-hub/">Data Hub</a>.</p><h4>Flux Language Development and Future Prospects</h4><p>In our continuous pursuit of innovation, Coreflux is excited to share the development of the Flux Language, a pivotal element in our IoT ecosystem. Our Flux Language, currently in its alpha stage, is designed to be a game-changer in how we handle IoT data and operations. It’s a testament to our commitment to providing flexible, scalable, and resilient solutions.</p><p>Flux Language is akin to a microservice in a microservices architecture, where each asset is singular in purpose, independently deployable, stateless, and communicates over the network. This design ensures that the Coreflux platform remains adaptable and robust, catering to a wide range of functionalities and use cases. For more details on <a href="https://docs.coreflux.org/flux-lang/">Flux Language</a>, visit our documentation.</p><p>Looking ahead, we are considering a significant changeover in our broker architecture. The idea is now to adopt WebAssembly for running the Language. This shift would enable pure performance integration both in cloud and edge environments, marking a significant leap in our technological capabilities. WebAssembly offers the promise of high performance and portability, making it an ideal choice for our next-generation MQTT broker.</p><p>Discussions are currently underway, and we are excited about the possibilities this change could bring. This move aligns with our vision to continuously evolve and enhance our offerings, ensuring that Coreflux remains at the forefront of IoT innovation. Stay tuned for more updates as we embark on this exciting journey towards a more efficient and powerful IoT ecosystem.</p><h3>Post Script</h3><p>As we celebrate this significant milestone and the festive season, we extend our warmest wishes to all our customers and partners. Your support has been instrumental in reaching this point. May your holidays be filled with joy, and may the new year bring you innovation and success.</p><p>From the Coreflux team, we wish you a wonderful Christmas.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4bdce25b4a6d" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coreflux-blog/week-49-develop-with-the-community-early-elf-december-4bdce25b4a6d">Week 49 Develop with the Community: “Early Elf December”</a> was originally published in <a href="https://medium.com/coreflux-blog">Coreflux Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Coreflux Week 47: “The Novelties November” Update]]></title>
            <link>https://medium.com/coreflux-blog/coreflux-week-47-the-novelties-november-update-8491ce3893bd?source=rss-4a1410ba423b------2</link>
            <guid isPermaLink="false">https://medium.com/p/8491ce3893bd</guid>
            <category><![CDATA[flux-assets]]></category>
            <category><![CDATA[coreflux]]></category>
            <category><![CDATA[iot]]></category>
            <category><![CDATA[mqtt]]></category>
            <dc:creator><![CDATA[Hugo Vaz]]></dc:creator>
            <pubDate>Sun, 26 Nov 2023 23:29:53 GMT</pubDate>
            <atom:updated>2023-11-28T18:34:45.880Z</atom:updated>
            <content:encoded><![CDATA[<p>As part of our ongoing commitment to building with the community, we’re excited to bring you the latest Coreflux update. This edition, themed “The Novelties November,” highlights the fresh and novel changes we’ve implemented as we approach the end of November. Our focus has been on tangible improvements across our products and infrastructure, driven by your feedback and our shared journey towards excellence.</p><h3>Introducing the MariaDB Connector to MQTT in Coreflux Central</h3><p>We’ve expanded Coreflux Central’s capabilities by adding a new flux asset — the MariaDB connector to MQTT. This new feature is a direct response to our users’ needs, aiming to enhance the versatility and functionality of our platform. It is a new asset capable of providing connectivity to MariaDB and MQTT, similar to our SQL asset. You should try it out since <a href="https://mariadb.org/">MariaDB </a>is an open-source SQL database.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QZO4FaVj39DJYaOJTqfSbw.jpeg" /></figure><h3>Enhancements in Coreflux Central</h3><p>Our team has been diligently working on the backend of Coreflux Central, focusing on optimizing system operations and file management. These enhancements are crucial for ensuring a smoother and more efficient user experience, even if they might not be immediately visible.</p><h3>Significant Improvements in Coreflux Hub: Version 1.2.005</h3><p>We’re proud to announce the release of Coreflux Hub version 1.2.005. This update is particularly significant for users who have experienced challenges with tag management.</p><h3>What’s New in Version 1.2.005:</h3><ul><li><strong>Enhanced Tag Management: </strong>We’ve introduced a more intuitive and efficient way to copy and duplicate address tags, significantly reducing the time and effort involved in managing tags. This was a request based on the community</li><li><strong>Edit Address Tags: </strong>This new functionality allows for greater flexibility and precision in managing your data.</li><li>Progress Bar in Downloads Page: Providing immediate, visual feedback on the status of your downloads, making the process more transparent and less stressful.</li><li>Button to remove previous history connection. Check the <a href="https://github.com/CorefluxCommunity/Coreflux-roadmap/issues/11">feature request</a>!</li></ul><p><strong>We strongly encourage users who have faced challenges with tag management to download and install this latest version. </strong>It’s a direct response to your needs, and we’re confident that these improvements will enhance your Coreflux Hub experience.</p><h3>Our Cloud Program’s Infrastructure Challenge</h3><p>A highlight of our recent work has been the cloud program’s infrastructure challenge. One team member, conducted performance testing on the Coreflux Broker, achieving impressive results. The Broker efficiently handled a high volume of MQTT messages, with our testing host publishing over 816k messages per second. These tests, conducted across different cloud providers, ensure that our systems are robust and reliable.</p><h3>Post Script</h3><p>From personal experience, I understand the importance of a smooth and efficient tag management system. It’s more than a feature; it’s a fundamental part of our workflow that impacts productivity and satisfaction.</p><p>We look forward to continuing this journey with you and will be back with more updates in two weeks. Thank you for being an integral part of our community and for your trust in Coreflux.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8491ce3893bd" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coreflux-blog/coreflux-week-47-the-novelties-november-update-8491ce3893bd">Coreflux Week 47: “The Novelties November” Update</a> was originally published in <a href="https://medium.com/coreflux-blog">Coreflux Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Coreflux C# Digital Worker Asset]]></title>
            <link>https://medium.com/coreflux-blog/coreflux-c-digital-worker-asset-69318a9ade4?source=rss-4a1410ba423b------2</link>
            <guid isPermaLink="false">https://medium.com/p/69318a9ade4</guid>
            <category><![CDATA[data-science]]></category>
            <category><![CDATA[iot]]></category>
            <category><![CDATA[c-sharp-programming]]></category>
            <category><![CDATA[mqtt]]></category>
            <category><![CDATA[coreflux]]></category>
            <dc:creator><![CDATA[Hugo Vaz]]></dc:creator>
            <pubDate>Sun, 05 Mar 2023 23:42:42 GMT</pubDate>
            <atom:updated>2023-03-07T13:23:53.942Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kcSx1dfKgAQc9fNqEY9Crw.png" /><figcaption>Inside the Asset 😅</figcaption></figure><p>The Digital Worker Asset is a powerful tool designed to help developers run C# code with the ability to connect to MQTT topics in a data hub made with Coreflux. It provides an easy way to create and deploy custom code that can interact with data from IoT devices, sensors, and other sources in real time.</p><p>The Digital Worker Asset C# is handy for industrial automation, smart energy and other applications that require real-time data processing, as it allows developers to quickly write and execute code that can react to changes in data and trigger actions accordingly. This can be used to implement advanced monitoring, control, and automation functions that can help optimize operations and reduce costs.</p><p>Some of the key features of the Digital Worker Asset include:</p><ul><li>Support for C# code execution</li><li>Ability to connect to MQTT topics in Coreflux and outside Coreflux</li><li>Feedback on executions</li><li>Easy scalable deployment</li><li>MQTT Compatibility can run in other infrastructures already</li></ul><p>The Digital Worker Asset is an essential tool for developers looking to create powerful, scalable and efficient IoT solutions using Coreflux. It allows them to quickly write and execute custom code that can interact with data from IoT devices, sensors, and other sources in real-time, helping them to build advanced monitoring, control, and automation functions that can improve operations and reduce costs by creating a Hybrid System.</p><h3>The Hybrid System Approach</h3><p>One of the main advantages of a Hybrid System is the ability to leverage the benefits of both on-premises and cloud resources. On-premises resources are typically closer to the edge devices, which can help to reduce latency and ensure more reliable communication. Meanwhile, cloud resources provide scalability, flexibility, and cost efficiency. By combining the two, developers can create a powerful and efficient system that can handle real-time data processing, storage, and analysis.</p><p>A Hybrid System can also help to address the security and compliance concerns that often arise with IoT solutions. By storing sensitive data on-premises and using cloud resources for non-sensitive tasks, developers can create a more secure and compliant system that meets the needs of their organization.</p><p>Additionally, <strong>an Hybrid System can reduce costs by optimizing resource usage</strong>. On-premises resources can be used for critical tasks that require low latency, while cloud resources can be used for less critical functions that can be offloaded to the cloud for cost savings.</p><p>Overall, an Hybrid System can provide a range of benefits for IoT solutions, including improved performance, security, compliance, and cost efficiency. By leveraging the power of both on-premises and cloud resources, developers can create a system that meets the unique needs of their organization and delivers real business value.</p><h4>Example</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VcREZYVPv8Fu0BuKyHVXOg.png" /></figure><p><strong>This is a typical integration of Coreflux that can help save up to 87%</strong> of <strong>subscription fees</strong> in many cases, depending on the cloud provider, architecture, and data ratio. In this scenario, the OT MQTT brokers are close to the edge devices, providing real-time data at milliseconds and second intervals. The IT MQTT broker contextualizes and aggregates the data into higher-level information, which is then sent to the cloud for analysis. By combining the power of on-premises and cloud resources, you can create a system that meets your organization’s unique needs while minimizing costs.</p><p>Overall, this example highlights the benefits of a Hybrid System for industrial IoT solutions, including improved performance, reduced costs, and optimized resource usage. By leveraging the power of both on-premises and cloud resources, you can create a system that delivers real business value while meeting your organization’s unique needs.</p><h3>C# — The Natural Language of this Digital Worker</h3><p>C# (pronounced “see-sharp”) is a modern, object-oriented programming language developed by Microsoft. It was introduced in 2000 and is used to build a wide range of applications for Windows, web, and mobile platforms. C# is a popular choice for developing enterprise applications due to its ease of use, robustness, and scalability.</p><p>To give you a sense of what C# code looks like, here’s an example of a simple console application that counts numbers:</p><pre>using System;<br>class Program<br>{<br>    static void Main(string[] args)<br>    {<br>        for (int i = 0; i &lt; 10; i++)<br>        {<br>            Console.WriteLine(i);<br>        }<br>    }<br>}</pre><p>In this code, we first import the System namespace, which contains a set of useful classes and functions that we can use in our program. Then, we define a class called Program, which contains a static method called Main. The Main method is the entry point of our program, which gets executed first when we run the program.</p><p>Inside the Main method, we use a for loop to count from 0 to 9, and for each number, we print it to the console using the Console.WriteLine method. Finally, we exit the program.</p><p>This is just a simple example to give you a taste of C# syntax. In practice, C# can be used to build much more complex applications.</p><h3>So how to make a Code for a C# Digital Worker Asset</h3><p>To prepare the code for the Digital Worker C# asset using Visual Studio Code, you’ll need to follow these steps:</p><p>Install Visual Studio Code: If you haven’t already, download and install Visual Studio Code, which is a lightweight, cross-platform code editor that supports a wide range of programming languages, including C#.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/296/1*3xs7vM1T9sysKpU3fu8JMQ.png" /></figure><p>Create a new C# project: Open Visual Studio Code and create a new C# project by selecting “File” -&gt; “New File” -&gt; “C#” from the menu. Choose a name and location for your project and click “Create”.</p><p>Write your code: Open the program.cs file in your project and write your C# code.</p><p>To get a better perspective we will use an example. We want to have a counter of parts in a production process of a machine. The program will run continuously and check the status of two tags, “MachineOn” and “ProductionOn”. If both tags are set to “true”, the program will increment a counter of parts and write the new count to the “Count” tag. If the “ProductionOn” tag is set to “false”, the program will reset the ProductionLast boolean to false. The program will also pause for one second before checking the tags again.</p><p>The Concept:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QdHBztk9IBq8tMADTuKd5g.png" /><figcaption>How To Count Parts with a PLC Signal</figcaption></figure><p>The Editor with the code :</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rUKXo4eZfl2KLx5CG789WQ.png" /><figcaption>Using Visual Studio CGA Style 👴</figcaption></figure><p>The Code:</p><pre>using System;<br>using Coreflux.DigitalWorker;<br>using System.Threading;<br>namespace EdgeCountingPartss<br>{<br>    class Program<br>    {<br>        static void Main(string[] args)<br>        {<br>            int i = 0;<br>            bool ProductionLast=false;<br>            <br>            while (true)<br>            {<br>                if(TagHolder.Read(&quot;MachineOn&quot;).Equals(&quot;true&quot;) &amp;&amp; TagHolder.Read(&quot;ProductionOn&quot;).Equals(&quot;true&quot;))<br>                {<br>                    if(ProductionLast==false)<br>                    {<br>                        i++;<br>                        Console.WriteLine(i.ToString());<br>                        TagHolder.Write(&quot;Count&quot;,i.ToString());<br>                        Thread.Sleep(1000);<br>                        ProductionLast=true;<br>                    }<br>                    else<br>                    {<br>                        //do nothing<br>                    }<br>                }<br>                if(TagHolder.Read(&quot;ProductionOn&quot;).Equals(&quot;false&quot;))<br>                {<br>                    ProductionLast=false;<br>                }<br>            }<br>        }<br>    }<br>}</pre><p>So we have the code, let’s configure our asset.</p><h3>Configuration of the asset using Commands</h3><p>Check the asset list topic to obtain the GUID of the Digital Worker Asset you wish to configure. Topic -&gt; $SYS/Coreflux/Assets</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/875/0*_0wKeQatCPXSyvce.png" /><figcaption>The Topic $SYS/Coreflux/Assets</figcaption></figure><p>Use a text editor to create a JSON configuration for the Digital Worker asset, or modify an existing configuration file as needed. The JSON configuration should include values for the parameters you wish to set, such as the mqttPort, mqttAddress, and CycleTime. Use the AssetHelp Command to get a standard config.</p><p>Use the assetConfigSave command to save the JSON configuration to the Digital Worker asset. The topic to provide the config is <strong>$SYS/Coreflux/Cloud/Command</strong>.</p><p>The syntax for the command is as follows:</p><pre>-assetConfigSave &lt;guid&gt; &lt;configuration&gt;</pre><p>Replace <em>&lt;guid&gt;</em> with the GUID of the Digital Worker Asset, and <em>&lt;configuration&gt;</em> with the contents of your JSON configuration file.</p><p>For example, if your Digital Worker asset has a GUID of 12345678–9abc-def0–1234–56789abcdef0 and your JSON configuration file is named DigitalWorkerConfig.json, you would copy the contents of the file and use the following command:</p><pre>assetConfigSave 12345678–9abc-def0–1234–56789abcdef0 {<br>  &quot;MqttClient&quot;: {<br>    &quot;mqttPort&quot;: 1883,<br>    &quot;mqttAddress&quot;: &quot;127.0.0.1&quot;,<br>    &quot;isAnonymous&quot;: true,<br>    &quot;username&quot;: &quot;root&quot;,<br>    &quot;password&quot;: &quot;coreflux&quot;,<br>    &quot;withTLS&quot;: false,<br>    &quot;DebugTopicEnabled&quot;: false,<br>    &quot;DebugTopic&quot;: null<br>  },<br>  &quot;DigitalWorker&quot;: {<br>    &quot;CycleTime&quot;: 100,<br>    &quot;ConsoleTopicFeedback&quot;: &quot;Coreflux/DigitalWorker/console&quot;,<br>    &quot;ErrorTopicFeedback&quot;: &quot;Coreflux/DigitalWorker/error&quot;<br>  },<br>  &quot;tags&quot;: [<br>    {<br>      &quot;name&quot;: &quot;Test DigitalWorker&quot;,<br>      &quot;code&quot;: &quot;<br>using System;<br>using Coreflux.DigitalWorker;<br>using System.Threading;<br>namespace Test {<br>  class Program { <br>          static void Main(string[] args) <br>           { <br>              int i = 0; <br>              bool ProductionLast=false; <br>              while (true)<br>              { <br>                  if(TagHolder.Read(\&quot;MachineOn\&quot;).Equals(\&quot;true\&quot;) <br>                      &amp;&amp; TagHolder.Read(\&quot;ProductionOn\&quot;).Equals(\&quot;true\&quot;)) <br>                  {<br>                  if(ProductionLast==false) {<br>                         i++;<br>                         Console.WriteLine(i.ToString()); <br>                         TagHolder.Write(\&quot;Count\&quot;,i.ToString());<br>                         Thread.Sleep(1000); <br>                         ProductionLast=true; }<br>                  if(TagHolder.Read(\&quot;ProductionOn\&quot;).Equals(\&quot;false\&quot;)) <br>                  {<br>                   ProductionLast=false; <br>                  } <br>              } <br>            } <br>          } <br>        }&quot;<br>     }<br>  ]<br>}</pre><p>The Digital Worker asset should now be configured with the new settings. You can use the assetConfigLoad command to confirm that the configuration has been applied correctly. Go to the topic $SYS/Coreflux/Cloud/Command and:</p><pre>//assetConfigLoad &lt;theAssetGuid&gt; <br>//in this example:<br>assetConfigLoad 12345678–9abc-def0–1234–56789abcdef0</pre><p>You should get the configuration of the asset. Start the asset by using the command in topic <strong>$SYS/Coreflux/Cloud/Command </strong>:</p><pre>-R 12345678–9abc-def0–1234–56789abcdef0</pre><h3>Check the Runtime</h3><p>Since the Digital Worker Asset has a topic to show everything that writes in the console you can check the topic. In this config, it is Coreflux/DigitalWorker/console. If all is well the digital worker should compile all tags, which are code to run scripts.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/676/1*FKnT6NQ23uqIPtBv2FsAAg.png" /><figcaption>The Console of the Digital Worker</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/986/1*S5UIwoooQeiq1IhdnlZBwA.png" /><figcaption>The feedback in our DataHub</figcaption></figure><p>In this example, we had to change the MachineOn to true and the ProductionOn to true as well.</p><p>If the device changes the MachineOn to true and the ProductionOn we get a Count. Since we have it in our code <em>Console.WriteLine</em> the console topic reacts to our write line command and shows the string.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/558/1*pwDW6RqqURt54b6bAgYJ_g.gif" /><figcaption>Magic🧙‍♂️</figcaption></figure><p>Now, you can send that count to the cloud, providing an injection of information instead of just data. Since the Production Counter and Machine State are signals, the system would need to store and keep up with them at low latency, which can result in <strong>higher cloud costs</strong>.</p><h3>Potential Usage</h3><p>The Digital Worker Asset provides users with the ability to create custom scripts that can contextualize and process data on an IIoT platform. By leveraging the power of C#, users can create sophisticated scripts that can perform complex calculations, manipulate data, and interact with other components of the platform.</p><p>Some examples of scripts that can be created using the Digital Worker Asset include:</p><p><strong>Data transformation scripts</strong>: These scripts can be used to transform raw data into a format that is more meaningful or useful for downstream applications. For example, a script could be created to convert temperature readings from Fahrenheit to Celsius, or to aggregate data from multiple sensors into a single output.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/792/1*kr5g-VmEbkrffBxDLBCSeg.png" /><figcaption>Example Concept</figcaption></figure><pre>{<br>  &quot;MqttClient&quot;: {<br>    &quot;mqttPort&quot;: 1883,<br>    &quot;mqttAddress&quot;: &quot;127.0.0.1&quot;,<br>    &quot;isAnonymous&quot;: true,<br>    &quot;username&quot;: &quot;root&quot;,<br>    &quot;password&quot;: &quot;coreflux&quot;,<br>    &quot;withTLS&quot;: false,<br>    &quot;DebugTopicEnabled&quot;: false,<br>    &quot;DebugTopic&quot;: null<br>  },<br>  &quot;DigitalWorker&quot;: {<br>    &quot;CycleTime&quot;: 100,<br>    &quot;ConsoleTopicFeedback&quot;: &quot;Coreflux/DigitalWorker/console&quot;,<br>    &quot;ErrorTopicFeedback&quot;: &quot;Coreflux/DigitalWorker/error&quot;<br>  },<br>  &quot;tags&quot;: [<br>    {<br>      &quot;name&quot;: &quot;Temperature Conversion&quot;,<br>      &quot;code&quot;: &quot;<br>using System;<br>using Coreflux.DigitalWorker;<br>using System.Threading;<br>namespace Test <br>{<br>  class Program <br>  { <br>    static void Main(string[] args)<br>     { <br>       while (true)<br>       { <br>         var tempF = double.Parse(TagHolder.Read(\&quot;sensor/temperatureinF\&quot;));<br>         var tempC = (tempF - 32) * 5 / 9;<br>         TagHolder.Write(\&quot;sensor/temperatureinC\&quot;, tempC.ToString());<br>         Thread.Sleep(1000); <br>       } <br>     }  <br>  }<br>}&quot;<br>    }<br>  ]<br>}</pre><p><strong>Predictive analytics scripts</strong>: These scripts can be used to analyze historical data and make predictions about future events or trends. For example, a script could be created to analyze the performance of a machine over time and predict when it will require maintenance.</p><p><strong>Control scripts</strong>: These scripts can be used to control the behaviour of other components of the IIoT platform. For example, a script could be created to turn off a machine if it detects an abnormal condition, or to adjust the settings of a sensor based on environmental conditions.</p><pre>assetConfigSave 12345678-9abc-def0-1234-56789abcdef0 {<br>    &quot;MqttClient&quot;: {<br>        &quot;mqttPort&quot;: 1883,<br>        &quot;mqttAddress&quot;: &quot;127.0.0.1&quot;,<br>        &quot;isAnonymous&quot;: true,<br>        &quot;username&quot;: &quot;root&quot;,<br>        &quot;password&quot;: &quot;coreflux&quot;,<br>        &quot;withTLS&quot;: false,<br>        &quot;DebugTopicEnabled&quot;: false,<br>        &quot;DebugTopic&quot;: null<br>    },<br>    &quot;DigitalWorker&quot;: {<br>        &quot;CycleTime&quot;: 100,<br>        &quot;ConsoleTopicFeedback&quot;: &quot;Coreflux/DigitalWorker/console&quot;,<br>        &quot;ErrorTopicFeedback&quot;: &quot;Coreflux/DigitalWorker/error&quot;<br>    },<br>    &quot;tags&quot;: [<br>        {<br>            &quot;name&quot;: &quot;ControlScript&quot;,<br>            &quot;code&quot;: &quot;<br>using System;<br>using Coreflux.DigitalWorker;<br>using System.Threading;<br>namespace ControlScripts <br>{<br>  class Program <br>  { <br>  static void Main(string[] args) <br>    {<br>      while (true) <br>      {<br>        double temperature = Double.Parse(TagHolder.Read(\&quot;sensor/temperature\&quot;));<br>        if (temperature &gt; 80) {<br>                    TagHolder.Write(\&quot;machineOn\&quot;, \&quot;false\&quot;);<br>        }<br>        Thread.Sleep(5000); // Wait 5 seconds before checking temperature again<br>      } <br>    } <br>  } <br>}&quot;<br>        }<br>    ]<br>}</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pUbfIcVUWzNk__487Mjt6A.png" /><figcaption>An example of a stop of a system!</figcaption></figure><p><strong>Reporting scripts</strong>: These scripts can be used to generate reports or alerts based on data collected by the IIoT platform. For example, a script could be created to generate a daily report of production metrics or to send an alert if a sensor reading exceeds a certain threshold. For example a JSON object.</p><p>Here’s an example of a reporting script that generates a daily report of the number of times the temperature exceeds 100 degrees Fahrenheit. The report is stored as a JSON object in Coreflux in a Topic in these case <strong>Coreflux/Reports/DailyReport!</strong></p><pre>using System;<br>using Coreflux.DigitalWorker;<br>using System.Threading;<br>using System.Collections.Generic;<br>namespace Reporting {<br>    class Program {<br>        static void Main(string[] args) {<br>            string reportTopic = &quot;Coreflux/Reports/DailyReport&quot;;<br>            Dictionary&lt;string, int&gt; reportData = new Dictionary&lt;string, int&gt;();<br>            <br>            while (true) {<br>                double temperature = double.Parse(TagHolder.Read(&quot;sensor/temperatureinF&quot;));<br>                if (temperature &gt; 100.0) {<br>                    DateTime timestamp = DateTime.UtcNow;<br>                    string date = timestamp.Date.ToString(&quot;yyyy-MM-dd&quot;);<br>                    if (!reportData.ContainsKey(date)) {<br>                        reportData[date] = 0;<br>                    }<br>                    reportData[date]++;<br>                }<br>                <br>                Thread.Sleep(10000); // wait for 10 seconds before checking temperature again<br>                <br>                // Generate and store daily report<br>                if (DateTime.UtcNow.TimeOfDay &gt;= new TimeSpan(23, 59, 59)) {<br>                    string report = &quot;{&quot;;<br>                    report += &quot;\&quot;timestamp\&quot;: &quot; + DateTimeOffset.UtcNow.ToUnixTimeSeconds() + &quot;,&quot;;<br>                    report += &quot;\&quot;data\&quot;: {&quot;;<br>                    foreach (KeyValuePair&lt;string, int&gt; entry in reportData) {<br>                        report += &quot;\&quot;&quot; + entry.Key + &quot;\&quot;: &quot; + entry.Value + &quot;,&quot;;<br>                    }<br>                    report = report.TrimEnd(&#39;,&#39;);<br>                    report += &quot;}&quot;;<br>                    report += &quot;}&quot;;<br>                    <br>                    TagHolder.Write(reportTopic, report);<br>                    reportData.Clear();<br>                }<br>            }<br>        }<br>    }<br>}</pre><p>The Digital worker can seamlessly store and run up to <strong>15 scripts!</strong></p><p>So let’s make a real-life example for a digital worker asset, to provide an OT/IT integration for a hot water pump based on the temperature of the water. Using the data conversion script, we convert the temperature reading from Fahrenheit to Celsius, which is then used by the control script to turn on or off the pump in case of an excess in temperature. The reporting script collects temperature readings every 10 seconds and generates a message reporting that already 10 times the temperature exceeded 85 degrees Celsius. <br>This way we have a very simple contextualization of a specific parameter, in this case, temperature.</p><p>The configuration of everything together:</p><pre>assetConfigSave 12345678-9abc-def0-1234-56789abcdef0 {<br>  &quot;MqttClient&quot;: {<br>    &quot;mqttPort&quot;: 1883,<br>    &quot;mqttAddress&quot;: &quot;127.0.0.1&quot;,<br>    &quot;isAnonymous&quot;: true,<br>    &quot;username&quot;: &quot;root&quot;,<br>    &quot;password&quot;: &quot;coreflux&quot;,<br>    &quot;withTLS&quot;: false,<br>    &quot;DebugTopicEnabled&quot;: false,<br>    &quot;DebugTopic&quot;: null<br>  },<br>  &quot;DigitalWorker&quot;: {<br>    &quot;CycleTime&quot;: 100,<br>    &quot;ConsoleTopicFeedback&quot;: &quot;Coreflux/DigitalWorker/console&quot;,<br>    &quot;ErrorTopicFeedback&quot;: &quot;Coreflux/DigitalWorker/error&quot;<br>  },<br>  &quot;tags&quot;: [<br>    {<br>      &quot;name&quot;: &quot;DataConversion&quot;,<br>      &quot;code&quot;: &quot;<br>using System;<br>using Coreflux.DigitalWorker;<br>namespace DataConversion {<br>  class Program { <br>          static void Main(string[] args) <br>           { <br>               while (true)<br>              { <br>                  double temperatureInF = Convert.ToDouble(TagHolder.Read(\&quot;sensor\\temperatureinF\&quot;));<br>                  double temperatureInC = (temperatureInF - 32) * 5 / 9;<br>                  TagHolder.Write(\&quot;sensor\\temperatureinC\&quot;, temperatureInC.ToString(\&quot;0.00\&quot;));<br>                  System.Threading.Thread.Sleep(1000);<br>              } <br>            } <br>          } <br>        }&quot;<br>     },<br>     {<br>      &quot;name&quot;: &quot;ControlScript&quot;,<br>      &quot;code&quot;: &quot;<br>using System;<br>using Coreflux.DigitalWorker;<br>namespace ControlScript {<br>  class Program { <br>          static void Main(string[] args) <br>           { <br>               while (true)<br>              { <br>                  if (TagHolder.Read(\&quot;sensor\\temperatureinC\&quot;) &gt; \&quot;100\&quot;)<br>                  {<br>                      TagHolder.Write(\&quot;pump\\onoff\&quot;, \&quot;0\&quot;);<br>                  }<br>                  else<br>                  {<br>                      TagHolder.Write(\&quot;pump\\onoff\&quot;, \&quot;1\&quot;);<br>                  }<br>                  System.Threading.Thread.Sleep(1000);<br>              } <br>            } <br>          } <br>        }&quot;<br>     },<br>     {<br>      &quot;name&quot;: &quot;ReportingScript&quot;,<br>      &quot;code&quot;: &quot;<br>using System;<br>using System.Collections.Generic;<br>using Coreflux.DigitalWorker;<br>namespace ReportingScript {<br>  class Program { <br>          static void Main(string[] args) <br>           { <br>               List&lt;double&gt; temperatures = new List&lt;double&gt;();<br>               while (true)<br>              { <br>                  double temperatureInC = Convert.ToDouble(TagHolder.Read(\&quot;sensor\\temperatureinC\&quot;));<br>                  if(temperatureInC&gt; 85)<br>                  {<br>                      temperatures.Add(temperatureInC);<br>                  }  <br>                  if (temperatures.Count &gt;= 10)<br>                  {<br>                      string report = \&quot;{\\\&quot;timestamp\\\&quot;: \&quot; + DateTimeOffset.UtcNow.ToUnixTimeSeconds().ToString() + \&quot;, \\\&quot;count\\\&quot;: \&quot; + temperatures.Count.ToString() + \&quot;}\&quot;;<br>                      TagHolder.Write(\&quot;reporting\\dailytemperature\&quot;, report);<br>                      temperatures.Clear();<br>                  }<br>                  Thread.Sleep(10000);<br>              } <br>            } <br>          } <br>        }&quot;<br>     }<br>  ]<br>}</pre><p>Overall, the Digital Worker Asset provides users with a tool for contextualizing and processing data on an IIoT platform. By leveraging the flexibility and power of C#, users can create custom scripts that meet their specific needs and add value to their organization.</p><h3>TagHolder</h3><p>The TagHolder is a class provided by the Digital Worker Asset that allows you to interact with Coreflux tags using C# code. The TagHolder provides three main functions: TagHolder.Init, TagHolder.Read, and TagHolder.Write.</p><p>To interact with the Coreflux data hub, you can use TagHolder to read and write tags.</p><p><strong>TagHolder.Init</strong> is used to initialize a tag for reading. Once a tag has been initialized, you can use TagHolder.Read to read the tag’s payload and TagHolder.Write to write a payload to the tag.</p><p><strong>TagHolder.Read</strong> takes a tag name as its argument and returns the payload of that tag as a string. If the tag has not been initialized using TagHolder.Init, TagHolder.Read will return an empty string.</p><pre>// initialize tag<br>TagHolder.Init(&quot;my-topic&quot;);<br><br>// read tag payload<br>string payload = TagHolder.Read(&quot;my-topic&quot;);<br><br>// print payload to console<br>Console.WriteLine(&quot;Tag payload: &quot; + payload);</pre><p><strong>TagHolder.Write</strong> takes a tag name and a payload as its arguments and writes the payload to the specified tag. If the write operation is successful, TagHolder.Write returns true.</p><pre>// send payload to tag<br>TagHolder.Write(&quot;my-topic&quot;, &quot;hello world!&quot;);<br><br>// print success message to console<br>Console.WriteLine(&quot;Payload sent successfully!&quot;);</pre><p>Overall, the TagHolder provides a convenient way to read and write Coreflux tags using C# code. By using the TagHolder in your Digital Worker Asset code, you can easily interact with the Coreflux data hub and integrate Coreflux tags into your application logic.</p><p>Shortly, we will add up the events to this TagHolder. 😎</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*htfqJ1mwbALmvJtjBl0Hcg.png" /><figcaption>Using the Digital Worker in a DataHub! It is like magic in the form of code!🧙‍♂️</figcaption></figure><h3>Troubleshooting</h3><p>When working with the Digital Worker Asset, users may encounter various issues that can prevent the asset from functioning correctly. Here are some common issues that users may face and some tips on how to troubleshoot them:</p><ul><li><strong>Compilation errors</strong>: If you encounter any compilation errors when building your project, the errors will be provided to the Error Console topic. Make sure to check the topic for any error messages and resolve them before running your code.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/691/1*aG-KzruXDFESgbQ448s6Eg.png" /><figcaption>GODAMN!! Not another comma error “;” 😡</figcaption></figure><ul><li><strong>Program errors:</strong> Even if your code compiles successfully, you may still encounter errors at runtime, such as conversion errors or other exceptions. These errors will also appear in the Error Console topic. If you encounter any errors, you can use try-catch blocks to catch them and handle them gracefully. This will ensure that your program continues running even if errors occur.</li><li><strong>Program not running</strong>: Due to the compilation of the asset we have a 15-script limitation per digital worker. Since we use the compiler and machine sometimes each digital worker will consume about 500Mb of memory, this is one of the reasons for our limitation since we want to handle performance as well.</li></ul><p>By following these tips, you can minimize the risk of encountering issues when working with the Digital Worker Asset. If you still encounter any issues, you can refer to the Error Console topic to check.</p><p>For more information and help join our Discord community “<a href="https://discord.gg/2Ta5Zt5v">Coreflux — Flux the System</a>”.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=69318a9ade4" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coreflux-blog/coreflux-c-digital-worker-asset-69318a9ade4">Coreflux C# Digital Worker Asset</a> was originally published in <a href="https://medium.com/coreflux-blog">Coreflux Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Presenting Coreflux Central v1.2 ]]></title>
            <link>https://medium.com/coreflux-blog/presenting-coreflux-central-v1-2-a96d33471d3c?source=rss-4a1410ba423b------2</link>
            <guid isPermaLink="false">https://medium.com/p/a96d33471d3c</guid>
            <category><![CDATA[iot]]></category>
            <category><![CDATA[mqtt]]></category>
            <category><![CDATA[platform]]></category>
            <category><![CDATA[coreflux]]></category>
            <category><![CDATA[data]]></category>
            <dc:creator><![CDATA[Hugo Vaz]]></dc:creator>
            <pubDate>Thu, 23 Feb 2023 01:55:58 GMT</pubDate>
            <atom:updated>2023-05-16T14:05:27.897Z</atom:updated>
            <content:encoded><![CDATA[<p>Coreflux v1.2, or “one-two” as we internally call it, is the latest version of the IIoT Data Hub that is changing the paradigm in Industry, Energy and Smart Cities.</p><p>This new version brings a host of new features and improvements.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/405/1*O0N1fxtgFM5_DLKyvUTE6A@2x.png" /><figcaption>Building with Blocks</figcaption></figure><h3>A Hubless Solution</h3><p>The most significant update in this version is the hubless solution, which allows you to install Coreflux Central on a Terminal machine and handle remote stations using MQTT. This makes it much easier to manage your data hub, as you no longer need a separate hub, all by just getting geeky with commands. 🤓</p><p>Using the same concept as Linux with the root user, you can provide commands directly in the MQTT Broker. This provides a much simpler and more streamlined user experience. Additionally, user administration, asset installation, config preparation, and even tag management can all be changed via your MQTT client. These MQTT topics can enable automation of your data hub, automatically create connections, manage users, and manage your data hub configs.</p><p>The hubless solution of Coreflux Central v1.2 offers many benefits, including improved flexibility and ease of use. With this solution, you can install the software on a wide range of devices, including Raspberry Pi, which is a popular choice for IoT applications. You can also use the terminal to interact with the software, making it easy to manage your data hub remotely.</p><h4>System Health Monitoring</h4><p>Coreflux Central v1.2 provides a fast and easy way to check the health of your Linux, Mac OS, Docker, or Windows system. By showing you important information about memory resources, active connections, and listening ports, you can quickly determine if your data hub is running smoothly or if there are any issues that need to be addressed.</p><p>One of the ways Coreflux Central v1.2 provides this information is through the use of MQTT topics. For example, the <strong>$SYS/Linux-x64/Comms/TCPActiveConnections</strong> topic provides a JSON string with the state, local endpoint, and remote endpoint of all active TCP connections. This allows you to quickly check if there are any unwanted connections to your system and monitor real port serving, which can help identify potential security risks.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nbg2dZQUU3zsE859FKSVHw.png" /><figcaption>Comm monitoring of the health of your data Hub</figcaption></figure><p>By using this information, you can connect to an application, dashboard, or database and check if any backdoors have been opened or if any events have been triggered. You can also monitor active connections and identify potential security risks before they become a problem.</p><p>Overall, Coreflux Central v1.2 provides a powerful system health monitoring tool that allows you to quickly check the health of your data hub. By monitoring active connections and listening ports, you can identify potential security risks and ensure that your system is running smoothly. If you’re looking for a fast and easy way to monitor the health of your Linux, Mac OS, Docker, or Windows system, Coreflux Central v1.2 is the perfect solution.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*U6g0pyP2vDBG-O7aQVPRbw.png" /><figcaption>Memory / Clients and Sessions</figcaption></figure><p>In order to access the $SYS/Coreflux you can use the user &lt;root&gt; and pass &lt;coreflux&gt; when connecting using a brouser like MQTT Explorer.</p><h4>New Assets “Container Style”</h4><p>In Coreflux Central v1.2, we introduce a new Asset with an architecture similar to a Container that offers several benefits. This Asset Container style is an encapsulated package that includes all the necessary assets and dependencies required for a particular asset. This allows us to easily distribute and deploy our assets across different environments, without the need to manually install dependencies on each machine.</p><p>One of the key benefits of the Asset Container style is improved performance. By bundling all the necessary assets and dependencies into one package, we reduce the overhead of loading and accessing files from multiple locations. This can result in faster load times and more responsive applications.</p><p>Another benefit is improved security. By keeping all the necessary assets and dependencies in one package, we reduce the risk of external interference or tampering. This can help to keep our assets secure and protect against malicious attacks.</p><p>Overall, the new Asset Architecture in Coreflux Central v1.2 provides a more efficient and secure way to manage our assets. By encapsulating all the necessary assets and dependencies into one package, we can easily distribute and deploy our assets across different environments. This saves us time and effort and ensures that our assets are always consistent across different systems.</p><h4>Commands to Automate your DataHub</h4><p>Asset containers provide a powerful and convenient way to package and deploy software components, especially in distributed systems. By encapsulating all necessary dependencies and configurations, asset containers make it easier to distribute, manage, and update software components across different environments and platforms.</p><p>You will be using the following topic to communicate with your Data Hub and respective assets:</p><pre>$SYS/Coreflux/Cloud/Command</pre><p>With Coreflux, you can easily install and manage asset containers using a set of command-line options. For example, to install the fins2mqtt asset container for Omron PLCs, you can use the following steps:</p><p>1 -Login to our cloud using the -L command, by providing the following payload in the topic $SYS/Coreflux/Cloud/Command:</p><pre>-L &lt;User&gt; &lt;Password&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/808/1*JEncrHi03ww7iATUCVGXfg.png" /><figcaption>Login Done!</figcaption></figure><p>2- Install the fins2mqtt asset using the -I command by providing the following payload in the same topic:</p><pre>-I coreflux_fins2mqtt</pre><p>(Please run the list command first to check if you have assets, otherwise, you need to buy more of them.)</p><p>Once installed you will see a GUID in the asset list.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IZKSYU1fJUzvXENCZRrE5Q.png" /></figure><p>You can use the assetHelp command to check the configuration options for the fins2mqtt asset container:</p><pre>-assetHelp &lt;theAssetGuid&gt;</pre><p>You can then use the assetConfigSave command to set the configuration for the asset container, using JSON format:</p><pre>-assetConfigSave &lt;theAssetGuid&gt; {&#39;myjsonelement&#39;: 42}<br><br>// To start the fins2mqtt asset container<br>-R &lt;theAssetGuid&gt;</pre><p>In addition, you can use the following commands for additional functionality:</p><pre>//List all assets <br>-l<br><br>//Unistall asset<br>-U &lt;theAssetGuid&gt;<br><br>//check the config of the asset<br>-{&quot;MqttClient&quot;:{&quot;mqttPort&quot;:1883,&quot;mqttAddress&quot;:&quot;127.0.0.1&quot;,&quot;isAnonymous&quot;:false,&quot;username&quot;:&quot;&quot;,&quot;password&quot;:&quot;&quot;,&quot;withTLS&quot;:false,&quot;DebugTopicEnabled&quot;:true,&quot;DebugTopic&quot;:&quot;$SYS/Coreflux/S7Asset/DebugTopic&quot;},&quot;S7&quot;:{&quot;S7IP&quot;:&quot;192.168.100.200&quot;,&quot;RackPlc&quot;:0,&quot;SlotPlc&quot;:1,&quot;Retries&quot;:0,&quot;RetryTimeInSeconds&quot;:8,&quot;RefreshTime&quot;:210,&quot;ConnectionResource&quot;:3},&quot;tags&quot;:[{&quot;name&quot;:&quot;lamp&quot;,&quot;writable&quot;:0,&quot;mqttTopic&quot;:&quot;PLC/Q0.0&quot;,&quot;mqttQos&quot;:0,&quot;mqttRetain&quot;:false,&quot;valueType&quot;:0,&quot;S7Address&quot;:&quot;Q0.1&quot;,&quot;behavior&quot;:0}]}&lt;theAssetGuid&gt;<br><br>//Stop an asset<br>-S &lt;theAssetGuid&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/423/1*jPINg9NQ4x70_Tp4MzXxcA.png" /><figcaption>The list of an awesome account 😅</figcaption></figure><p>The fins2mqtt asset container is just one example of many available assets, such as modbus2mqtt, firebase2mqtt, s72mqtt, NoSQL, and more. Each asset container is designed to provide specific functionality or integration and can be installed and configured using the same set of command-line options.</p><p>Make sure to verify the state of the asset in the Assets topic after running any command, to ensure that it’s running correctly and providing the expected functionality.</p><h4>Why should I get it?</h4><p>Overall, Coreflux Central v1.2 is a significant upgrade over previous versions of our platform, thanks to its hubless solution and powerful MQTT command topics. With these new features, managing your data hub has never been easier. Whether running a small IoT project or a large-scale industrial application, Coreflux Central v1.2 is the perfect choice for managing your data hub and provides a powerful way to automate the workflows of your system or platform.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a96d33471d3c" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coreflux-blog/presenting-coreflux-central-v1-2-a96d33471d3c">Presenting Coreflux Central v1.2 🚀</a> was originally published in <a href="https://medium.com/coreflux-blog">Coreflux Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[MQTT OPCUA, a Coreflux Flux Asset]]></title>
            <link>https://medium.com/coreflux-blog/mqtt-opcua-c27240fbc420?source=rss-4a1410ba423b------2</link>
            <guid isPermaLink="false">https://medium.com/p/c27240fbc420</guid>
            <category><![CDATA[opc]]></category>
            <category><![CDATA[opc-ua]]></category>
            <category><![CDATA[iot]]></category>
            <category><![CDATA[coreflux]]></category>
            <category><![CDATA[mqtt]]></category>
            <dc:creator><![CDATA[Hugo Vaz]]></dc:creator>
            <pubDate>Fri, 04 Nov 2022 18:21:02 GMT</pubDate>
            <atom:updated>2022-11-07T14:14:32.445Z</atom:updated>
            <content:encoded><![CDATA[<h3>MQTT OPC-UA, a Coreflux Flux Asset</h3><p><strong>The Purpose of this Flux Asset</strong></p><p>Coreflux’s MQTT OPC UA is an asset centered around creating a bridge between a machine’s OPC UA data flow and MQTT, synchronizing data to and from broker and server, to effectively allow OPC-UA compatible devices to communicate with other Coreflux assets.</p><p><strong>OPC-UA: Open Platform Communications, Unified Architecture</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/523/1*O-ZpgjNNlRRm_UWSBbccRA.png" /></figure><h3>The Promise</h3><p>OPC-UA is a cross-platform, open-source, IEC62541 standard for data exchange from sensors to cloud applications developed by the OPC Foundation. In general terms, there are standardized data models available for dozens of industrial equipment types (dubbed “Companion Specifications”), published by the governing foundation. Multiple elements are handled, such as authentication, authorization, encryption, checksums, and multiple communication protocols are foreseen, across platforms.</p><h3>The Reality</h3><p>The uniformization of OPC is, when looking at the field, in reality non-existent (despite the initial vision/intention having been sound). Different providers implement it according to their own interpretation of the base specifications. Due to different OPC UA implementations, Coreflux’s support of the OPC protocol will be limited.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Mif0Z6fEbIbRzn1UxaD0bw.png" /></figure><p>This is one of many reasons we consider OPC standard (UA or DA) as a legacy system.</p><h3>Preparation</h3><p>In order to properly implement the MQTT OPC UA flux asset, the following conditions must be ensured:</p><ul><li>Guarantee you have the OPC server installed</li><li>The certificate of the OPC UA defined in the server</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/417/1*o1XMF5YhnBSGcrOibhr7-Q.png" /></figure><h3>Installation</h3><p>Once you press “Install”, you will be presented with the asset configuration window:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/424/1*O0dKovzvuuVhCu6wF2qa1A.png" /></figure><ul><li>OPC UA server → The server of the OPC UA</li><li>TCP port of OPC UA → The port for the OPC UA server</li></ul><p>After installation, the instance window for this asset installation will display the “Standby” status.</p><p>For proper functioning, the asset must be configured (see chapter 5).</p><p>To begin execution of the MQTT OPC Bridge Flux Asset, press the Play button, and if successful, the instance status will change to “Running”.</p><p>If for some reason the inputted configuration fails to execute (or permission to run is not confirmed by the system), the asset will try to enter a run state but return to a halted state when failing to do so, displaying an error popup (on the GUI Hub) or message (on the command-line Hub). If the asset is running, but you’re not seeing responses, see the section Troubleshooting.</p><p>With a version lower than v1.20 in the config file you can change the following attributes:</p><ul><li>browseOPCServer → <strong>True</strong> browses all the variables in the OPC UA server</li><li>autoAcceptServerCertificate → <strong>True</strong> accept the certificate automatically</li><li>username → the username for the OPC UA server</li><li>password → the password for the OPC UA server</li><li>BaseTopicForBrowse → the topic to browse the variables locally</li></ul><h3>Configuring the Tags</h3><p>With a version lower than v1.20 you can find the config in the following file:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/648/1*BSAfKvoqj3Jwrsc98tzCUg.png" /></figure><pre>&lt;ConnectorTag&gt;<br>&lt;name&gt;TagExample&lt;/name&gt;<br>&lt;writable&gt;ToOpc&lt;/writable&gt;<br>&lt;mqttTopic&gt;Coreflux/MQTT_OPC_BRIDGE/Vars/Channel1/Device1/TagExample&lt;/mqttTopic&gt;<br>&lt;mqttQos&gt;AtMostOnce&lt;/mqttQos&gt;<br>&lt;mqttRetain&gt;false&lt;/mqttRetain&gt;<br>&lt;opcAdress&gt;s=Channel1.Device1.Tag22&lt;/opcAdress&gt;<br>&lt;opcNsIndex&gt;2&lt;/opcNsIndex&gt;<br>&lt;Type&gt;Boolean&lt;/Type&gt;<br>&lt;/ConnectorTag&gt;</pre><p>The top parameters can be changed via :</p><ul><li>Name → An identification name for the tag</li><li>Writable → <strong>ToOpc</strong> writes down the tag only in the opc direction. <strong>ToMqtt</strong> writes only to the mqtt direction. <strong>ToAll</strong> writes down to both directions.</li><li>mqttTopic → The topic where it will be written</li><li>mqttQos → AtMostOnce — 0 / AtLeastOnce — 1 / ExactlyOnce — 2</li><li>mqttRetain → True for retain / false without retain</li><li>opcAdress → Node id string</li><li>opcNsIndex → Namespace index for the 2</li><li>Type → Opc UA type :</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/736/1*IaFBKy8t4EccLpRyWZZQ7w.png" /></figure><h3>Conclusion</h3><p>Please find us on our discord server for more information.</p><p><a href="https://discord.gg/P9yG6sxU">Join the Coreflux — Flux The System Discord Server!</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c27240fbc420" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coreflux-blog/mqtt-opcua-c27240fbc420">MQTT OPCUA, a Coreflux Flux Asset</a> was originally published in <a href="https://medium.com/coreflux-blog">Coreflux Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Coreflux Develop blog — Enjoy The changes]]></title>
            <link>https://medium.com/coreflux-blog/coreflux-develop-blog-enjoy-the-changes-b9de31578e25?source=rss-4a1410ba423b------2</link>
            <guid isPermaLink="false">https://medium.com/p/b9de31578e25</guid>
            <category><![CDATA[iot]]></category>
            <category><![CDATA[mqtt]]></category>
            <category><![CDATA[development]]></category>
            <category><![CDATA[coreflux]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <dc:creator><![CDATA[Hugo Vaz]]></dc:creator>
            <pubDate>Mon, 11 May 2020 11:00:58 GMT</pubDate>
            <atom:updated>2020-05-13T10:57:03.024Z</atom:updated>
            <content:encoded><![CDATA[<h3>Develop blog — Enjoy The changes</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FxTghjNTods8aNCGNNTMYA.png" /><figcaption>Old Design Board</figcaption></figure><p>After beta testing, we are on our road for version 1.0. We are rolling out to market, and it is going to be available worldwide. The beta test proved to bring three major concerns:</p><ul><li>The usability and integration of the flux assets from the Hub</li><li>The lack of social interaction with <strong>Coreflux</strong></li><li>The necessity of going mobile</li></ul><p>Since we are striving to bring <strong>the best IoT platform</strong>, we decided to embark in changing everything again and bringing a new design into life. And adding functionalities to reply to the concerns of our users.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-SAbhb1Drt_MJ3fZHVqMYA.png" /><figcaption>Coreflux Hub Splashscreen with web interaction</figcaption></figure><p>The team on the Hub proceeded with 122 git pushes. One of those was entitled the “1001 changes ” since we were starting to become overwhelmed by our design. But we were getting there :</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2qL83iHfIP9IUOyewK-9BQ.gif" /><figcaption>Coreflux Hub — Installing an asset</figcaption></figure><p>The palette colours of the new Hub, the organization of the assets, the integration with documentation and video lessons bring <strong>Coreflux </strong>into a new field. This design is ready for our roadmap to go to into a remote/mobile hub. We already cover the :</p><ul><li><strong>Control of the number of assets from the user account</strong></li><li><strong>Download the assets from the cloud so the user can test/buy</strong></li><li><strong>Starts / Stops of all the flux assets</strong></li><li><strong>Install / Uninstall flux assets</strong></li><li><strong>The basic configuration of the flux assets</strong></li></ul><p>The cloud integration with the Hub was a game-changer but eventually developed some issues. If the user unplugs the Hub from the internet, how do we support the new system? If the Hub receives from the cloud a new flux asset version that does not support the current config, how do we update?</p><p>We have answers for this already, we will post them in due time.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b9de31578e25" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coreflux-blog/coreflux-develop-blog-enjoy-the-changes-b9de31578e25">Coreflux Develop blog — Enjoy The changes</a> was originally published in <a href="https://medium.com/coreflux-blog">Coreflux Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[MQTT and Energy Monitoring Part 1]]></title>
            <link>https://medium.com/coreflux-blog/mqtt-and-energy-monitoring-part-1-5ede86174eb1?source=rss-4a1410ba423b------2</link>
            <guid isPermaLink="false">https://medium.com/p/5ede86174eb1</guid>
            <category><![CDATA[internet-of-things]]></category>
            <category><![CDATA[coreflux]]></category>
            <category><![CDATA[automation]]></category>
            <category><![CDATA[energy-efficiency]]></category>
            <category><![CDATA[iot]]></category>
            <dc:creator><![CDATA[Hugo Vaz]]></dc:creator>
            <pubDate>Sat, 03 Aug 2019 12:17:36 GMT</pubDate>
            <atom:updated>2019-08-03T12:44:14.100Z</atom:updated>
            <content:encoded><![CDATA[<p>What a couple!</p><h3><strong><em>The Constraint</em></strong></h3><p>Recently we wanted to use a small test to see again the capabilities of Coreflux. So we teamed up with ABB, that had a client that have machines able to demand 150 KW of power easily while having 200KW solar panel installation to lower the energy costs.</p><p>Having information is good, you can make adjustments, but in the case of energy monitoring, you need to be remarkably quick to act. Cleary that data needs to select the best performance for your business. Some questions can help you drive into that correlation of data. <br>Is the energy cost of this product better in this machine or another? Is the design of the part energy efficient?</p><p>In the end, we need to get the data from energy monitoring and from the production machines. So we needed to make in the end a system capable of predicting the best outcome in terms of energy efficiency. But for now, both companies decided to prove the concept to the client and do a Prototype test.</p><h3>The Prototype</h3><p>So usually, vendors designing energy monitoring devices are using Modbus to provide data to systems. We wanted to collect and distribute the data and ABB wasn’t any different to Modbus. So ABB lent us a very nice suitcase.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uVzTPEmdzShSJ_CCfR3ozw.jpeg" /><figcaption>ABB — You cannot Improve what you cannot measure</figcaption></figure><p>We used the ABB CMS-700 measuring simulated machine load, this would provide data to an MQTT broker inside the factory that with the Flux Bridge Asset we sent it to our MQTT platform server iot.coreflux.cloud.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/634/1*_oVHbXyJX9w7H6pnsUqHCQ.gif" /><figcaption>The ABB CMS-700 fuse switch monitoring sensor</figcaption></figure><p>In order to show the data in this prototype, we made a small 5-minute dashboard in the free tool Freeboard. Using the MQTT as a data provider.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*k_DRPMsFIK4wp0POXPQy9A.png" /><figcaption>Freeboard.io</figcaption></figure><p>The last step was to prepare the Modbus Flux Asset. So we just went into our hub and installed and configured.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8xBLUxlSXCOi2DO86-YdYQ.png" /></figure><p>Since we are advanced users, we configure the container by hand. This was unnecessary but sometimes we like to make it harder.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rALV-FLI5KTXKATAYMR1lw.png" /></figure><p>All was set and ready to go!</p><h3>The Results</h3><p>We were mind blown with the capabilities of the integration, the device was pushing 489 variables at a rate of 12ms via Modbus. The events were arriving and we were able to draw charts with a proper refresh rate.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/634/1*aFiIbb3oo3ranrqjZb8ilg.gif" /></figure><h3>The Conclusion</h3><p>The implementation with Coreflux was simple and scalable. The possibilities with this kind of integration are vast, one can create:</p><ul><li><strong>Control charging stations of electric-powered cars</strong></li><li><strong>Manage your production orders by deciding what machine to run and when</strong></li><li><strong>Turn your machines on with the most effective sequence</strong></li><li><strong>Check your energy balance with the production of your solar panels and your consumption</strong></li></ul><p>But all this can be made automatically, by using the C#, Python, ASP.net, Node.js APIs you can run small programs to make these solutions. That will be the next step.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/393/1*V2-VnKo_9Nx1UHGcKGlcMw.png" /><figcaption>The <a href="http://coreflux.org/">IoT Platform</a> Community</figcaption></figure><p>Thanks to <a href="https://new.abb.com/pt"><em>ABB</em></a><em> </em>for partnering with us in this adventure.</p><p>(to be continued…) <strong>STAY TUNED FOR MORE EPISODES….</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5ede86174eb1" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coreflux-blog/mqtt-and-energy-monitoring-part-1-5ede86174eb1">MQTT and Energy Monitoring Part 1</a> was originally published in <a href="https://medium.com/coreflux-blog">Coreflux Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The 5 Pillars of IOT Data-driven Manufacturing]]></title>
            <link>https://medium.com/@hugo.vaz7881/the-5-pillars-of-iot-data-driven-manufacturing-f0369994c8c9?source=rss-4a1410ba423b------2</link>
            <guid isPermaLink="false">https://medium.com/p/f0369994c8c9</guid>
            <category><![CDATA[iot]]></category>
            <category><![CDATA[engineering]]></category>
            <category><![CDATA[manufacturing]]></category>
            <category><![CDATA[big-data]]></category>
            <category><![CDATA[level-set]]></category>
            <dc:creator><![CDATA[Hugo Vaz]]></dc:creator>
            <pubDate>Tue, 02 Jul 2019 22:45:09 GMT</pubDate>
            <atom:updated>2019-07-03T23:35:38.587Z</atom:updated>
            <content:encoded><![CDATA[<h3><strong>IoT Data-driven Manufacturing the 5 Pillars</strong></h3><h4>Everyone asks me how they should build their system, but they should not ask that question. The question is why? Followed by, for what?</h4><p>So I am going to write about the 5 major Pillars I normally use.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*S7okCZ07ad6QasTVHOdrnQ.png" /></figure><h3>1.Data for More Efficient Operations</h3><p>Thanks to this influx of data, organizations can improve their operations. Understanding what’s going on at the most granular level possible helps you make better choices on how to run your business. A Cyclical business process optimization would provide the plants with a tool to improve operations.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wX0sEQ_O71x2ePXRDY2x1A.png" /><figcaption>Data Cycle</figcaption></figure><h3>2.Data for Accessible raw materials</h3><p>In order to control the supply chain failures, organizations need to be able to manage the raw materials delivered to the machine, transport and plant. This requires to be controlled by information coming from the operators, machines, transport systems, warehouses, logistic partners and suppliers. All this data needs to be analyzed with predictive analytics and calculated possible delays and raw materials shortages. Also, to understand the full operation of a specific raw material and the impact in the business in terms of time/cost.</p><h3>3.Data for Automation processes</h3><p>IoT allows machines to do much more work than they could previously. In the case of industry, besides the machine provide their own data, the production order to follow up needs to reflect the data-driven process. An automated real-time scheduling system can be fully adopted, this changes an organization from an Information System adopter to a Decision System Adopter. The impact brings the reduction of setup and idle times of machines. And the prioritization of orders and reducing lead time for the client.</p><h3>4.Data for Predictive maintenance</h3><p>A lot of machine in the plants have currently installed sensors that can provide predictive models for predictive maintenance. This machines breakdown are critical for plants, and their preventive maintenance removes production hours. These machines need to be working in a predictive model for that is necessary to standardize these models and have push notification systems for the teams how / when and what to act.</p><h3>5.Data for Business Optimization</h3><p>Typical in an Industrial IOT system a 4 Level system based on a Manufacturing Organization is used:</p><p><strong>Level 1. Machine level </strong>Sensor data analytics enables measures of material production process values, quantity and COP. This can be used to have in the machine the process to warn for predictive maintenance of its own state.</p><p><strong>Level 2. Area/Team Monitoring </strong>Information is generated based on the Machine level providing the first analysis of the business. The accomplishment of orders by area/teams/machine, COP on the Area and according to plan. This information can be showed comparing using ratios from other plants or areas.</p><p><strong>Level 3. Plant Monitoring </strong>The plant can use all unit production historical information and the real-time data to build predictive models, find correlations, detect faults and recognize patterns to optimize the factory work.</p><p><strong>Level 4. Corporate Monitoring </strong>The data is visualized and presented to top management for global-scale informed decision making. Production values, Efficiency from plants, Sales report and Logistic information (ex: lead time )</p><h3>Conclusion</h3><p>Know your business, get your data and build your system….</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f0369994c8c9" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Untold Tejo Cleaning Story — The ones that weren’t mentioned]]></title>
            <link>https://medium.com/@hugo.vaz7881/the-untold-tejo-cleaning-story-the-ones-that-werent-mentioned-e43c1296f3bd?source=rss-4a1410ba423b------2</link>
            <guid isPermaLink="false">https://medium.com/p/e43c1296f3bd</guid>
            <category><![CDATA[level-set]]></category>
            <category><![CDATA[heroes]]></category>
            <category><![CDATA[automation]]></category>
            <category><![CDATA[portugal]]></category>
            <category><![CDATA[environmental-issues]]></category>
            <dc:creator><![CDATA[Hugo Vaz]]></dc:creator>
            <pubDate>Sat, 29 Jun 2019 02:10:12 GMT</pubDate>
            <atom:updated>2020-08-19T16:43:34.427Z</atom:updated>
            <content:encoded><![CDATA[<h3>The Untold Tejo Cleaning Story — The ones that weren’t mentioned</h3><p>Working in Setlevel brought me many challenges, some were quite endeavours, others were harsh, and some had <strong>meaning</strong>. And this story has a lot of <strong>meaning</strong>.</p><p>So back in 2017, we created New Energy Level as a joint-venture with some key players in the environmental services to develop technology for that market. Everything was going normal until 2018 an event occurred.</p><p>1- <strong>The challenge</strong></p><p>One day in January 2018, I was seeing the news and was quite surprised to see that the main Portuguese river was polluted.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/860/0*V0rjrkMa9a951gd0" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/860/0*VXwuY6qcWcj-w4KF" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/860/0*wuWg3BhiIgZFP7OC" /><figcaption>The Tejo Pollution in January 2018</figcaption></figure><p>There was a dry period in Portugal, and after a peak of pollution, the river couldn’t “handle” a fast reduction of the levels of oxygen. It affected several species, and the water was considered unsafe. <strong>So the operation from EPAL in Valada do Ribatejo which produces 240 000 m3 /day was in risk, a service that provides water for 3 million people.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/200/0*-tR7N1ZJCCutYbGV" /><figcaption>Our colours represent the country … off to service!</figcaption></figure><p>So the State decided to act. And at that time we didn’t know we were going to be called for service.</p><p>Three days later, the CEO from NEL told us that Ambitrevo contacted him to help with the operation to clean the river. I was immediately excited and wanted to act…</p><p>But our CTO in NEL had to be the one acting, and we first had to listen. He planned to use a Polymer to mix with the organic matter that was polluting the water from Tejo. And this would bring a solution to aggregate that matter. Then the water with the organic matter would flow to a Geotube to take the water from the organic matter. And the organic matter would be inside a bag where it could be dried or used into a circular economy.</p><p>So a rough project was done!</p><p>While we were designing the solution, the State decided to use a location and Ambitrevo prepared the operation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*wbOR1szOR50jfRvE" /><figcaption>The selected terrain</figcaption></figure><p>2-<strong>The Takeaway</strong></p><p>We had the idea to use a mobile solution since we could re-use the technology and go to where an emergency is. So we decided to buy a Mercedes Van :) and transform it into the <em>Tejo Angel</em>. This beauty was going to be equipped with a 12KW pump to take water out of the river and inside we would have the necessary equipment to make the mix with the polymer. <strong>Our mission put everything moving!</strong></p><p>So we did the electrical cabinet, prepared the hydraulic system, installed the tanks motors, changed the controls, prepared the software, checked the pipes and tested everything with water. And it was messy!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/651/0*8_dszfEHB0tGftrL" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/651/0*nbkHVoJXb8kjmzQS" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/785/1*OPQuq8O8LgodmObAHfHWDg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Q_UNwETjUlsAMIS6" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*r5eL6QrtGHhDo0s_" /></figure><p>Work Work Work !!!</p><p>So after a lot of hours and <strong>5 crazy days</strong> we were able to pull this off. The van was ready, but the work was not done. We usually work with sprints and our work is scheduled, but this was different. <strong>This was part of more</strong>, the river was waiting, and the issue in the river was still there. <strong>This was an emergency, not a typical job.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/323/1*TloTtk4BIXnkEIT9ABIk1A.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/579/1*f7dLPLUWEO1sEj9_OyeUtA.png" /><figcaption>All Ready to go</figcaption></figure><p>3-<strong>The Operation</strong></p><p>The site already had an extensive work from <strong>Ambitrevo </strong>and <strong>Geosin</strong>. They already had placed the Geotube, and it was impressive to see it. <strong>The Geotube from Geosin </strong>was one of the heroes at the site. We had to pull water with the organic material from the river, mix it with our polymer, send it to a tower and from the tower it would flow to the <strong>Geotube</strong>. Where the water was going to leave the <strong>Geotube </strong>and leave the polymer with the organic matter inside.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*lzPMzC2FS07-obRp" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*mNodeFc6j0KC4oGN" /><figcaption>The site!</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*ftHxqnrdPExHKpGd" /><figcaption>The Site</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*BMH9M5syoCBRiXxY" /><figcaption>The first start!</figcaption></figure><p>So we were eager to start, and so we did. But Murphy was around and a pipe burst, so we had a small step back on that day. We had to reschedule for the next day since we needed to do this operation with daylight.</p><p>Next day we started and fixed the faulty pipe, and instead of pushing the system, we went gradually to the maximum water flow. Eventually, everything aligned and the equipment began to show why it was built. The objective was becoming a reality.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*GAPZbaVFVF4Y-8Pg" /><figcaption>Tejo Angel pushing it</figcaption></figure><p>4- <strong>The Result</strong></p><p>So we were able to fill the Geotubes, we were amazed everything was working, the minister of the environment João Pedro Matos Fernandes was going to visit us alongside with the Mayor. All major media coverage was there to report. But we were proud that the matter that was creating the issue was being removed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*tyTF3uUEwI1Wif97" /></figure><p>The final video of the operation was filmed by the State-owned company EPAL, and it still gives me the chills we were part of this.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FgiZmX_12GNE%3Ffeature%3Doembed&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DgiZmX_12GNE&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FgiZmX_12GNE%2Fhqdefault.jpg&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/3e66ad53826d73e186e212b8fcb52b73/href">https://medium.com/media/3e66ad53826d73e186e212b8fcb52b73/href</a></iframe><p>As soon as all this started, it also ended in 19 days since everything was done. The river was cleaned, and we came back home.</p><p>The companies that worked in this system NEL (Setlevel joint venture), Ambitrevo, EPAL and Geosin were critical. <strong>You see, sometimes life brings you opportunities in disguise where you can shine and show that you are more than ordinary. And those that do it, they reach a moment of greatness and so we mention them </strong>:</p><p><strong>Adalberto Maia</strong></p><p><strong>Carlos Faria</strong></p><p><strong>Filipe Pereira</strong></p><p><strong>Filinto Oliveira</strong></p><p><strong>Hugo Felgueiras</strong></p><p><strong>João Fernandes</strong></p><p><strong>João Silva</strong></p><p><strong>José Paulo Mota</strong></p><p><strong>Luis Rosa</strong></p><p><strong>Rui Oliveira</strong></p><p><strong>Saul Costa</strong></p><p>and our Internship Student @ the time Telmo Paiva</p><h4>They did this not just because it is their job but for 3 Million people to still have clean water in their homes.</h4><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e43c1296f3bd" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Grandma’s Recipe: Beckhoff Twincat in MQTT under 15 minutes]]></title>
            <link>https://medium.com/coreflux-blog/grandmas-recipe-beckhoff-twincat-in-mqtt-under-15-minutes-63ec7658e21f?source=rss-4a1410ba423b------2</link>
            <guid isPermaLink="false">https://medium.com/p/63ec7658e21f</guid>
            <category><![CDATA[automation]]></category>
            <category><![CDATA[beckhoff]]></category>
            <category><![CDATA[iot]]></category>
            <category><![CDATA[coreflux]]></category>
            <category><![CDATA[mqtt]]></category>
            <dc:creator><![CDATA[Hugo Vaz]]></dc:creator>
            <pubDate>Thu, 27 Jun 2019 01:37:25 GMT</pubDate>
            <atom:updated>2019-06-28T22:52:08.553Z</atom:updated>
            <content:encoded><![CDATA[<p>Today we were expecting a client to be happy about having his Twincat PLC variables in the cloud. While we were explaining what we were doing, he said: “I have to stop you there!”. So we entered into listening mode, and we got quite excited to hear his feedback! He started, “that is quite a salesman speech. It simply impossible to have it so easy all Twincat variables in an IoT platform.” We got stunned…</p><p>We felt that we were failing as a salesman actually because he couldn’t believe it and we did it several times. So we decided to say :</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/1*_hpLiXp5_DsFOK-IKl005A.jpeg" /><figcaption>Grandma’s Plant</figcaption></figure><p>“My Grandma’s has a DIY recipe for that in her plant!</p><p>She calls it <strong>Beckhoff Twincat in MQTT under 15 minutes. We are going to show it to you. And if we are able to do it in 15 minutes, we can post this story in our blog.</strong>”</p><p>“Show me then!”</p><p>So let’s get into the Recipe.</p><h3>1 Prepare Coreflux (00:00:34s)</h3><p>Install the Beta version of Coreflux for windows in my computer, in this case. It took all 34 seconds so…</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/510/1*Uq-tTokc64LQsQ1qd9mh2g.png" /><figcaption>Installation Coreflux</figcaption></figure><h3>2 Prepare Flux Assets Broker (00:01:02s)</h3><p>After finding the Coreflux HUB in the desktop, we opened and installed the Broker Flux Asset.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/905/1*OpYzPe2rFCvBGBZUlKtWCQ.png" /><figcaption>Broker MQTT prepared</figcaption></figure><h3>3 Prepare Flux Assets ADS2MQTT(00:03:12s)</h3><p>So here comes the toughest part of our recipe. As Grandma’s taught us we have to go to the System manager and check out our ADS Address. Then you select the FLux Asset ADS2MQTT and install it, and the configuration appears.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/546/1*MOQNtIUuw6axbptUSNexmw.png" /><figcaption>Preparation of ADS2MQTT Flux Asset</figcaption></figure><p>Afterwards, we should start the ADS2MQTT and check if it is running.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/373/1*vVdloSmpbCDRBYgRFgiBKQ.png" /><figcaption>ADS 2 MQTT Flux asset</figcaption></figure><h3>4 Check the variables in MQTT FX (00:04:52s)</h3><p>After less than 5 minutes, check your variables in the MQTT FX.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/906/1*E2L7RmTflPwbbrVYLBCb8A.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0reBuGB2PrHB99h-zLMpJQ.png" /><figcaption>MQTT and Twincat variables</figcaption></figure><h3>Results</h3><p>What we were able to accomplish, we had all PLC Variables in Coreflux and were able to get them via a C# application and a python app. That we were developing in between an hour. Our Grandma’s Recipe was a success, and we were able to access all variables and gather every variable change if needed. The system worked based on demand, and we can only connect the necessary variables by subscribing them. However,<strong> if we subscribed to all variables, we had every 1 millisecond an update. </strong>Which is not bad.</p><h3>Conclusion</h3><p>Still, there is an engineering culture in Industry that all data should flow at 1second. Also, there is a ton of “fears” and “superstitions”. The most common is that the plc might not be able to compute the code if it is sending data. Nowadays the ARM9 400 MHz is equipped in the Beckhoff CX8090, and it can do more than 300 MIPS ( Millions of Instructions Per Second). Sending a variable through an ethernet port which also is equipped with its own Communications Module it is not a problem, we have enough bandwidth to provide data to new systems.</p><p>Nothing should stop nowadays if it makes sense an industry into entering a <strong>Data Governance Framework. Business is getting competitive if you don’t have data from your shop floor. It will get tough if you don’t follow a Data Governance framework like most companies are embracing. Start connecting your shop floor devices with your systems. It is possible you need to start doing it, but you need to adopt the correct technologies. </strong>Ask me how I can send you my grandma’s recipes. :)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=63ec7658e21f" width="1" height="1" alt=""><hr><p><a href="https://medium.com/coreflux-blog/grandmas-recipe-beckhoff-twincat-in-mqtt-under-15-minutes-63ec7658e21f">Grandma’s Recipe: Beckhoff Twincat in MQTT under 15 minutes</a> was originally published in <a href="https://medium.com/coreflux-blog">Coreflux Blog</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>