1
Brains Development / Update DRO from Modbus
« on: October 20, 2008, 08:49:16 PM »
I programmed a PIC chip to be a mini ModBus and it seems to be working great
I created a little VB script to step thru to see how it's doing and it does just what I want, It inputs 64,65,66,67 and assign's the correct values to the variables.
As you can see from the script I have a DRO assigned 1010 that it displays the XaxisRegister and it does that all correctly.
TabletXaxisPos = GetInput(64)/1000
TabletYaxisPos = GetInput(65)/1000
ButtonValue = GetInput(66)
FlagValue = GetInput(66)
SetOemDRO(1010,TabletXaxisPos)
All of the script works fine!!!
I am trying to write a brain to automatically update the DRO instead of a macropump and I'm not having any luck.
My brain shows MOD:4-P:64 Formula = A/1000 OEMDRO:1010 I divide by 1000 to scale the 0 to 12000 input to inches
My Mod bus is Address 01 and its the first 4 registers. I must be doing something wrong in the Mod bus definition somewhere but can't see it.
I'm trying to display my Graphics Tablet on the Screen
Kisssys
I created a little VB script to step thru to see how it's doing and it does just what I want, It inputs 64,65,66,67 and assign's the correct values to the variables.
As you can see from the script I have a DRO assigned 1010 that it displays the XaxisRegister and it does that all correctly.
TabletXaxisPos = GetInput(64)/1000
TabletYaxisPos = GetInput(65)/1000
ButtonValue = GetInput(66)
FlagValue = GetInput(66)
SetOemDRO(1010,TabletXaxisPos)
All of the script works fine!!!
I am trying to write a brain to automatically update the DRO instead of a macropump and I'm not having any luck.
My brain shows MOD:4-P:64 Formula = A/1000 OEMDRO:1010 I divide by 1000 to scale the 0 to 12000 input to inches
My Mod bus is Address 01 and its the first 4 registers. I must be doing something wrong in the Mod bus definition somewhere but can't see it.
I'm trying to display my Graphics Tablet on the Screen
Kisssys