Hello Guest it is March 29, 2024, 09:57:29 AM

Author Topic: Remote USB display with Modbus  (Read 22832 times)

0 Members and 1 Guest are viewing this topic.

Remote USB display with Modbus
« on: June 11, 2011, 10:37:58 AM »
Hi All, I am having a hard time getting a handle on getting the DRO info to my LCD.
I know nothing about VB so I used one from another thread. The USB board I am using is
A Gravitech SLCD-3-Kit seen here http://www.gravitech.us/sechlcddrbok1.html
I am including the settings I am using and a vidieo of what the LCD is showing.
It is close but not right and keeps scrolling.http://www.youtube.com/watch?v=0z4vCZEsZa4
"Gravity, its not just a good idea its the law"

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Remote USB display with Modbus
« Reply #1 on: June 11, 2011, 12:13:32 PM »
I might be wrong BUT I don't think you can do Modbus over USB. IF you had the NONUSB verison it should work fine as it uses RS232 which MACH can talk to through SendSerial or serial modbus.

IF you need LCD support it can be done through a MODIO unit from Peter Homann. OR from a POKEYS.

Just a thought. (;-) TP
Re: Remote USB display with Modbus
« Reply #2 on: June 12, 2011, 09:06:32 AM »
Thanks for the reply but it is possible, there are several pentants sold that are USB that have LCD read outs. If you saw the video I am close it is sending the DRO info just not the right format.
"Gravity, its not just a good idea its the law"

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Remote USB display with Modbus
« Reply #3 on: June 12, 2011, 01:57:49 PM »
You may want to try sending it ALL as a string instead of individual updates.

The USB pendants are normaly run with a PLUGIN.

Just a thought, (;-) TP

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Remote USB display with Modbus
« Reply #4 on: June 12, 2011, 02:38:33 PM »
OOPS the sendstring is a modio control you are using sendserial.

(;-) TP

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Remote USB display with Modbus
« Reply #5 on: June 12, 2011, 03:28:56 PM »
OK normaly when you write to an LCD you write to a position on a matrix such as row0 column 1

For a 4x20 display you would have rows 0-3 (4) and columns 0-19 (20).

What you are doing is sending charector straight in and it just wraps the data around and around (linewrapping).

Look at the manual for the format for writing to the LCD display.

(;-) TP
Re: Remote USB display with Modbus
« Reply #6 on: June 12, 2011, 04:18:39 PM »
OK normaly when you write to an LCD you write to a position on a matrix such as row0 column 1

For a 4x20 display you would have rows 0-3 (4) and columns 0-19 (20).

What you are doing is sending charector straight in and it just wraps the data around and around (linewrapping).

Look at the manual for the format for writing to the LCD display.

(;-) TP

Thanks for the help, I have the manual it is down loadable from http://www.gravitech.us/sechlcddrbok1.html
But it is all Greek to me I have never tried to program anything before, it is going to take  someone smarter than me to
figure it out.

"Gravity, its not just a good idea its the law"

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Remote USB display with Modbus
« Reply #7 on: June 12, 2011, 05:48:11 PM »
I'll Have to dig out some old info when we did it long ago for hand pendants.

(;-) TP

Offline BR549

*
  •  6,965 6,965
    • View Profile
Re: Remote USB display with Modbus
« Reply #8 on: June 12, 2011, 07:42:15 PM »
OK I have no idea if this will work but give it a try. WHat we are doing is sending 1 long string of everything. Everything is spaced out so when it line wrappes ALL the stuff lines up on each line(hopefully)  If you need to adjust it do it in the " " at the each of each line the spaces are empty holder places ADD or subbtract a space to adjust. Basically each line is 16 charectors lone then it wrapps the line.

The "?Y0,?X0" SHould be the starting point of the Matrix, Row 1 column one

We may need to send a blank page each time but try it first.

XV = "X: " & Format (Getdro(0) , "+000.0000;-000.0000") & "    "
YV = "Y: " & Format (Getdro(1) , "+000.0000;-000.0000") & "    "
ZV = "Z: " & Format (Getdro(2) , "+000.0000;-000.0000") & "    "
AV = "A: " & Format (Getdro(3) , "+000.0000;-000.0000") & "    "
MS = "?Y0,?X0"
SendSerial "" &MS &XV &YV &ZV &AV

Re: Remote USB display with Modbus
« Reply #9 on: June 13, 2011, 05:52:05 PM »
Well I tried the VB above and it still does the same thing. Is there something in the ModBus status and controll settings I need to set up?
Thank you so much for taking the time to help me.



OK I have no idea if this will work but give it a try. WHat we are doing is sending 1 long string of everything. Everything is spaced out so when it line wrappes ALL the stuff lines up on each line(hopefully)  If you need to adjust it do it in the " " at the each of each line the spaces are empty holder places ADD or subbtract a space to adjust. Basically each line is 16 charectors lone then it wrapps the line.

The "?Y0,?X0" SHould be the starting point of the Matrix, Row 1 column one

We may need to send a blank page each time but try it first.

XV = "X: " & Format (Getdro(0) , "+000.0000;-000.0000") & "    "
YV = "Y: " & Format (Getdro(1) , "+000.0000;-000.0000") & "    "
ZV = "Z: " & Format (Getdro(2) , "+000.0000;-000.0000") & "    "
AV = "A: " & Format (Getdro(3) , "+000.0000;-000.0000") & "    "
MS = "?Y0,?X0"
SendSerial "" &MS &XV &YV &ZV &AV


"Gravity, its not just a good idea its the law"