background image

Contatto

MCP 4 – User's manual

DUEMMEGI

R

160

170

180

190

200

210

220

230

240

250

260

270

280

290

300

310

000

2208

2218

2228

2238

2248

2258

2268

2278

2288

2298

2308

2318

2328

2338

2348

2358

001

2209

2219

2229

2239

2249

2259

2269

2279

2289

2299

2309

2319

2329

2339

2349

2359

002

2210

2220

2230

2240

2250

2260

2270

2280

2290

2300

2310

2320

2330

2340

2350

2360

003

2211

2221

2231

2241

2251

2261

2271

2281

2291

2301

2311

2321

2331

2341

2351

2361

004

2212

2222

2232

2242

2252

2262

2272

2282

2292

2302

2312

2322

2332

2342

2352

2362

005

2213

2223

2233

2243

2253

2263

2273

2283

2293

2303

2313

2323

2333

2343

2353

2363

006

2214

2224

2234

2244

2254

2264

2274

2284

2294

2304

2314

2324

2334

2344

2354

2364

007

2215

2225

2235

2245

2255

2265

2275

2285

2295

2305

2315

2325

2335

2345

2355

2365

008

2216

2226

2236

2246

2256

2266

2276

2286

2296

2306

2316

2326

2336

2346

2356

2366

009

2217

2227

2237

2247

2257

2267

2277

2287

2297

2307

2317

2327

2337

2347

2357

2367

R

320

330

340

350

360

370

380

390

400

410

420

430

440

450

460

470

000

2368

2378

2388

2398

2408

2418

2428

2438

2448

2458

2468

2478

2488

2498

2508

2518

001

2369

2379

2389

2399

2409

2419

2429

2439

2449

2459

2469

2479

2489

2499

2509

2519

002

2370

2380

2390

2400

2410

2420

2430

2440

2450

2460

2470

2480

2490

2500

2510

2520

003

2371

2381

2391

2401

2411

2421

2431

2441

2451

2461

2471

2481

2491

2501

2511

2521

004

2372

2382

2392

2402

2412

2422

2432

2442

2452

2462

2472

2482

2492

2502

2512

2522

005

2373

2383

2393

2403

2413

2423

2433

2443

2453

2463

2473

2483

2493

2503

2513

2523

006

2374

2384

2394

2404

2414

2424

2434

2444

2454

2464

2474

2484

2494

2504

2514

2524

007

2375

2385

2395

2405

2415

2425

2435

2445

2455

2465

2475

2485

2495

2505

2515

2525

008

2376

2386

2396

2406

2416

2426

2436

2446

2456

2466

2476

2486

2496

2506

2516

2526

009

2377

2387

2397

2407

2417

2427

2437

2447

2457

2467

2477

2487

2497

2507

2517

2527

R

480

490

500

510

520

530

540

550

560

570

580

590

600

610

620

630

000

2528

2538

2548

2558

2568

2578

2588

2598

2608

2618

2628

2638

2648

2658

2668

2678

001

2529

2539

2549

2559

2569

2579

2589

2599

2609

2619

2629

2639

2649

2659

2669

2679

002

2530

2540

2550

2560

2570

2580

2590

2600

2610

2620

2630

2640

2650

2660

2670

2680

003

2531

2541

2551

2561

2571

2581

2591

2601

2611

2621

2631

2641

2651

2661

2671

2681

004

2532

2542

2552

2562

2572

2582

2592

2602

2612

2622

2632

2642

2652

2662

2672

2682

005

2533

2543

2553

2563

2573

2583

2593

2603

2613

2623

2633

2643

2653

2663

2673

2683

006

2534

2544

2554

2564

2574

2584

2594

2604

2614

2624

2634

2644

2654

2664

2674

2684

007

2535

2545

2555

2565

2575

2585

2595

2605

2615

2625

2635

2645

2655

2665

2675

2685

008

2536

2546

2556

2566

2576

2586

2596

2606

2616

2626

2636

2646

2656

2666

2676

2686

009

2537

2547

2557

2567

2577

2587

2597

2607

2617

2627

2637

2647

2657

2667

2677

2687

R

640

650

660

670

680

