===== Change Pump Example ===== Charge pump output can be easily implemented in the Software PLC. To do it - Goto the "Software PLC" \\ \\ {{mycnc:plc:mycnc-charge-pump-001.png}} \\ \\ - Press "Add" to add new PLC procedure \\ \\ {{mycnc:plc:mycnc-charge-pump-002-1.png}} \\ \\ - Enter the procedure filename (CHARGE_PUMP), press "OK" button \\ \\ {{mycnc:plc:mycnc-charge-pump-002.png}} \\ \\ - Enter source code for change pump \\ \\ main() { n=0; port=0; do{ n++; if (n&1) { portset(port); } else {portclr(port);}; }while(1); exit(99); }; \\ \\ {{mycnc:plc:mycnc-charge-pump-004.png}} \\ \\ - Press buttons "Save" and "Build" \\ \\ {{mycnc:plc:mycnc-charge-pump-005.png}} \\ \\ Output pin defined "port" variable will start pulse generation. .... port=0; .... The result oscillogram is shown below {{mycnc:plc:mycnc-charge-pump-006.png?800}}