Author Topic: How to access registers of hicon integra  (Read 947 times)

0 Members and 1 Guest are viewing this topic.

Offline a3dcreator

  • Active Member
  • Posts: 45
    • View Profile
How to access registers of hicon integra
« on: November 15, 2017, 10:54:40 PM »
Anyone know how to see the registers for hicon integra in mach4?
Im trying to display some encoder dros from registers

Thanks.
« Last Edit: November 15, 2017, 11:01:24 PM by a3dcreator »

Offline Vital System Support

  • Active Member
  • Posts: 329
    • View Profile
Re: How to access registers of hicon integra
« Reply #1 on: November 16, 2017, 11:48:09 AM »
You can access the registers by name starting with HiCON. You can view the names of registers in Mach4 file menu Diagnostics->Regfile

The registers are read only

Code: [Select]
local inst = mc.mcGetInstance()

local regHandle = mc.mcRegGetHandle(inst, 'HiCON/Encoder0')
local val = mc.mcRegGetValue(regHandle)