OptoBlog

OptoMMP Tools in groov Manage

Posted by Terry Orchard on Oct 5, 2023 9:20:36 AM

This tech tip post covers some groov Manage tools that make the Opto Memory Map Protocol easier to use.

The Opto Memory Map Protocol (OptoMMP) is a powerful method of interacting with Opto controllers, everything from a PAC brain to the latest groov RIO—however, it's often overlooked and underused. This blog post covers some tools built right in to groov Manage that make OptoMMP more approachable, easier to implement, and straightforward to debug.

The three tools I’ll cover here are all in I/O →  I/O Services, including one that will help practice your MMP skills using the scratchpad. At the end I’ll show a quick MMP example in Node-RED to tie it all together.

Before going into groov Manage, one document deserves a huge shoutout: the OptoMMP Protocol Guide [Form 1465]. With it, you can see every detail about how the protocol is implemented, the breakdown of the packets sent, and how to use lots of exposed features. It is not required reading for general usage of OptoMMP, but it does contain the answer to any questions you might have.

OptoMMPblog-IOservices

In the I/O services you have a bunch of tools available—the primary focus here is the MMP Calculator, Generic MMP, and Scratch Pad.

OptoMMPCalculator

The first and most important place to start is with the MMP Calculator. MMP is entirely based around the hexadecimal memory locations and what is read from and written to those areas of memory. Given the base address of any area you can use offsets to determine any address you need, but it’s much easier to just use the built-in calculator to get the exact address you need.

There are areas for channel configuration, analog and digital read/write, PIDs, and the entire scratchpad. When you’re working with specific points, just put in the module and channel number, then copy the provided MMP address.

OptoMMP Generic

At the bottom of that first section is a direct link to the second tool called “Generic MMP”. This is essentially an MMP browser that will unpack the data at any memory location into a specific data type, including float, string, and signed or unsigned 8, 32, and 64-bit integers.

Everything is stored in memory as just bits of 1’s and 0’s, so this unpacking and parsing is extremely useful—just be sure to select the data type and encoding to match the memory area you’re looking at.

OptoMMPScratchPad

The final groov Manage option to test all this out and make good use of OptoMMP is the Scratch Pad tool. The scratch pad is an awesome way to move data between devices and applications that are calculated or saved separately to live channel values.

Scratch pad values can be shared over MQTT and OPC UA, or interacted with via the groov Manage REST API, groov I/O nodes, our .NET, C++, or Python MMP libraries, or any custom program that communicates with an Opto controller over the MMP port 2001.

In these screenshots I chose the scratch pad string at index #13 as my example. First, I got the value from the calculator, opened and set the string with the Generic MMP, and confirmed it using the Scratch Pad tool.

OptoMMPNodeRED

To bring it all together, here is that same string brought into Node-RED using the groov I/O read node set to use the MMP Address data type. Just a simple example to show how trivial it is to tie OptoMMP into your groov applications using the tools accessible right there in groov Manage.

 

Topics: Node-RED, groov EPIC, groov Manage, groov RIO, OptoMMP

Written by Terry Orchard

Terry is a UC Irvine alumnus that works in technical marketing and focuses on development and content creation. When he's not at the computer he enjoys spending time with his family and pets, flying drones, and working on yo-yo tricks.

    Subscribe to Email Updates

    Recent Posts

    Posts by Topic

    see all