connec ng epics to twincat
play

Connec&ng(EPICS(to(TwinCAT( Torsten(Bgershausen( SW(Engineer( - PowerPoint PPT Presentation

Connec&ng(EPICS(to(TwinCAT( Torsten(Bgershausen( SW(Engineer( Mo&on(Control(and(Automa&on(Group( www.europeanspalla&onsource.se( 2015E05E19( Overview( What(is(a(TwinCAT(system(?( Our(EPICS(Com(Module(for(TwinCAT(


  1. Connec&ng(EPICS(to(TwinCAT( Torsten(Bögershausen( SW(Engineer( Mo&on(Control(and(Automa&on(Group( www.europeanspalla&onsource.se( 2015E05E19(

  2. Overview( • What(is(a(TwinCAT(system(?( • Our(EPICS(Com(Module(for(TwinCAT( • Using(StreamDevice(–(Chopper((spinning(disc)( • Using(MotorRecord(–(Linear(axis( • Ongoing(developments( ( (

  3. TwinCAT:(a(soU(PLC(system( PC( SW( “SoU(PLC”( “real&me”( Fieldbus( IO( IO( IO( IO(

  4. Connec&ons(to(TwinCAT( TwinCAT( real(&me( (kernel( ADS( PLC( Mo&on( OPC( FB_DriveVirtual( Ethercat(master( COM( winsock( Motor( Encoder,(switches( EPICS(IOC( Control(network:(EPICS(channel(access(

  5. EPICS(Com(Module( EPICS(Com( TwinCAT( real(&me( Module( ADS(Router( (kernel( (real&me(under( PLC( Mo&on( ( ((TwinCAT)( FB_DriveVirtual( Ethercat(master( winsock( Motor( Encoder,(switches( EPICS(IOC(

  6. ASCII(data( Low(level(debugging( $(telnet(192.168.88.48(200( Main.M1.bBusy?;\r\n( 0;\r\n( EPICS(TwinCAT( “Main.M1.fPosi&on=10.0;\n”( IOC( TwinCAT( StreamE( System( “OK;\n”( Device( 6(

  7. Disc(synchronized(with(the(14(Hz(pulse:( Baby(Chopper( 7(

  8. Chopper(Control(Demo( 8(

  9. Chopper(Control(Service(Mode( 9(

  10. MotorRecord::(move()( • TwincatMotorAxis::move(double(posi&on,(int( rela&ve,(double(minVelocity,(double(maxVelocity,( double(accelera&on)( • {(/*(status(checking(not(shown(*/( • ((stopAxisInternal();( • ((setValueOnAxis("nCommand”,(rela&ve(?(2(:(3);( • ((setValueOnAxis("fPosi&on",(posi&on);( • ((sendVelocityAndAccelExecute(maxVelocity);( • }( 10(

  11. Single(Axis( 11(

  12. Ongoing(developments(E(1( • Single(transac&on:(chain(commands( “Main.M1.bBusy?;Main.M1.fActPosition?;\n” 
 “0;11.417835;\n” " • Retrieving(complete(motor(status(as(a(struct( “Main.M1.stAxisStatus?;\n”( “Main.M1.stAxisStatus:(1=0,(2=0,(3=0,(4=0,( 5=0,6=0.000000,7=0.000000,8=0.000000,9=0.000000,(10=0,( 11=0,12=1,(13=1,14=0.000000,15=0,…;\n”( • Read(the(“RAW”(encoder(value:( ( ADR=16#3040020,16#80000049,2,18/ ADSPORT=501/?; " ( 12(

  13. Mo&on(Control(E(TODO( • Op&mize( • More(homing(procedures( E Implement(in(the(mo&on(control(unit((MCU)( E Expose(them(via(EPICS(?( • (configura&on(parameters(( E(Which(are(needed(in(the(MCU(( E(which(need(to(be(exposed(via(EPICS(?( ( (((Accelera&on,(Jerk,(SoU(limits)( • ((Health(status/alarms(( E(Internal(alarms(from(the(MCU( • More(automated(tes&ng( – python(based,(pyEpics,(nose( ( ( 13(

  14. Thanks( • Anders(Sandström,(MCAG( • EPICS(community( ( • Ques&on(s)(?( 14(

Recommend


More recommend