Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

"No response, check COM settings"

Help
Bilal
2012-01-12
2013-05-30
  • Bilal
    Bilal
    2012-01-12

    Hi first of all ,thanks for all your effort,

    My problem is that I cant communicate to my PLC  Micrologix1000 via DF1Comm driver. When I run the AdvancedHMI project, I get an error saying "INVALID VALUE RETURNED. Failed to open COM4" on all the objects. I noticed that he had the DF1Comm object set to COM4 in his PDF, but COM2 on his channel 0 settings, so I tried setting the DF1Comm object to COM2, and then got this error: "INVALID VALUE RETURNED! No response, check COM settings".

    Note : The computer I use it doesn't have physical serial port instead I use PL-2303 USB-to-Serial Bridge Controller to connect my PLC.

    Thanks for your concern,

     
  • Archie
    Archie
    2012-01-12

    Is RSLinx running at the same time and using the serial port?

     
  • Bilal
    Bilal
    2012-01-12

    Thanks for fast respond,

    When I've download program to PLC after that I shut RSLinx down yet more I change the serial COMX port for example : "COM3  to COM4" just  to prevent conflicting . No chance yet.

    Any help would be appreciated.

    Thanks

    Note: I am running Windows 7  pro 64bit ,Visual studio 2010 , AdvancedHMIv321, Micrologix1000

     
  • Archie
    Archie
    2012-01-13

    What are the settings in RSLinx that allows you to communicate:

    COM Port
    Baud Rate
    BCC/CRC
    Half/Full Duplex
    …..

     
  • Bilal
    Bilal
    2012-01-13

    My RSLinx settings :

    Configure RS-232 DF1 Devices

    Device : PLC-CH0

    Comm Port       : COM4
    Baud Rate         : 9600
    Parity                   : None
    Stop Bits             : 1
    Error Checking  : CRC
    Protocol               : Full Duplex

    Good days,

     
  • Archie
    Archie
    2012-01-13

    The one setting that doesn't seem quite right is PLC-CH0 . That indicates a protocol for the PLC5, which is not supported by the DF1 driver with AdvancedHMI. Will RSLinx work if you use SLC-CH0/Micro/PanelView ?

     
  • Bilal
    Bilal
    2012-01-13

    Yes, I've used this too .     "if you use SLC-CH0/Micro/PanelView? "
    I've uploaded some capture pics. If you have some time please check them. They might give you some clue.

     
  • Archie
    Archie
    2012-01-13

    I can see in the picture the DF1Comm is set to COM2, but RSLinx uses COM4. You will need to use the same COM port that RSLinx works with and be sure RSLinx is completely shut down. Check the component tray to make sure RSLinx is not just minimized

     
  • Bilal
    Bilal
    2012-01-13

    I use same COM port for DF1Comm and RSLinx  .Now they all set to COM4. I am sure that RSLinx shut it down. But same as before I am still  getting error "No Response Check COM Settings" .

    I write simple program for PLC " Start button "B3:0/0" , Stop Button "B3:0/1" ,Motor "O:0/0". I use  MomentaryButton for  Start , Stop button and PilotLight for Motor.

    Pulling Data from PLC  ;  Set  to MomentaryButton --> PLCaddressClick = B3/0 " B3/1 for Stop".
                                                  Set to  PilotLight-> PLCaddressValue = O:0/0 "Motor address"


    I think if my COM port does not properly work then How I upload program to my PLC .

    I am sorry that I've already  taken your lot time so far but I cant really find enough documents to benefit.
    By the way , this will be my last bother :).

    Thanks a lot for your concern..

     
  • Archie
    Archie
    2012-01-13

    It's no bother. I know serial communications can sometimes be a real hassle to sort out. This is what I would do to see if communications with the PLC are occuring:

    Download this serial port monitor tool:
    http://www.serial-port-monitor.com/free-serial-port-monitor-downloads.html

    Create a new session using COM4 and Request View
    Start up RSLinx with RSWho and watch to see if there are packets being exchanged
    Shut down RSLinx and startup AdvancedHMI to see if any packets are being exchanged

     
  • Bilal
    Bilal
    2012-01-13

    I used Serial Port Monitor for COM4 port  ,also got two pics for one for AdvancedHMI port monitor second one for RsLinx port monitor.

    AdvancedHMI BaudRate is AUTO but when I change to Manual like BaudRate = 9600 , VS 2010 kind of crashes.
    Serial Port Monitor shows  AdvancedHMI BaudRate = 38400 but I had changed as manual RSLinx BaudRate 9600 sure when I changed RSLinx BaudRate like 38400 doesnt work.

    I mean that this BaudRate might be our real problem?.

    Thanks anyway :)

    http://www.serial-port-monitor.com/free-serial-port-monitor-downloads.html

     
  • Archie
    Archie
    2012-01-13

    Yes! Your are right, that is the problem. It was a known issue that I had forgotten about. It has been fixed, but the fix is part of the next release. If you view the code for DF1Comm,vb at line 96, this is the code that fixes the problem:

        Private m_BaudRate As String = "AUTO"
        <EditorAttribute(GetType(BaudRateEditor), GetType(System.Drawing.Design.UITypeEditor))> _
    Public Property BaudRate() As String
            Get
                Return m_BaudRate
            End Get
            Set(ByVal value As String)
                If value <> m_BaudRate Then
                    If Not Me.DesignMode Then
                        '* If a new instance needs to be created, such as a different Com Port
                        CreateDLLInstance()

                        If DLL(MyDLLInstance) IsNot Nothing Then
                            DLL(MyDLLInstance).CloseComms()
                            Try
                                DLL(MyDLLInstance).BaudRate = value
                            Catch ex As Exception
                                '* 0 means AUTO to the data link layer
                                DLL(MyDLLInstance).BaudRate = 0
                            End Try
                        End If
                    End If
                    m_BaudRate = value
                End If
            End Set
        End Property

     
  • Bilal
    Bilal
    2012-01-14

    I've changed  code for DF1Comm.vb at line 96. VB 2010 doesnt crashes any more when I change BaudRate from AUTO to 9600. But when I run project , on MainForm "MomentaryButton for  start , PilotLight for Motor  kind of freeze ofcourse errors show  up on Buttons like "No response, check COM settings". Also , I check Com ports of RSLinx and AdvancedHMI DF1comm1 wtih Serial Port Monitor. RSLinx BaudRate is constant "BaudRate is 9600" but AdvancedHMI DF1comm1 BautdRate is not constant first is BaudRate is 9600 then BaudRate  is being changed as 38400.

    Another weird thing is, no matter what  AdvancedHMI DF1comm1 COMX port is "ex. 1,2,3.." as soon as I run project errors shows up on Buttons as "No response, check COM settings".

    So far no chance :) may be next version of AdvancedHMI will be much better for me.

    Thanks for your time,

     
  • Bilal
    Bilal
    2012-01-14

    I have said before that "The computer I use it doesn't have physical serial port instead I use PL-2303 USB-to-Serial Bridge Controller to connect my PLC."

    Have you ever tested AdvancedHMI DF1comm1 with PL-2303 USB-to-Serial Bridge Controller?. If you  have ,does it properly work with AdvancedHMI DF1comm1?. if so, Could you recommend me good USB-to-Serial converter.

    I  want to find  my mistake. I will.

    Thanks,

     
  • Bilal
    Bilal
    2012-01-15

    Hi I've finally gotten cause of mistake that made me crazy.  That was "PL-2303 USB-to-Serial Bridge Controller" converter.
    I bought new one sure not the one has "Prolific chip " .  This new " DIGITUS USB to serial adaptor, USB 2.0" realy get job done well.

    Thanks a lot sir..