Jump to content

Fernando Castro

Members
  • Posts

    264
  • Joined

  • Last visited

  • Days Won

    24

Posts posted by Fernando Castro

  1. 3 hours ago, yyh2 said:

    1.      got it.
    hint : you can use a modified version of the "V280_Text_enter" example to suit your needs.

    the only limitation of it is that you have to write your Hebrew backwards, since it works left to right and Hebrew is right to left.
    not a big deal if you need to enter a word or two.
    unitronics support…you should know these kind of tricks.

    2. If someone can elaborate on the "transpose" function, it would be great.
        I read the help file about it, got the general idea, but it is still unclear.

    I don't know why it is called "transpose" but is actually a "compression", that is useful if you store characters on MI's

    i.e, 1 ascii char is 8 bits in size, each MI has 16 bits, so if you store 1 Character per MI then you have 1 byte occupied, and 1 byte wasted, "transpose" extracts only the "used" bytes and combines them, so you basically store 2 characters per MI instead of only one. 

    • Like 1
  2. If you have a good relationship with the manufacturer (which seems to be the case) you can set up a laptop with a remote access software so the manufacturer could connect to it and make sure that everything is done properly.

    4 hours ago, ArtemU said:

    I'm completely new to this subject, any help is appreciated.

    I believe is the best way to do it if you don't have previous experience. 

    • Upvote 1
  3. 23 hours ago, Anton said:

    Thanks for the responses guys,

    Additional devices is a real solution, but not applicable for this project.
    I want to try resolve this problem by V350 function

    I am also think about it, but not have experience of TCP/IP communication by Visio. May be you have some samples?
     

    Not really, there is something you could take a look at in the examples folder. I started to implement an FTP client by myself but was very tedious job and never finished.

    I managed to get the responses from the FTP protocol as ASCII values then, list files on the server and start the download but got stuck buffering the file and then writing it to the SD card.

    basically, with TCP/IP you initialize a socket through a specific port, then connect to It and then and then you can use TCP/IP raw to build the messages.

    If you are going to try it will help to Install a program like Wireshark to monitor the messages sent over the network, and debug what is being sent/received.

    As I mentioned before, it will be time consuming 

    • Like 1
  4. Isn't the rest API just a request over http protocol? the authorization is done in the server, right? I mean if that is the case in theory you should be able to do it using. TCP/IP protocol.

    and hard coding the headers of the messages, and the responses ... I mean I don't think it will be worth the time if there is already an easier solution available but seems doable to me.

     

     

  5. I am on an older version of visilogic, so I couldn't open your project, but I think I may know what could be happening:

     

    * Messages 6, 7, and 11mean that the master has found incompatible elements in the data sent between master and slave.

    Are you using the correct function code to write on the Modbus slave?

    remember that on Modbus are different type of write functions: 


    What is Modbus and How does it work? | Schneider Electric USA

    I had a similar problem once while trying to communicate with 2 devices (for one was using write coils, for the other write holding registers) and somehow, I got the IP addresses of each one mixed. 

    so, I think I was trying to write holding registers on a coil address which of course was not available in the selected slave device.

     

     

  6. 17 hours ago, Joe Tauser said:

    Not really.  You need a driver on the PC to communicate with the USB port on the Samba.  Typically you use the RS232 (RJ12) port on the PLC.

     

    Joe T.

    complementing Joe's answer that USB port is actually an USB to RS232 converter embedded in the PLC. In any case, it is easier to use directly the serial port into the PLC the RJ12 (both are physically the same com).

  7. 6 hours ago, Gaylord Williams said:

    real value 1500 showed value 1498

    3000 ==>2992

    750==>748
    1250==>1248

    1000==>1000 

    i tried to correct with corrected value = 1498 + (1500 - 1498) * (1500 / 1498) = 1500.33

    Also, I just realized that in this examples that you gave there are no float numbers all of those are INT ... are you sure that you VFD is using float type?.

    In any case reading the values in hex format as I mentioned before will give you a hint on where the problem is

  8. 4 hours ago, Gaylord Williams said:

    the exchange data format is not precised in my doc , but i can see it with Artics Tools,(a tool to read in the variator) the area is in 16bits format Real.
    it's an AD 5000 from Nidec (no public data)

    i thought about a correcting formula but it's not constant few example of missprecision to help you to understand

    real value 1500 showed value 1498

    3000 ==>2992

    750==>748
    1250==>1248

    1000==>1000 

    i tried to correct with corrected value = 1498 + (1500 - 1498) * (1500 / 1498) = 1500.33

    but for 2992 + (3000 - 2992) * (3000 / 2992) = 3002.34 it's still not precise  

     

     

    there is over there some different float 32-bit representations standards. I did not find the one that Unitronics is using but since I recently did some communication with a device that uses IEEE754 for floating point arithmetic and I got same readings, I am assuming it is IEEE754.

    In your case I'll start reading values in HEX to see if the "RAW" data being sent and received is the same to determine where that precision loss is. is it the data not being transmitted correctly or not converted correctly?

     

    Also, you mentioned REAL data which I think it's not quite the same as FLOAT data. 

     

    but let's start with the hex values, you can use a Modbus master simulator in a computer (Modbus Master Simulator - free software utility for testing Modbus slave devices (dxp.pl)) to see what is in the AD 5000 from Nidec.

     

     

     

     

  9. 11 hours ago, John_R said:

    On the other hand, I was the main programmer at my job for years,

    I knew that someday I would retire, and I made every effort to to document my programs, and ensure that my co-workers had access to all my work.

    to me, that was common courtesy...

    Just sayin'....

     

    I agree, I mean at least I try to have everything documented too.

    I have seen that a lot of people "protect" their programs to charge for the additional services in the future, but not me ..for me is like Mr. Customer, you own this thing here is everything you need to know about it: diagrams, code, drawings help yourself.  (I don't want to be bother for each time a minor change will be made to the system that doesn't affect my part) and chances are that if there is a good relationship with Mr. Customer, he always is going to request more services anyway and if there is not a god relationship with him, I don't want to be tied to Mr. Customer, it will be an endless scope of work, and nothing will be enough for Mr. Customer.

    I get it if it is a custom machinery, or a "turn-key" solution but in that case, the bare minimum is to deliver a hard copy backup that can be installed in a brand-new PLC in the worst-case scenario.

    • Upvote 1
  10. I am surprised by the number of times that question is made.
    And this is not only for Unitronics, but in the automation world, to have access to the source code/project that needs to be intended since the conception of the project.
    90% of the time the original programmer doesn't intend to make their program available to others unless specified by the customer (In my opinion bad practice but it is how it is). 
    If you don't have access to the password, then you need to contact the original programmer, if that is not an option then you will need to do everything from scratch. 

    Every time I had to work on a project the first question I ask is "Do you have access to the original program or a way to make changes?"

    • Like 1
    • Upvote 1
  11. 14 hours ago, Gaylord Williams said:

    Hi , it's my first post,  sorry if i didn't post at the good place.

    I'm working on Visilogics , V700 PLC , and i want to communicate with a VAR to pick up Real Value , i recieve 2 Words of 16 Bits , the first for MSW and second for LSW. this is my parameter's value.

    I need to interpret this value , but the function in Visilogics to convert Integer to Real are for FIXED point , not FLOATTING point , it means it doesn't work in my case , so i came here to ask you guys if there is something i can do , to avoid having to dissect my both words into mantisse and exosant , and use a formula.

    And if there is no function to do it , can you explain to me how to make it simple with this example:  110,1 parameters give me  17 116 for MSW and 13 107 LSW.

    This is my first automatician job (that will make me validate my graduate) and i'm still learning , this is the first time i encounter that case , where i have to do it manually so i really need your help please.

    I answered something like that a couple weegs ago.

    https://forum.unitronics.com/topic/9447-conversion-the-value-of-a-ieee-754-floating-point/

    If I understood correctly you have 1 32 bit  float stored in 2 16 bit MI, you can use the structure function to "Copy" those 2MI on a 1MF. Being the standar Float type AND assuming byte order is the same it will work, if byte order is different you can use swap bytes before structure

  12. 22 hours ago, Alison said:

    Hi guys. First up, I have gone through all the MODBUS vids (thanks) and used the examples, but there are a few things I don't understand. I'm really sorry to ask, because I know these are simple things for you all, but I don't know where else to find this info... there is no one else I can ask.

     I have this V350 which is my "master" and a heat pump which is Modbus enabled, that I am trying to read data from, which would be the Slave. I have no means of programming anything on this heat pump; I cannot download a program to it, so I cannot put the Modbus Slave demo program on it (do I have to do this?! I mean how do you handle that, with stuff that isn't a PLC? Do they default to being "Slave" anyway?). I have some info for it that tells me the default address for the heat pump is  9, and that the COM setup is defaulted to 9600, 8, E, 1 (although I may be able to change this if I have to). I can upload the modbus "map" I have for the heatpump if it helps?

     

    So I used the example Modbus Master program given in the videos and I have changed the settings in the COM INIT function block accordingly.

    I would like to read the heat pump's setpoint temperature, then display it on the HMI.  According to the info I have the heat pump uses holding register 0x24 for this value. I'm assuming this is a hex value and I have to covert to decimal, which is (I think) 36? so I have entered "36" as the value for the start vector in the MODBUS RHR fb. The length of that vector is (for now) just 1, as I am only reading this one register. I have also set the slave ID to 9 here too. The demo program takes the value from that register, and plonks it into MI5 on the Master.  Well, nope. I can't get it to work. 

    I am using the V350's RJ11 connection. It's only 2 wires for  MODBUS  although the connection on the heat pump has 3: A+, B-, and GND. I was just using A and B.

    If I can crack this little bit, I am pretty happy that I can do whatever else I need, it's just getting the basics - and teaching yourself something is never easy! What am I missing here? Is it that  my physical connections are wrong, or is it programming..? Any advice is so welcome. I feel very stupid.

     

    Alison

     

     

    you just need the master program; those examples are to demonstrate how to use the PLC as master or as Slave. devices that are slaves and non-programable like your VFD should have the configuration in the documentation along with a table with address table that they use to transmit the data.

    I'll suggest getting an USB to RS485 adapter (always a handy tool to have) and use a Modbus program on the computer to test first. 

    Amazon.com: Teyleten Robot USB to RS485 485 Converter Adapter CH340T Chip 64-bit Suitable for Windows 7/8 MacOS WinCE5.0 XP(Pack of 3) : Electronics

    Modbus Master Simulator - free software utility for testing Modbus slave devices (dxp.pl)

    as I mentioned before you need to check that your hardware part is OK, then once you are sure it works you can start with the PLC side.

    12 hours ago, Joe Tauser said:

    you're plugged into the USB port and logged in then the COM1 RJ11 port is disabled.

    the problem is that on the PLC it will be difficult to debug if you are using USB port to communicate as Joe mentions. I prefer to use the ethernet port for programing the PLC/ and debugging using online mode.

    22 hours ago, Alison said:

    .  According to the info I have the heat pump uses holding register 0x24 for this value. I'm assuming this is a hex value and I have to covert to decimal, which is (I think) 36? so I have entered "36" as the value for the start vector in the MODBUS RHR fb

    This is correct; however, some vendors start counting at 0 some others on 1, also if you need values that are stored in more than one register (32 bits 2x16) bytes may be in the wrong order some brands use different "endianness".

  13. NVM, solved it with the move function.

    on my computer is as follows:

    Windows + Alt + Space

    then the Move and Close appears on the edge of the screen, I press "Enter" to select Move.

    then maintain the left arrow pressed for a while (because the pop up was at the center of the screen on the right and it takes some time to be "dragged").

    It is a workaround, and you kind of need to know where that window was, or to try both directions for enough amount of time until something happens.

  14. 3 hours ago, Cortes said:

    Hello i work on visilogic with a v700 and i want to know how how can I have the alarms displayed directly on the screen in real time without having to open the menu. Thanks for your help

    What I do is that I created a banner at the top of my screen, color coded with the alarms and some text. the problem is that you could have many alarms at the same time.

    I have dealt with this before cycling through. all the active alarms.

    Each alarm can be linked to a specific bit, and the same with alarm groups so you can use those bits to track active alarms.

  15. 12 hours ago, Ausman said:

    I might not have understood you completely?  I thought that the issue is that the set/reset then can't be accessed on the laptop.  The "move" controls only move the main window, not the popup.

    well, yes that is the main problem and it kind of happens with all other "pop up" windows, not only the "set/reset" one, HMI object properties, Find. etc.

    Not a big deal... but it kind of sucks it may be exacerbated because I use a docking station, with the 2 extra monitors, and I am constantly swapping windows across all 3 screens. 🥴

    I don't want to be that guy but ... Visilogic software is the only one on which I have ran with this issue.🤷‍♂️ 

     

     

  16. 12 hours ago, Ausman said:

    My simpler method 4 up works fine on my systems.

    But if you had the Set/Reset popup showing, you must have been online.  I've just tried this and the main program window moves back ok, even when online, but the popup persists in the original monitor is was in.  The only way I could get it to lose this location was to actually USE it in the right place. But I haven't tried everything.  I did a CtrlAltDel close as well, same thing.

    Some of the popups seem to have a mind of their own as to where they appear.

    cheers, Aus

    Yes, but my problem is that at work I use multiple monitors, at home only the laptop so, I need to remember to drag everything back to the laptop screen and make sure everything is being displayed there before leaving the office... that just isn't going to work I will forget that's for sure. 😂

  17. On 12/19/2018 at 11:58 PM, Joe Tauser said:

    Windows keystrokes are like an Ancient Chinese Secret.

    The Ctrl+Shift + click on icon - blow out user settings in registry.  This will also clear your recent programs list.  I did a little digging and this was added in Win 7.

    Alt+Space then "M" then use your arrow keys to move the window.  It's like magic when that little bugger starts marching over from a display that no longer exists.  You can try these out even if you do have multi-monitors connected.  Goes back to Win 95.

    I had these reinforced in my lizard brain not too long ago when it happened to me moving from work to home - work: Left side 2nd monitor.  Home: right side 2nd monitor. 

    Gah.

    Many programs do not include code to recognize that your display configuration has changed, and the last window position is saved in the registry.  So be a good boy and put your windows back before you close the program.  Santa is watching.

    Joe T.

    Is this still working on windows 10?

    At the office I have 2 monitors I left the Visilogic "SET/RESET pop-up  window" in one of the screens.

    when I needed to, I remote diagnose some PLC I couldn't make that pop-up window appear!  I tried CTR +Shift and launching the program using the desktop shortcut (Or I am doing something wrong?).

    my solution was overcomplicated, but it was the only way I was able to do it: I have another desktop PC always ON, and connected to the same PLC network (that one only has one screen). so, I remoted into that computer then opened visilogic inside that computer to remote connect to the PLC.

  18. On 3/9/2022 at 11:43 AM, kratmel said:

    As far as I know - a rotary knife can not be implemented using the capabilities of the Unistream+Servo platform. This application requires high-speed positioning circuit processing with two encoders - material speed and knife motor speed.

    Such applications require specialized processing modules and appropriate technological software. I am familiar with solutions from Siemens, Nidec (Control Techniques) and Koolmorgen.

    The only case where this application could be built yourself with free software sample code - is a hardware kit from Control Techniques (Unidrive SP +  SMEZmotion with  Power tools Pro software) but Unidrive SP is out of production. All other solutions require additional costs for both  hardware and software.

    You can contact support@unitronics.com for information.

    I have seen those applications using ORMEC Drivers ORMEC | Motion Control | Total System Solutions for Factory Automation.

    On 2/22/2023 at 11:09 AM, Marcelo said:

    Hello, Is there any new develpment in axes coordination using servos? Or with the function "rottary knife"? Thanks

    axis coordination or synchronization are different that the "rotatory knife" when high speed and "electronic camming" is required you need specialized hardware as @kratmel said.

    on axis synchronization the controller does all the reverse kinematics of a given trajectory and send the desired position/speed/acceleration to the drivers. then the motion is "Sync" but actually each driver is doing an independent motion.

    on the rotatory knife application (used often on horizontal packing machinery at high speeds). the idea is that one servo motor is a master and the other a slave, and then one motion should be derived from the other one, you make a motion profile and a virtual cam, so that way the system should behave as it the two motors are mechanically linked together. so High-speed controllers and High-speed communication protocols are required in order to maintain the response time. 

    So, it really depends on the application that you have, and the correct selection of hardware rather than the software. the UMD-0010E-B3 uses CAN-Open:

    Can Open 10 kbit/s to 1000 kbit/s in comparison Servo Wire (Firewire IEEE 1394) works up to 400 Megabit/s

     

  19. 21 hours ago, RickL said:

    I'll need more than just a "heart beat" failure indication of the main PLC controller, thinking to possibly emulate a "catch/throw" error paradigm with-in the main controller to the cause of the controller/peripheral  failure.  Here the extrication PLC  would weigh the best course of action.

    Oh, we all agree on that. you need more than that:

    the SIL assessment, the required performance level (PLr), the category of the SRP/CS, measures against CCF on multi-channel systems, the component MTTFd , and the average test quality of components.

    But sorry I can't help you, has been a while since I took the "Functional safety in machine automation and risk assessment" training. I don't feel qualified enough to give advice on how to design the control system.

     

  20. On 4/1/2023 at 3:07 AM, RAKESH GIRI said:

    thank you so much sir for resolved my problem.

    So, I did not solved the problem? 😂.

     

    2 hours ago, Gabriel Franco said:

    1. Do not place more than one rung in each net. Split them.  

    image.png.71b15f6f1772807588ef27b8b5472262.png

    2. You´re using the same ID (#1) to master and to slave. Fernando already mentioned where to change slave ID address.

    image.png.09158fd918d2407c40eebcbedc11893f.png

     

    It´s highly suggested to use Modbus PC software (such as ModScan, Modbus Poll or any other) to debug communications.

     

    Good catch! from @Gabriel Franco. I assumed that the program was working as it was with another older scanner before.

    If that is the case, the process that I'll do to troubleshoot is first. check the hardware configuration.

    I have the feeling that the issue may not be the Modbus address that you are trying to read (30001 vs 40001).

    If it is RS485, then it is a serial communication is the scanner properly configured? (Baud rate, parity, data bits, timeout) does it require a terminator resistor? sometimes there is a configuration option or dip switch to set those.

    And following Gabriel, you can test on a computer using this Modbus Master simulator: Modbus Master Simulator - free software utility for testing Modbus slave devices (dxp.pl) 

  21. On 4/2/2023 at 8:38 AM, RickL said:

    ....  "I was curious about, but to be honest I don't really care"  - Fernando Castro

     

    That comment has the mentality level we  often see from six graders.  They will express their interest to know  something (that you yourself has stated is true), followed by  "but to be honest  .... I really don't care" (obviously an un-honest contradiction). 

    They deprive themselves of the interest or curious inquiry of the desired subject matter over some other totaly un-related condition.

    As an adult, you should be able to discern that they are two separate entities and address them accordingly. 

     

     

     

     

     

    Maybe I didn't explain myself properly. what I tried to convey is that usually I try to share knowledge and help others to solve problems, to the best of my capabilities at least (I usually care). However, in this case, I don't care.

    I don't care If you succeed or not.

    I don't care if you understood how to use a specific function on the PLC.

    I don't care if you did something overcomplicated to achieve what you were trying to do, and there was a better way.

    I don't care if you knew something that I did not and I miss the oppportunity to learn something new.

    There is No contradiction on my words, I am curious about what are you trying to do and what the heck did you programmed. I don't care if you solve your problem or not.

    You do you.

    8 hours ago, RickL said:

    "Hmmm (and with Joe's permission), it seems perhaps you are really overthinking this, of course I can only speculate what you are trying to accomplish."   - John_R

    I take it Joe's your father or guardian,  I don't know why you need to seek permission from Joe to respond to forum questions, are you not capable to stand on your own  merits??  ..... Are you old enough to be posting on here?   I gonna tell your mom your messing around on the computer here instead of doing your homework!      :  (

    Not my business. but If I had to guess maybe it is because Joe is the most active moderator in the forum? and at least someone (Not me, as I stated before I don't care) is worried that if it gets "off the rails this topic will be forced to be closed before you can get the help that you requested". 

     

     

  22. Hi, I tried to open your project but I have and older version of visilogic Installed.

    I was curious about, but to be honest I don't really care. However I will give you some advise I felt like you already burned some bridges here with all the other topics and I doubt that at this point someone will really wants to invest their own time on explaining everything.

    There is nothi g wrong with not knowing stuff. All of us learned in some way or another, I get that you have the attitude,  but you should have started making an effort to learn the basics first,  then asking for help on the specifics.

    At  this point my first tought was  "He is probably doing something wrong but I don't have the time to understand what he is trying to do, solve it and explain it"., and the fact that there were 0 other comments makes me think that I am not the only one, however I can only speak for myself.

  23. I think you are confusing the terms:

     

    slave ID is usually used to specify the device on the Modbus Network. in the code that you sent is hardcoded to be 1:

    image.png.74f2199b76600f8ba2172edd3639432d.png

     register 400001 and 300001 to me sounds like different function code registers. are you sure that the Masibus Old and New scanner uses different addresses?

    some background on Modbus:

    Modbus works using specified registry addresses, and the called function codes:

    MODBUS Protocol Data Types and Corresponding Description.

    so, 30001 is the first address on the Input registers, and 40001 is the first one on the Holding registers.

    the difference is that holding registers are Read/Write  and Input registers are only Read.

    so, if you want to access register 30001 you need to point to addres 0 of Input registers using function code 4 (Read Input registers).

    the program that you sent is accessing address 0 using function code 3 (Read Holding registers) which happens to be register 40001:

    image.png.d135beabab3529a79b4844620f1055d4.png

     

    If you are sure that you need to read register 30001 then use the appropriate function code:

    image.png.6407eb2ce4896d06764ed7412c6c304a.png

     

    Also, some Modbus devices starts counting on 0, others on 1 just to take into consideration.

    • Like 1
    • Upvote 1
×
×
  • Create New...