690

700

710

720

730

740

750

760

770

780

790

000

2688

2698

2708

2718

2728

2738

2748

2758

2768

2778

2788

2798

2808

2818

2828

2838

001

2689

2699

2709

2719

2729

2739

2749

2759

2769

2779

2789

2799

2809

2819

2829

2839

002

2690

2700

2710

2720

2730

2740

2750

2760

2770

2780

2790

2800

2810

2820

2830

2840

003

2691

2701

2711

2721

2731

2741

2751

2761

2771

2781

2791

2801

2811

2821

2831

2841

004

2692

2702

2712

2722

2732

2742

2752

2762

2772

2782

2792

2802

2812

2822

2832

2842

005

2693

2703

2713

2723

2733

2743

2753

2763

2773

2783

2793

2803

2813

2823

2833

2843

006

2694

2704

2714

2724

2734

2744

2754

2764

2774

2784

2794

2804

2814

2824

2834

2844

007

2695

2705

2715

2725

2735

2745

2755

2765

2775

2785

2795

2805

2815

2825

2835

2845

008

2696

2706

2716

2726

2736

2746

2756

2766

2776

2786

2796

2806

2816

2826

2836

2846

009

2697

2707

2717

2727

2737

2747

2757

2767

2777

2787

2797

2807

2817

2827

2837

2847

Page 84 of 87

Rel.: 1.2 October 2018

DUEMMEGI

 s.r.l. - Via Longhena, 4 – 20139 MILANO

Tel. 02/57300377 - Fax 02/55213686 – 

www.duemmegi.it

Содержание Contatto MCP 4

Страница 1: ...DUEMMEGI Contatto Contatto Contatto MCP 4 MCP 4 Programmable Control Module User s Manual Release 1 2 October 2018 Via Longhena 4 20139 MILANO Tel 02 57300377 FAX 02 55213686 www duemmegi it...

Страница 2: ...rk 15 2 1 13 Scheduler 16 2 2 Event triggered Equations 17 2 2 1 Logic equations 17 2 2 2 SET RESET equations 17 2 2 3 TOGGLE equations 18 2 2 4 COUNTER Equations 18 2 2 5 THRESHOLD Equations 20 2 2 6...

Страница 3: ...software package 60 10 2 MCP IDE 60 10 2 1 MCP IDE 64 10 2 2 Program transferring 64 10 3 MCP VISIO 65 10 3 1 The Groups of MCP VISIO 66 10 3 2 The Projects of MCP VISIO 69 10 3 3 The Simulator of MCP...

Страница 4: ...ns Standards and regulations The design and the setting up of electrical systems must be performed according to the relevant standards guidelines specifications and regulations of the relevant country...

Страница 5: ...d continues to operate without interruption only when downloading of the new program is completed and if everything goes well the automatic switch from the old program to the new one will be performed...

Страница 6: ...itialization of Ethernet interface V2018 activated when a communication loss on COM4 RS485 occurs for more than 5 seconds V2017 activated when one or more MODBUS slaves do not answer to MCP 4 set in M...

Страница 7: ...2 point 2 of channel 1 of output module 3 AO15 1 channel 1 of output module 15 AI20 2 channel 2 of input module 20 R12 register R12 R14 5 bit 5 of register R14 for script only V100 virtual point 100...

Страница 8: ...V1 V16 1 V17 V32 R12 means that R12 maintains the value before the power down RAM has a battery for back up AO16 AO17 247 means that outputs AO16 channel 1 channel 2 channel 3 channel 4 and AO17 chann...

Страница 9: ...s a SLAVE device in a MODBUS network Alternatively the MODBUS MASTER mode can be activated for MCP 4 exclusively on COM4 using the following directive MODBUS a T Vm Wx n Ry where a is the address in t...

Страница 10: ...le Registers The words read written are those mapped from WORD 0000 to 9998 in the slave If the specified WORD number is in the range 50001 to 65535 MCP4 performs reading via function 3 Read Holding R...

Страница 11: ...ted to the sunrise time in the range 127 to 127 and the optional register reporting the calculated sunrise time SUNSET minutes to be added or subtracted to the sunset time in the range 127 to 127 and...

