Trouble interpreting data from Recorder

Hello RSI,
I’m setting up a simple recorder to record the position of one Yaskawa Sigma7 motor/drive actual position. It’s heavily based on your C# example.

I do RecorderCountSet(1) before any axis/multiaxis creation.

I have set the memory I want to read from as axes.RSIAxisAddressType.RSIAxisAddressTypeACTUAL_POSITION.

Right now when testing the machine is standing still with no commanded movements. For one run the recorded values fluctuates from 3288334336 to 3556769792. I thought ACTUAL_POSITION would give values in user units, but even if it is in counts it is way off when I compare it to the “Primary encoder feedback” in Rapid Setup. I attach a picture of some example output of my recorder compared to what I get from ActualPositionGet().

I checked axes.AddressGet(RSIAxisAddressType.RSIAxisAddressTypeACTUAL_POSITION)) and it evaluates to: 0x000000000d5e7678
I followed this custom trace guide to try to trace adress 0x0d5e7678. But then intime will throw an exception (pictured).

I’m probably missing something obvous here…


example-output intime-error

Unfortunately the Recorder.cs sample code you referenced is incorrect, I apologize. It will be updated today :slight_smile:

The recorder can record 64-bit double values as well as 32-bit integer values. When you are record something like ActualPosition, which exists as a 64-bit double in the RMP firmware, you will need to use:

RecorderRecordDataDoubleGet() instead of RecorderRecordDataValueGet().

So your code (and our code) should read:

Double positionRecord = controller.RecorderRecordDataDoubleGet(0)

It will not be scaled by the UserUnits so you’ll have to do that after getting the value.

The custom trace guide uses a firmware address (32-bit) for custom traces. The value returned from AddressGet(…) is a Host Address (the 64-bit address in your PC’s RAM).

To get the firmware address, you can do this:

Uint32 firmware address = controller.FirmwareAddressGet(axis.AddressGet(ACTUAL…))

Thank you Scott, all understood. I have some beautiful data coming in from my recorder now.

2 Likes