Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversion - Page 3


Page 3 of 3 FirstFirst 123
Results 25 to 36 of 36

Thread: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversion

  1. #25
    Member Dancy's Avatar
    Join Date
    Aug 2007
    Location
    usa
    Posts
    125
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    one can buy RS-485 to ethernet, USB and RS-232 adapters
    RS-485 is the industrial version of serial communications and uses differential signaling so can go much greater distance and much higher immunity to noise.
    Yes it is a version of MODBUS
    and it can be transmitted over ethernet.



  2. #26
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    3210
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    Hi Dancy,

    You would want the RS232 to RS485 adapter.

    There is a PC program called modpoll that we often recommend using first to verify functionality from the PC and to verify which modbus registers on which device do what you need. Then afterward modify the tables in the KFLOP ModBus C Program to continuously read and write those registers. There are also 2 functions that need to be modified to load and unload the data to/from the registers and KFLOP virtual bits and variables while doing any packing/unpacking/formatting/scaling. In the end you can then for example just set/clear a KFLOP IO Bit and the corresponding relay in the slave will react accordingly.

    Regards
    TK http://dynomotion.com


  3. #27
    Member
    Join Date
    Jun 2004
    Location
    Scotland
    Posts
    344
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    Quote Originally Posted by Dancy View Post
    one can buy RS-485 to ethernet, USB and RS-232 adapters
    RS-485 is the industrial version of serial communications and uses differential signaling so can go much greater distance and much higher immunity to noise.
    Yes it is a version of MODBUS
    and it can be transmitted over ethernet.
    What Tom was suggesting in his previous post, was the devices may not use standard MODBUS.
    It's not unknown for manufacturers to create there own protocol, but still use some form of generic serial communication. The only way to find out, is to either find the official documentation (which may not even give the required details), or to analyse the data and see if it using a common standard, then try and establish how to access all the registers.

    For analysing, try https://www.virtual-serial-port.org/...serialmonitor/
    I've used it in the past for working out why a VFD wouldn't do what the manual said it should, and it has a 14day fully functional demo period.



  4. #28
    Member Dancy's Avatar
    Join Date
    Aug 2007
    Location
    usa
    Posts
    125
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    (grin) ....I have homework to do

    details to follow



  5. #29
    Member Dancy's Avatar
    Join Date
    Aug 2007
    Location
    usa
    Posts
    125
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    Quote Originally Posted by TomKerekes View Post
    Hi Dancy,

    You would want the RS232 to RS485 adapter.

    There is a PC program called modpoll that we often recommend using first to verify functionality from the PC and to verify which modbus registers on which device do what you need. Then afterward modify the tables in the KFLOP ModBus C Program to continuously read and write those registers. There are also 2 functions that need to be modified to load and unload the data to/from the registers and KFLOP virtual bits and variables while doing any packing/unpacking/formatting/scaling. In the end you can then for example just set/clear a KFLOP IO Bit and the corresponding relay in the slave will react accordingly.

    Dang! you have alot of rabbits in that hat! I am having trouble finding all these tidbits that Kflop can do. Have dug into this web page pretty deep and searched the Wiki. I did find a mention of MODBUS. It implies there is a board to attach to KFLOP. Where do I find that? And code at \C Programs\RS232\ModBus\ ?? is this something provided on purchase of the KFLOP? an install disk perhaps?



  6. #30
    Member
    Join Date
    Jun 2004
    Location
    Scotland
    Posts
    344
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    Quote Originally Posted by Dancy View Post
    Dang! you have alot of rabbits in that hat! I am having trouble finding all these tidbits that Kflop can do. Have dug into this web page pretty deep and searched the Wiki. I did find a mention of MODBUS. It implies there is a board to attach to KFLOP. Where do I find that? And code at \C Programs\RS232\ModBus\ ?? is this something provided on purchase of the KFLOP? an install disk perhaps?
    The KFlop has serial ability as standard, however the pins used don't meet the full RS232 standard. However if you add a Kanalog board, it adds the needed buffer to get full RS232 voltage compliance. RS232 with KFLOP has the details.
    There is also the option to install a driver so you can access the serial port as a COM port on windows, but you shouldn't need to do that - http://dynomotion.com/Help/VirtualComPortwithKFLOP.pdf

    I use a KFlop and Kanalog with Modbus on my lathe to control a Click PLC, and I'll admit it is probably the most challenging bit of KFlop programming I've had to do. It took a few nights of headscratching trying to figure out how to get KFlop to access the right registers, then make the information available for use in the KFlop. Even once I got it working, I still didn't really understand how it worked!



  7. #31
    Member Dancy's Avatar
    Join Date
    Aug 2007
    Location
    usa
    Posts
    125
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    Thanks M_C;
    I have been writing code since 1976 and completely understand! ....if it's working, don't touch it!.
    Have you published your work anywhere? If I may, I would love to see how you accomplished your hardware/software interface to the Click.



  8. #32
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    3210
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    Hi Dancy,

    I am having trouble finding all these tidbits that Kflop can do. Have dug into this web page pretty deep and searched the Wiki. I did find a mention of MODBUS. It implies there is a board to attach to KFLOP. Where do I find that?
    Not exactly sure what you mean. But Kanalog connects to KFLOP and converts KFLOP's 3.3V UART signals to proper RS232 levels. So since your system will likely have a Kanalog you can assume there is an RS232 port available. If you ModBus Slaves require RS485 then you will need to add an external 3rd party RS232 to RS485 converter. If you Google "RS232 to RS485 converter" you should find many for only a few dollars.



    And code at \C Programs\RS232\ModBus\ ?? is this something provided on purchase of the KFLOP? an install disk perhaps?
    You can download our software which includes the ModBus examples from our site.

    Regards
    TK http://dynomotion.com


  9. #33
    Member
    Join Date
    Jun 2004
    Location
    Scotland
    Posts
    344
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    Quote Originally Posted by Dancy View Post
    Thanks M_C;
    I have been writing code since 1976 and completely understand! ....if it's working, don't touch it!.
    Have you published your work anywhere? If I may, I would love to see how you accomplished your hardware/software interface to the Click.
    Zip of my lathe files should be attached.
    Essentially the forever loop in Cyclone_init.c (this is my main machine initialisation file which gets run to configure the KFlop), calls the ModbusMaster_Loop() (which exists in ModbusMasterVer1_cyclone.c), which then handles all the Modbus communication.
    That is continually reading two registers and copying them to UserVars in the KFlop for easy access by any C program running - one is the memory location that contains the current turret position (the PLC does the conversion from the grey/parallel encoder and stores the result in a register), the other is one input bank (it contains the lube level, and door status, although I've still never got around to implementing them!)
    And copying the contents of one UserVar to one register - the desired tool position.

    There are also two hardwired inputs/outputs between the Kanalog and PLC, which allow for some basic handshaking and validating. One from Kanalog to PLC goes high to allow a tool change to take place, and the other one from the PLC to Kanalog should be high if the turret is on the desired position and locked. This sequence is handled by the Cyclone_M6/toolchange programs.

    I have just had a scan through my modified ModbusMaster file, and I seem to remember you have to enter register details in 2 or 3 different places. This was the first machine I ever fitted a KFlop to, so the code isn't the tidiest or best commented, and I seem to remember doing that many edits to the Modbus code, I gave up with comments and never got around to adding them.

    Attached Files Attached Files


  10. #34
    Member Dancy's Avatar
    Join Date
    Aug 2007
    Location
    usa
    Posts
    125
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    M_C;
    have had just a few minutes to skim over your code and it looks better than you give yourself credit for. Thank you so much for sharing it with me. I am sure your examples will save me hours of time.

    Tom:
    "board attached" ...my mistake, while reading the snip on modbus in the Wiki. I saw the 3d board model and the two ports looked like a RS-485 board. Woops!
    Seems I read more than one Kanalog can be attached to Kflop. If so, how is that done? If I can't get this monster to talk via their implementation of MODBUS I will have to deal with about 150 in/out items. I have used I/O expanders via the I2C bus



  11. #35
    Member TomKerekes's Avatar
    Join Date
    May 2006
    Location
    USA
    Posts
    3210
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    Hi Dancy,

    Seems I read more than one Kanalog can be attached to Kflop. If so, how is that done? If I can't get this monster to talk via their implementation of MODBUS I will have to deal with about 150 in/out items.
    No, only one Kanalog can be connected. However besides Kanalog IO up to 4 additional Konnects can be added for an additional 192 IO (128 inputs and 64 outputs). Note for timing and noise susceptibility reasons ribbon cables should be as short as possible. The demo below is testing under worst case scenario.



    Regards
    TK http://dynomotion.com


  12. #36
    Member Dancy's Avatar
    Join Date
    Aug 2007
    Location
    usa
    Posts
    125
    Downloads
    0
    Uploads
    0

    Default Re: Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversio

    Perfect



Page 3 of 3 FirstFirst 123

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

Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversion

Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversion

Intro questions - Windows/Kflop/Kanalog and a 17k pound milling machine conversion