Timotheos

MrPLC Member
  • Content count

    5
  • Joined

  • Last visited

Community Reputation

0 Neutral

About Timotheos

  • Rank
    Newbie

Contact Methods

  • ICQ 0
  1. Hi guys, Check out this link too which has a pretty cool timeline of AB PLCs. http://www.rockwellautomation.com/ab100yea...LC_25_Years.pdf Does it look like the picture on this page? I'd love to see the picture you have. I've been doing some research on PLC history. The PDQ II and PMC were Allen Bradley's first attempts that really didn't take off. The Modicon 084 was "the PLC" at the time. Later in 1974 ABs Bulletin 1774 PLC laid the groundwork for their success. The patent is actually online at http://www.freepatentsonline.com/3942158.pdf Tim
  2. data logging

    Here's the subroutine I use to copy the data to a new worksheet and then start over. My main sheet is called Log and any ones that are created get datetime stamped. I have a variable intRowIndex which keeps track of how many rows have been filled in. I usually trigger this when a sheet is full but you could easily set something up to if rows = 6 then run this subroutine. Hope that helps, Tim Sub CopySheet()         Dim strRowRange As String Dim intMaxColumns As Integer Dim intColumn As Integer On Error GoTo ErrorCopySheet    'Find the number of columns    intMaxColumns = 3 'Initialize the start    'Loop until the column is empty    Do While Sheet1.Cells(1, intMaxColumns).Formula <> ""        If Sheet1.Cells(2, intMaxColumns).Value = "" Then Sheet1.Cells(2, intMaxColumns).Value = 1        intMaxColumns = intMaxColumns + 1    Loop            'Copy what's in the sheet        Sheet1.Range(Cells(3, 1), Cells(intRow + intRowOffset, intMaxColumns - 1)).Copy                'Make a new sheet and rename it        Sheets.Add after:=Worksheets(Worksheets.Count)        ActiveSheet.Name = Month(Now) & "." & Day(Now) & "." & Year(Now) & " Log " & Worksheets.Count - 2        'Paste in the values from the main sheet        ActiveSheet.Range("A1").PasteSpecial                    'Format the columns to auto fit            intColumn = 1            For intColumn = 1 To intMaxColumns                Columns(intColumn).Select                Selection.Columns.AutoFit                ActiveSheet.Cells(1, 1).Select            Next intColumn                'Go back to the main sheet        Worksheets("Log").Select        ActiveSheet.Cells(intRowOffset, 1).Select                'Clear the content of the main sheet and reinitialize        strRowRange = intRowOffset & ":" & intRow + intRowOffset        Sheet1.Rows(strRowRange).ClearContents        ThisWorkbook.Worksheets("Row").Cells(1, 1).Value = 0        intRow = 0         Exit Sub ErrorCopySheet:    MsgBox "Whoops!", vbCritical, "Error" Exit Sub End Sub
  3. data logging

    Hi Dale, For the time interval try this... 'string holding polling interval (i.e. 1:00 = 1 minute) 'this could be set in a form or a cell dim strPollIntervall 'Schedule the next poll time NextTime = Now + TimeValue(strPollInterval) Application.OnTime NextTime, "LoggingFunction" Tim
  4. Just a quick note. The Up/Down Counter (UDC) uses a double word so it can go to 99999999.
  5. Sounds like a great project to learn PLCs. I think the AD manuals are really good. I'd start by downloading the 05 manual from their web site and start perusing their instruction set. There's a good section on Modbus with code examples.