Modbus TCP Remote DRO

Here is where you can drop off Examples of WORKING macros,plugins,Gcode programs , macro Wizards etc.
Please give a brief description of what it is and how it works.

Modbus TCP Remote DRO

Postby nm156 » Wed May 03, 2017 3:41 am

Hi All!

New to the forum, been around CNC for almost 20 years. I'm building a new machine and while waiting for parts to arrive I decided to do a little programming.

remote.jpg


You can use an old Windows laptop, desktop or tablet as a remote DRO. (Or even a wallboard with an LCD screen)


This is more of a proof of concept, but it is functional.

Paul

Sorry, had to break up the files due to upload size limitations.
Attachments
TCPModbusRemote.zip
(217.54 KiB) Downloaded 1718 times
README.pdf
(137.01 KiB) Downloaded 1807 times
nm156
 
Posts: 3
Joined: Tue May 02, 2017 8:25 pm

Re: Modbus TCP Remote DRO

Postby cncdrive » Wed May 03, 2017 9:35 am

This is a really nice work.
Thank you for sharing!!!
cncdrive
Site Admin
 
Posts: 4887
Joined: Tue Aug 12, 2014 11:17 pm

Re: Modbus TCP Remote DRO

Postby nm156 » Wed May 03, 2017 8:28 pm

Hello again!

I refined the program somewhat and made it prettier! (I think)

DRORemote2.png


It is now a stand-alone executable without a need for the DLL or font install. It also now runs under the .NET 2.0 framework (same as UCCNC)
README is included in new package. As usual, full source code and example included.

I think the Modbus addition to UCCNC was a great idea. I'm now working on an Arduino Modbus TCP project. :D

Paul
Attachments
TCPModbusRemote.zip
(186.84 KiB) Downloaded 1736 times
nm156
 
Posts: 3
Joined: Tue May 02, 2017 8:25 pm

Re: Modbus TCP Remote DRO

Postby A_Camera » Thu May 25, 2017 8:13 pm

This is really very nice, and I agree that the built in Modbus is a great thing, easy to use and is extremely flexible. I have full control over my VFD through those three wires, very good and useful. I am not only controlling the RPM and the CW/CCW/ON/OFF but also reading a lot of parameters back and update the necessary UCCNC fields with what I want to see, like temperature, current, voltage, real RPM, spindle speed reached and so on. I have also abandoned the spindle start dwell delay and checking the "spindle speed reached" LED to see if the spindle is up and running with the right speed before the M3 or M4 macros are exited. A very simple modification of the macros, and is even compatible with the traditional dwell use if I'd not want to use the VFD flag, just normal delay.

Actually, the built-in Modbus support was a major reason why I bought this software. It is miles ahead of Mach3 Brains... :lol:
A_Camera
 
Posts: 639
Joined: Tue Sep 20, 2016 11:37 am

Re: Modbus TCP Remote DRO

Postby A_Camera » Thu May 25, 2017 8:19 pm

nm156 wrote:I'm now working on an Arduino Modbus TCP project. :D

...and I am working on a PIC Modbus project (just started yesterday).
A_Camera
 
Posts: 639
Joined: Tue Sep 20, 2016 11:37 am

Re: Modbus TCP Remote DRO

Postby Blaise » Sun Dec 29, 2019 11:41 am

Hi nm156, I am new to a lot of things, pretty much in study mode! New to UCCNC, C# macros, MODBUS... Even Windows! (MAC user).
I am pretty good with Arduino, ESP32.

I am working on a diy build router CNC. The mechanical side of the project is still at the drawing stage.
CNC.png


In parallel to cading, I am working on the electronics part of the project. I am quite pleased with my progress! I have, on a bench, UCCNC connected to a UC300ETH, driving a large servo using a DG4S-16035 drive. I got a Huanyang VFD connected via RS485 and the Huanyang plugin! Also started adding external controls like physical buttons for cycle start, pause and so on. I have an MPG working also! So far, so good!

If you look closely on the side of the gantry, I have a basic control panel and I would like to have a LCD with most of what you have in your demo here but a simple LCD driven by an Arduino would suffice. Maybe a ESP32 over WiFi and Modbus TCP?

I feel quite at ease understanding the code in the macro and I am confident, I could modify it to my needs but on the Arduino side, I don’t know where to start. It’s the Modbus protocol that I have a hard time wrapping my head around.

I was wondering if you have progressed with your Arduino code?

Many thanks for sharing!

- Blaise
Blaise
 
Posts: 81
Joined: Tue Jan 16, 2018 3:41 am

Re: Modbus TCP Remote DRO

Postby Blaise » Fri Jan 03, 2020 2:12 pm

Never mind... It took some fiddling around but I got the Arduino talking over Modbus RTU.
This is gonna make wiring of the CNC and electronics so much easier and cleaner!
Blaise
 
Posts: 81
Joined: Tue Jan 16, 2018 3:41 am

Re: Modbus TCP Remote DRO

Postby thesleepydog » Thu Jan 09, 2020 9:56 pm

Blaise wrote:Never mind... It took some fiddling around but I got the Arduino talking over Modbus RTU.
This is gonna make wiring of the CNC and electronics so much easier and cleaner!


Would you consider posting some info on how you got it to work? Maybe some screenshots ? Would greatly appreciate it.
thesleepydog
 
Posts: 15
Joined: Sun Mar 03, 2019 11:10 am

Re: Modbus TCP Remote DRO

Postby Blaise » Fri Jan 10, 2020 4:13 am

thesleepydog wrote:Would you consider posting some info on how you got it to work? Maybe some screenshots ? Would greatly appreciate it.


It will be my pleasure. I would like to clean things up a little in the code first. And, also, there are still a few things I need to figure out but as soon as I have something that makes sense, I'll post it here.
Blaise
 
Posts: 81
Joined: Tue Jan 16, 2018 3:41 am

Re: Modbus TCP Remote DRO

Postby Soler » Sun Feb 02, 2020 12:32 am

A tutorial for this would be great
Soler
 
Posts: 32
Joined: Sun Feb 02, 2020 12:20 am

Next

Return to UCCNC TOOL BOX

Who is online

Users browsing this forum: No registered users and 0 guests