Страница 12: ...the first 32 registers of MCP 4 SHARE V1025 V1152 SHARE V1153 V1280 SHARE R0 R7 SHARE R8 R15 SHARE R16 R23 SHARE R24 R31 2 1 9 Management of fault modules Assign a virtual point to the failure conditi...

Страница 13: ...e allowed 2000 virtual points 0 registers 1000 virtual points 62 registers 512 virtual points 93 registers 0 virtual points 125 registers In other words the number of virtual points divided by 16 adde...

Страница 14: ...published by the other components of the same network even if it does not contain any NETWORK directive the data exchange mechanism here described also applies between Contatto MCP 4 controllers and...

Страница 15: ...ormation by all the components or nodes of the network needs a sure time Due to the particular management of the mechanism to access to the network this time can be optimized instructing each MCP 4 ab...

Страница 16: ...with 8 time slots 8 ON OFF intervals for each day of the week The resolution of the Scheduler is 1 minute The Scheduler will be activated by the following directive SCHEDULER n Vx where n is the Sched...

Страница 17: ...RESET priority on the level O1 1 SI1 1 RI1 2 Set Reset edge triggered O1 1 SI1 1 RI1 2 Set Reset edge triggered O1 1 SI1 1 RLI1 2 Reset on the level out is locked OFF if I1 2 is activated O1 1 SPLI1...

Страница 18: ...virtual inputs each one with its own specific function 1 one or more inputs for forward or backward counting S k 2 one or more inputs for the zeroing or to load the counter with a defined value P z PP...

Страница 19: ...ding the underflow or the overflow of the counter MIN is the minimum value that can be assumed by the counter the default value is 0 MAX is the maximum value that can be assumed by the counter the def...

Страница 20: ...Hysteresis must be in the range 0 to 65535 Other allowable operators AND and OR Examples O1 1 AI1 240 2 V2 AI1 40 AI2 30 V2 AI1 40 5 O1 4 AI1 128 AI1 30 O1 5 AI1 600 R50 30 O1 1 AI1 R51 R52 AI1 1000...

Страница 21: ...Equations for mathematical and logic calculation Allowed MATH and LOGIC operators MATH LOGIC Symbol Function Symbol Function Sum AND Subtract OR Multiply XOR divide P Preset Preset options P Preset on...

Страница 22: ...When V1 goes ON only the value 20 will be sent to the output because it is a Preset on level AO1 1 P 10 V1 PL 20 V1 P 30 V1 When V1 goes ON only the value 10 will be sent to the output because it is...

Страница 23: ...ents are stored has the battery back up feature therefore the events remain stored even if the main supply voltage fails at least until the battery does not reach the minimum retaining voltage of the...

Страница 24: ...be stored in the RAM of MCP 4 since the section of the RAM where these events are recorded has the battery back up feature the values remain stored even if the main supply voltage fails at least unti...

Страница 25: ...ed if the counting is greater or equal to 100 The input I1 1 when activated will reset the counter to 0 V10 AI10 4 R0 The virtual point V10 will be activated if the counting of the channel 4 of ModCNT...

Страница 26: ...s Example AO1 2 DALI G1 AI44 2 Send AI44 2 to Group 1 G2 R1 Send R1 to Group 2 G3 R1 10 Send R1 incremented by 10 to Group 3 G4 R1 10 Send R1 decremented by 10 to Group 4 B1 AI45 2 Send AI45 2 to Ball...

Страница 27: ...1440 hh x 60 mm Variable yearly dates specified in a register Rx or in a Word WORD x containing a number in the range 1 to 372 corresponding to the day of the year starting from January 1 372 Decembe...

Страница 28: ...l be ON every week from Monday 11 15 to Friday 17 00 O1 1 CLOCK WORD32770 WORD32771 As the previous equation but time are specified by the shown Words O1 1 DATE R0 XX R1 XX Switching ON every year at...

Страница 29: ...RO definition that are variable parameters because they change from a call to the other one cannot have the same names reserved to the parameters or the keywords of MCP 4 The following example defines...

