Help setting up GS3 Vfd to mach3 and controlling it via modbus


Results 1 to 8 of 8

Thread: Help setting up GS3 Vfd to mach3 and controlling it via modbus

  1. #1
    Registered
    Join Date
    Mar 2016
    Location
    Canada
    Posts
    3
    Downloads
    0
    Uploads
    0

    Default Help setting up GS3 Vfd to mach3 and controlling it via modbus

    Hello,

    I have been posting this around trying to find a solution.

    I have set all my devices to use 8bits, Odd, 1 stop bit for the modbus protocol.

    The attached images show my various settings.

    The scripts I'm using are as follows. I downloaded these from another post and am not familiar with the nomenclature to identify any problems.

    M3
    call setmodoutput (0,1)
    call setmodoutput (1,1)
    call setmodoutput (64,600)
    DoSpinCW()

    M4
    call setmodoutput (0,1)
    call setmodoutput (1,0)
    call setmodoutput (64,600)
    DoSpinCCW()

    M5
    call setmodoutput (0,0)
    call setmodoutput (2,1)
    DoSpinStop()

    Spindle Speed
    rpm = GetRPM()
    SetSpinSpeed( rpm )

    The following link shows the modbus addresses for the VFD starting at 9.26 (page 5-9 lower right corner)
    https://www.automationdirect.com/sta...s/gs3m/ch5.pdf

    If someone can explain to me why I have found a need to drop the first 4 when I enter the address into Mach3 I would appreciate it. When I enter the address as listed I get an "illegal data address" status message.

    I also saw another post setting up a GS2 drive where they had also dropped the 4.
    http://www.machsupport.com/forum/ind...c,27376.0.html

    The above has a starting register of 2330 and 2331 I have mine set to 2331 and 2332.

    What I have observed. With Starting Registers 2331 and 2332

    VFD display on startup: Stop, 0 RPM, Forward

    In MDI I enter an M4 command and observe that the vfd displays: 0 RPM, Stop, Reverse

    M5: Stop, 0 RPM, Forward

    M3: External Fault , Reverse, Stop -----the external fault address is 42334, the next address after direction address

    When I enter M5: Stop, Forward, External Fault message

    If I enter an s command there is no change.

    Now if I change my starting addresses to 2330 and 2331 the following is displayed

    M4: Run, Forward, 1765 RPM (this is rpm at 60hz) ---Direction has changed, It's running vs stopped, and RPM is not 0
    M5: Stop, Forward, 0 RPM
    M3: Run, Reverse, 17 RPM
    M4: Run, Forward, 17 RPM

    The RPM for M4 will remain 1765 until an M3 command is given then both will be 17 following that command. I have no idea why.

    If I give an s command, s600 m4, the vfd displays a message of invalid data.

    I hope there is enough information available for people to provide me with some insight into what is going on. And what I can do to fix it.

    Thanks

    Similar Threads:
    Attached Thumbnails Attached Thumbnails Help setting up GS3 Vfd to mach3 and controlling it via modbus-prts-pns-jpg   Help setting up GS3 Vfd to mach3 and controlling it via modbus-moutputs1-jpg   Help setting up GS3 Vfd to mach3 and controlling it via modbus-modbusstatus-cntr-jpg  


  2. #2
    Registered
    Join Date
    Mar 2016
    Location
    Canada
    Posts
    3
    Downloads
    0
    Uploads
    0

    Default Re: Help setting up GS3 Vfd to mach3 and controlling it via modbus

    I have managed to control my spindle through modbus using mach3. I abandoned the method above and decided to use brains instead. For any interested I'm using a GS3 23P0 Drive, a Marathon Y1999 motor, and a USB-rs485 cable. I will be posting my solution, please keep in mind that I'm new to this and don't understand it all, I'm also no professional when it comes to documentation so I expect this to be a bit of a mess.

    I have included my Brain file "SpindleControlModbus", you will need to rename the extension on the file from .txt to .brn. Copy it to your mach3 folder then into the folder labelled brains. Hopefully it works.

    Rounding Explanation Link
    Rounding number in brains formula

    Explanation on Modbus fields
    MODBUS 3

    Manual for my particular VFD (see section 5-9 for register values, section 5-75 for communication breakdown)
    DURApulse AC Drives User Manual



    Attached Thumbnails Attached Thumbnails Help setting up GS3 Vfd to mach3 and controlling it via modbus-portsettings485-jpg   Help setting up GS3 Vfd to mach3 and controlling it via modbus-usb-rs485com-jpg   Help setting up GS3 Vfd to mach3 and controlling it via modbus-1ports-pinsmod-jpg   Help setting up GS3 Vfd to mach3 and controlling it via modbus-2motoroutputs-nothing-jpg  

    Help setting up GS3 Vfd to mach3 and controlling it via modbus-3spindlesetup-jpg   Help setting up GS3 Vfd to mach3 and controlling it via modbus-4modbusconfig-jpg   Help setting up GS3 Vfd to mach3 and controlling it via modbus-5braindiagram-jpg   Help setting up GS3 Vfd to mach3 and controlling it via modbus-6settingoutputtomodbus-jpg  

    Attached Files Attached Files
    Last edited by Program; 03-12-2016 at 06:25 PM.


  3. #3
    Registered jwolin's Avatar
    Join Date
    May 2005
    Location
    United States
    Posts
    56
    Downloads
    0
    Uploads
    0

    Default Re: Help setting up GS3 Vfd to mach3 and controlling it via modbus

    Wow, thank you so much for posting this information! Guys like you that take the time to help others are very much appreciated! I am eager to try this out on my GS3 as well. On question: Is there something special about the USB-rs485 converter you chose? I am planning on getting a simple, inexpensive one like this unless I need something different.

    http://cncmentor.com - open source sharing community and CAD Library


  4. #4
    Registered
    Join Date
    Mar 2016
    Location
    Canada
    Posts
    3
    Downloads
    0
    Uploads
    0

    Default Re: Help setting up GS3 Vfd to mach3 and controlling it via modbus

    That's nice of you, your welcome. Hopefully configuring it will go smoothly for you.

    As far as the USB rs 485 converter I chose, it was because I had ordered the VFD and the motor from automation direct (I have nothing but good things to say about them) and they also sold the converter and I didn't want to bother risking any compatibility issues. That was pretty much my only reason, I didn't shop around, I just included it in my order. When it comes to connecting my converter all I do is plug in the USB end and then connect the RJ12 cable and plug that into the VFD. I'm not sure how one would connect the USB rs485 in your link to the VFD.

    Here's a link to the USB rs485 I purchased, it is more expensive

    USB-485M

    One thing I forgot to mention in my post and I found this out later was the reason for subtracting one from the register value when using modbus.

    " Per MODBUS convention, the register address of the slave device is calculated by subtracting 1 from the register name that you specify in the
    master device configuration software"

    http://www.micronor.com/products/fil...usTutorial.pdf

    Above is the link to the quote, just search the pdf for subtracting and you will find the question.



  5. #5
    Member
    Join Date
    Apr 2013
    Location
    Sweden
    Posts
    1846
    Downloads
    2
    Uploads
    0

    Default Re: Help setting up GS3 Vfd to mach3 and controlling it via modbus

    Very interesting. Thank you for the details and the brain file.



  6. #6
    Registered
    Join Date
    Feb 2016
    Location
    United States
    Posts
    7
    Downloads
    0
    Uploads
    0

    Default Re: Help setting up GS3 Vfd to mach3 and controlling it via modbus

    Great write up (from over 1 year ago). Im going to try this and see how it works for me. I ordered the cable that's recommended and it should be here early next week.



  7. #7
    Registered
    Join Date
    Oct 2014
    Posts
    2
    Downloads
    0
    Uploads
    0

    Default Re: Help setting up GS3 Vfd to mach3 and controlling it via modbus

    I did all this but still can't get it to work
    what do I need to change on the drive
    i know this is an old post but I don't understand this stuff
    how can it tell if the computer is talking to the drive
    thanks



  8. #8
    Member
    Join Date
    Apr 2013
    Location
    Sweden
    Posts
    1846
    Downloads
    2
    Uploads
    0

    Default Re: Help setting up GS3 Vfd to mach3 and controlling it via modbus

    Quote Originally Posted by jdolecki View Post
    I did all this but still can't get it to work
    what do I need to change on the drive
    i know this is an old post but I don't understand this stuff
    how can it tell if the computer is talking to the drive
    thanks
    Very difficult to say because it can be almost anything if you followed the advise to the letter.

    Wrong port number.
    Wrong register numbers.
    VFD configuration error.
    Wrong BOB.

    Those are just four common issues because those depend on your individual hardware setup.

    https://adapting-camera.blogspot.com
    https://www.youtube.com/c/AdaptingCamera/videos


Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


About CNCzone.com

    We are the largest and most active discussion forum for manufacturing industry. The site is 100% free to join and use, so join today!

Follow us on


Our Brands

Help setting up GS3 Vfd to mach3 and controlling it via modbus

Help setting up GS3 Vfd to mach3 and controlling it via modbus

Help setting up GS3 Vfd to mach3 and controlling it via modbus