Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - jbrandall

Pages: [1]
1
Technical support / Fine tuning some timing
« on: March 31, 2015, 06:42:43 PM »
I seem to have overload my FMD with too much to do and not enough time to get it done, so I am going to pair it with a Nano which will handle to most time sensitive routine with little to output.  However, the Nano will generate some numbers that the FMD will need.  So is it better for the Nano to write to the FMD or is it better to have the FMD read the Nano? (via MODBUS)  Using the Nano to write, I can control when it does so,  not true with a read by the FMD.  Does the 'writing' get done before the ladder cycle completes or after all the outputs have been set?

On a related subject; I am reading 64 variables from the FMD every 300 ms (via Host Link Protocol).  Is this affecting the ladder logic execution or are the communication functions separate from the main processor?  

I know I'm splitting hairs, but I'm getting some really strange results that can't all be blamed on 'noise'.  Thank you for any guidance anyone can provide.

2
Technical support / high speed counter
« on: July 16, 2013, 02:58:11 PM »
why does my high speed counter start to count down when input(3) pulse stop coming?  all else it seems to work ok.  I do use PMON 2 to monitor input(4).  When that stops, the counter stops counting down.  What do I do??

3
Technical support / timing issue or am I asking too much?
« on: April 04, 2013, 12:54:53 PM »
I have an FMD16-16 that is giving me fits.
Basically the plc has to monitor a shaft that is turning up to 90 RPMs and do some different things depending on other inputs.  I have an arm that passes a proximity sensor every revolution and I use the pulse period to calculate the speed of the shaft every scan.  While the shaft is making one revolution, another sensor is picking up 1 to 9 pulses very quickly. I think I have attached the program which has 31 rungs of ladder logic (not counting comments) and there are 22 custom functions which contain 55 IF/Then statements, some of which are nested.  I also read all 8 analog inputs, some 3 times quickly, as well as do several For I=1 to 10 Loops and control two PWM outputs.  Along with all that, I am asking for 64 bytes of data via a router and the hostlink protocol every 1/4 second.  I'm wondering if my problem stems from asking the processor to do all of it's work in the 2/3 of a second that it takes the shaft to turn one revolution.  What happens is that my RPM reading randomly goes way out of range and when I try to record it in memory, I sometimes get a double entry.
The problem started when I added this code: (and the function 'EndTrip' is called)
   IF juice_switch=1
      IF TESTIO(pickup) SETIO PumpOut SETPWM 2,5000,5 REM nozzle rate?
         IF injector_pump=1 SETPWM 1,7000,10 REM injector rate?
         ELSE SETPWM 1,3000,10  SETIO nozzles2 REM nozzles2 rate?
         ENDIF
      ENDIF
   ELSE CALL JuiceOff REM everthing off!
   ENDIF REM no juice

juice_switch is a DM memory location that I can toggle between 0 and 1.  pickup is input7.  Everything works fine up the point that I turn 'pickup' on WHETHER juice_switch IS ZERO OR ONE!??  Tried rewiring to input8 with the same results.  In my mind 'pickup' should not even come into play if 'juice_switch' = 0.

 I don't have a good concept of how fast a processor can do its calculations?  Is there a chance that I can't have the plc do everything I want in 2/3 of a second?  Is the PULSEPERIOD command interrupting the ladder logic?  It does recover and keep running, but the out of range RPM reading causes other problems.   How can I test this? What else could be wrong?

4
Technical support / Trying to read a pulse period on FMD16
« on: February 18, 2013, 03:04:18 PM »
I have upgraded from a nano to a FMD1616 and am trying to run a program that worked on the nano that I transfered to the FMD.  I am trying to read the pulse period on input #4 on every scan and I did do a PMON 2 on the first scan.  My statement is "temp1=PULSEPERIOD (2)" and when I monitor temp1, the numbers are all over the place, from 300 to 400,000 or more and sometimes negative.  I am using an old nano to trigger input #4 with what I believe to be a pulse every second; on for 2 tenths and off for 8 tenths.  My expectation is to see a number in temp1 around 1,000,000.  I do use input #4 to trigger other events functions.  What all am I missing??