Страница 30: ...3 I2 4 V12 C5 R 1 P 129 I2 3 P 130 I2 4 P 128 V11 AO6 R5 This example well clarify how to use the MACRO utility to execute block of repetitive equations where only some parameters change In addition a...

Страница 31: ...w or if the result of the previous operation is negative underflow or if a division by 0 occurred the value of this bit is 0 in all other cases ZERO bit flag whose value is 1 if the result of the prev...

Страница 32: ...ollowed by a number in the range 1 to 127 The keyword TRIGGER specifies the event triggering the execution of the script or every how many time it must be executed The events triggering the scripts ca...

Страница 33: ...s a script that the variable has been declared in another script In the following example the variable TEMP1 is declared as local both for script 1 and for script 2 while the variable is shared by bot...

Страница 34: ...nstruction included between ELSE and ENDIF will be executed Each IF block must be always closed by an ENDIF which is mandatory on the contrary to ELSE which is optional The condition of the block IF T...

Страница 35: ...w or if a division by 0 occurred The ZERO flag value is 1 if the result of the previous operation is zero The following SCRIPT shows the use of these flags script 1 trigger 2 R0 R1 R2 somma R1 R2 if C...

Страница 36: ...lue equals one of the moments when the light brightness must be changed the two instructions RAMP1 K and PERC1 Z will be executed the effect of this instructions that are identical to A01 K and A01 Z...

Страница 37: ...in a direct mode The following rule is always true Use CALL if the subroutine after the calling does not return any value Call directly the function if after the calling it must return a value At ever...

Страница 38: ...tant value R100 CALCULATE R10 R11 function to which 2 parameters are passed and which will return a value copied in R100 The parameter R11 will be passed as reference therefore the function can change...

Страница 39: ...n be achieved also using the following script where the destination registers will be passed as reference and therefore the subroutine works directly on them Prefer however the version of the previous...

Страница 40: ...T x must be used in subroutines or functions only The declaration BIT X must be placed in the subroutine declaration ONLY The following script uses a function having as input parameters a value REG an...

Страница 41: ...vious two examples This script uses a function having as input parameters a value REG and a bit ENABLE therefore declared by BIT ENABLE the function returns a bit TEST therefore declared by BIT TEST R...

Страница 42: ...umber of register R0 The notation ptr inside square brackets returns the content of the pointed register In the following script the R15 value will be increased by 1 every time the content of each reg...

Страница 43: ...by notations as Cx Ry etc and they are an option to the pointer method described before 3 2 12 SWAP x The SWAP x function exchange the high byte with the low byte of the specified Word x The Word can...

Страница 44: ...oint the subroutine executes the OR between the Word containing the point and the mask which as said contains only one bit set to 1 at the position of the bit related to the desired point To reset the...

Страница 45: ...ical utility to display the status of the plant input and output modules counters virtual points registers etc a simulator to verify the written program or a part of it before to transfer it into MCP...

Страница 46: ...tion define Command I1 1 Input definition Pump1 Command Equation The previous equation is fully equivalent to O1 1 I1 1 but it can be easily interpreted The variable names defined through the define d...

Страница 47: ...CP 4 memory 4 3 Uploading the program to MCP 4 memory Last step of MCP 4 programming process is the uploading to its flash MEMORY of the binary file containing the system configuration and the program...

Страница 48: ...Following figures show the proper connections to be made and the description of the terminals note that terminal 17 must be left unconnected Connections of MCP module ETH 24V BUS 0V L1 L2 RS485 RS485...

Страница 49: ...s Read to read the current MCP 4 setting for the Baud Rate on RS 232 and RS485 ports The other three parameters Wait Time are the delay time before the answer of MCP 4 to a Host request these wait tim...

Страница 50: ...ation The Read button allows to report the MCP4 ETH current configuration and its MAC address 2 Via LAN network and browser MCP4 ETH has the factory settings as shown in the figure above particularly...

Страница 51: ...of device that can be connected on RS485 line must be limited to 32 5 5 WEBS communication port MCP 4 features a special communication port COM3 under the terminal cover on the bottom left side see fo...

Страница 52: ...d addresses the doubled modules are displayed on the screen in yellow color The doubled addresses signaling however cannot be assured because if the answer of the two modules is exactly superimposed e...

Страница 53: ...channel Available communication ports 1 x RS232 opto coupled 2 x RS485 opto coupled 1 x dedicated port 1 x Ethernet port optional Peripheral devices handling Touch screen video terminals Bus display w...

Страница 54: ...ata1 DataN Writing to RAM memory of N bytes 1 252 starting from address specified by the first 3 data bytes Note 1 0x7D 4 Add_U Add_H Add_L N Reading from microcontroller memory of N bytes 1 255 start...

Страница 55: ...e Mod_Addr Data7 Data8 CH4 of module Mod_Addr 0x7A 8 256 Data1 Data Nx8 Answer to reading message of N 1 32 input modules starting from address module Mod_Addr The answer contains Nx8 bytes in the dat...

Страница 56: ...d from the MCP 4 timekeeper chip 1 Monday 2 Tuesday 7 or 0 Sunday Note 3 0F08 0F09 1924 Day of the month in BCD format Read from the MCP 4 timekeeper chip Note 3 0F0A 0F0B 1925 Month in BCD format Rea...

Страница 57: ...ddress 0 STATUS 0 means BUS OK 5 SYS F 1 Module_Address 0 STATUS 1 means MOD F 6 SYS F 1 Module_Address 0 STATO 0 means MOD OK 7 The symbol means not used Note 5 The list of analog events values or co...

Страница 58: ...installed The information are organized in one byte for each MODCNT module with offset Module_Address as follows offset 0 Byte 0xEB00 not used offset 1 Byte 0xEB01 input module MODCNT 1 offset 2 Byte...

Страница 59: ...0A23 1297 Scheduler number Sx Writing a value 1 to 16 in this Word MCP 4 will copy the data of the day Dy of the schedule Sx in the Words 1280 1296 8 scheduling times ON OFF Enabling 0A24 0A25 1298 Da...

Страница 60: ...s tool can work connected to MCP 4 through the serial port or it can simulate the program written by MCP IDE in order to debug it before the writing into MCP 4 FLASH memory MCP MAP is an advanced tool...

Страница 61: ...on or the menu item View Show Keywords List is the life belt and it allows to switch ON or OFF the opening of a space on the right side containing all the keywords allowed in the related TAB When Conf...

Страница 62: ...riting the standard equation of MCP 4 The Macros workspace allows writing the Macro definitions The Script workspace allows writing the Scripts Page 62 of 87 Rel 1 2 October 2018 DUEMMEGI s r l Via Lo...

Страница 63: ...after compiling information about the resources used in the just compiled program The Decompiling workspace read only is reserved to expert user and contains after de compiling information about how t...

Страница 64: ...nd the messages on the Ethernet port of the PC where it has been installed instead to RS232 port The answer of MCP 4 afterward will follow the reverse way Use Server Name allows to specify an address...

Страница 65: ...ts registers counters timers and events both digital and analog ones The reading setting window opened by the butto n looks like in the figure on this right side The clock panel shows Hours Minutes Se...

Страница 66: ...ts From MCP create a group for all configured Output Modules Load Mixed Module from MCP create a group for all configured Mixed Modules Through these functions the module configured in MCP 4 will be s...

Страница 67: ...ual point Click on the right side of each LED while holding down the Shift button on the keyboard to assign a label to the related point Finally click on the white band on the lower side of the virtua...

Страница 68: ...the module itself while holding down the Ctrl button on the keyboard To paste the module from the Clipboard to a group press the button in the destination group Each group can be saved or updated in...

Страница 69: ...MCP 4 program or part of it The simulator is a fully software tool therefore no serial connection to MCP 4 is required The simulator shows the behavior of the output parameters of a program e g real a...

Страница 70: ...ated paragraph To localize the input and output points virtual points registers etc refer to the external RAM memory described in a previous chapter or better refer to the tables listed in the followi...

Страница 71: ...he real module of Contatto system starting from which the status of the outputs has to be read and CH the channel then the value of Start will be Add x 16 2048 x CH 1 Allowed values from 0 to 8176 how...