5
Technical support / Monitoring a FMD
« on: February 01, 2013, 11:20:20 AM »
Is it just me or others having this problem:  In the past I have run several nano's and monitored them with my laptop running trilogi 6.??.  This year I had to goto FMD16-16's and upgraded to trilogi 6.45.  I'm using basically the same program as on the nano's and everything works as expected in simulation mode.  However, when I try to monitor/control the plc from my laptop, clicking on the inputs makes them act like one-shot inputs (they are not).  I see the input led light briefly, but that's it.  In the past, and in simulation mode, a left click acts like a momentary contact (on when held on and off when released), and a right click latches the input on.  Also the inputs work correctly via switches or sensors.  The problem seems to be in the monitoring program...

6
Technical support / Input #4 on FMD16-16
« on: January 20, 2013, 05:01:31 PM »
Is there something special with input #4 on the FMD 16-16?  I recently purchased 3 boards and have tried to use 2 of them with the same results:  I have two 3 wire normally open NPN proximity sensors hooked to inputs 3 and 4.  When I power up or reset the plc, if the sensors are on, input 3 works as it should, however, input 4 does not.  Both sensors indicate that they are on, and the #3 led and the #4 led are lighted on the board.  However, in monitoring mode, input #4 does not show up as on, but #3 does (as it should), nor does my program function properly.  Moving the sensor away from it's target and back corrects the problem, but this is not acceptable as sensors #4 is supposed to be on at startup and any of the other sensors could be on then.  I switched sensor wires, and the problem is still at input #4.

The sensors and the program worked on a Nano1, but I needed more inputs and outputs so I upgraded to the FMD 16-16.  I set the first FMD aside when it didn't work and tried the second.  Any suggestions on testing the third board without installing my programs on it? Any other suggestions??


7
Technical support / local file system
« on: December 20, 2012, 05:29:00 AM »
I thought I'd be a good boy and upgrade to JRE 1.4.2_19 and v6.45 from 6.41 and have done so.  Now I can't navigate to load my old files!!  I did copy an old file to C:\TRiLOGI\TL6\usr and was able to open it, but am still unable to saveas to anywhere except the usr folder.  I know that I'm dumber than a stone, but I thought I had mastered the widows file system.  WTF am I missing??

8
Technical support / Lost in MODBUS land
« on: November 27, 2011, 06:06:03 PM »
I'm having so much fun with one Nano-10 that I got another one.  Actually, I need a third analog input and everything I read says it is so easy to have the two plc's talk to each other.  Not so much for me!  What I've got so far is: nano1 and nano2 up and running and wired together via the RS485 ports with about 18" of twisted pair, negative to negative and positive to positive. They are also both hooked up to a wireless router via the RJ45 ports, but with no internet. The router is at 192.168.2.1, nano1 is at 192.168.2.5:9080, ID 01, and nano2 is at 192.168.2.6:9080, ID 02. They both use a common NPN proximity sensor to control input2 on each plc (could this be a problem?)

The programming for nano2 is that when input2 is on, it does a custom function that is:  

M= ADC(1)   REM read moisture
Input[10] = M   REM store moisture
N=Input[10]   REM for testing

This seems to work when viewed with TRiLOGI.  There is no setup routine (yet).

The programming for nano1 is that when input2 is on, it also does a custom function which is longer, but ends with:

REM hyd pressure test
P = ADC(1)  REM hyd pressure
DM[3879] = P
W = ADC(2)  REM scale pressure

REM go get moisture
M=READMODBUS(3,2,10)   (as per Modbus.PC6 sample program)

When viewed with TRiLOGI, P and W change as expected, but M stays at zero.  There is a setup routine for this nano, but nothing with SETSYSTEM or SETPROTOCOL.

My TRiLOGI manual shows the syntax as SETSYSTEM n,data - with the choices for n being 1,2,or 3 and the choices for data being 4,5,6,8, and 256.  The user's manual for the Nano-10 shows an examples of SETSYSTEM 19,0 (page 14-6), SETSYSTEM 253,n (page 12-5), and I'm sure I've seen SETSYSTEM 20,?? somewhere, but with so little information, I don't dare play with that.

I think that I want to use the RS485 port (COMM1?) but believe that the NETCMD$ function would also work.  If possible, could someone please show programming for both methods.

Thanks


Pages: [1]