Страница 72: ...alue is suggested to be multiple of 16 and equal to the number of modules to be read multiplied by 16 Allowed values from 16 to 8176 MCP 4 will answer with a number of bytes equal to Number divided by...

Страница 73: ...hose most significant byte is zero and the less significant byte is contains the status of the output points of module 25 in binary code 1 out ON 0 out OFF The less significant bit is related to the o...

Страница 74: ...lue is the module 16 of the starting number this result is always an integer number in the range 0 to 7 The parameters to be passed to the MODBUS driver for virtual point V328 are Start 1173 Number 1...

Страница 75: ...The function 16 is more used than the function 6 The following parameters have to be specified Number this value is the Word address where the new value has to be written Allowed values for Number fro...

Страница 76: ...r Start 541 Number 1 normally in this case this parameter is not required by the driver Bit 2 Value 1 or ON it depends on the used driver Note the point 3 of an output module correspond to bit 2 of th...

Страница 77: ...procedure however is normally executed automatically by the MODBUS driver of the MASTER system Example 4 Write the value 157 into counter C22 remember that for the Contatto system the counter are num...

Страница 78: ...been used see description of the PROTOCOL directive All numbers in the tables are in decimal format As option DUEMMEGI provides free of charge a small program named WordFinder which immediately gives...

Страница 79: ...216 226 236 246 009 137 147 157 167 177 187 197 207 217 227 237 247 Channel 3 IN 000 010 020 030 040 050 060 070 080 090 100 110 120 000 266 276 286 296 306 316 326 336 346 356 366 376 001 257 267 277...

Страница 80: ...758 009 649 659 669 679 689 699 709 719 729 739 749 759 Channel 3 OUT 000 010 020 030 040 050 060 070 080 090 100 110 120 000 778 788 798 808 818 828 838 848 858 868 878 888 001 769 779 789 799 809 81...

Страница 81: ...44 V360 V376 V392 V408 V424 V440 V456 V472 V488 V504 Bit 8 V265 V281 V297 V313 V329 V345 V361 V377 V393 V409 V425 V441 V457 V473 V489 V505 Bit 9 V266 V282 V298 V314 V330 V346 V362 V378 V394 V410 V426...

Страница 82: ...1065 V1081 V1097 V1113 V1129 V1145 V1161 V1177 V1193 V1209 V1225 V1241 V1257 V1273 Bit 9 V1034 V1050 V1066 V1082 V1098 V1114 V1130 V1146 V1162 V1178 V1194 V1210 V1226 V1242 V1258 V1274 Bit 10 V1035 V1...

Страница 83: ...7 V2003 V2019 Bit 3 V1796 V1812 V1828 V1844 V1860 V1876 V1892 V1908 V1924 V1940 V1956 V1972 V1988 V2004 V2020 Bit 4 V1797 V1813 V1829 V1845 V1861 V1877 V1893 V1909 V1925 V1941 V1957 V1973 V1989 V2005...

Страница 84: ...2427 2437 2447 2457 2467 2477 2487 2497 2507 2517 2527 R 480 490 500 510 520 530 540 550 560 570 580 590 600 610 620 630 000 2528 2538 2548 2558 2568 2578 2588 2598 2608 2618 2628 2638 2648 2658 2668...

Страница 85: ...3 3153 3163 3173 3183 3193 3203 3213 3223 002 3074 3084 3094 3104 3114 3124 3134 3144 3154 3164 3174 3184 3194 3204 3214 3224 003 3075 3085 3095 3105 3115 3125 3135 3145 3155 3165 3175 3185 3195 3205...

Страница 86: ...3611 3621 3631 3641 3651 3661 3671 3681 3691 3701 3711 C 640 650 660 670 680 690 700 710 720 730 740 750 760 770 780 790 000 3712 3722 3732 3742 3752 3762 3772 3782 3792 3802 3812 3822 3832 3842 3852...

Страница 87: ...4084 4094 003 4035 4045 4055 4065 4075 4085 4095 004 4036 4046 4056 4066 4076 4086 005 4037 4047 4057 4067 4077 4087 006 4038 4048 4058 4068 4078 4088 007 4039 4049 4059 4069 4079 4089 008 4040 4050 4...

Отзывы: