Fadal 4020 upgrade

euroflo
Posts: 25
Joined: Wed Dec 19, 2018 8:23 pm

Re: Fadal 4020 upgrade

Post by euroflo »

mate I am trying to change the colours inside the buttons of the X,Y,Z, so it looks like my original screen is this the place to change them cnc-screen...???

"xp" name="glview" type="glview" position="80;80" width="930" height="395"
singlepath="no" bgColor="##b-ncview"
ColorT0="white:1" ColorT1="#00DD00:1" ColorT2="#0000DD:1" ColorT3="#DDDD00:1"
ColorT4="#00DDDD:1" ColorT5="#00DD00:1" ColorT6="#DD5500:1"
HColorT0="transparent:0" HColorT1="#DD0000:3" HColorT2="#0000DD:3" HColorT3="#DDDD00:3"
HColorT4="#DD00DD:3" HColorT5="#00DD00:3" HColorT6="#DD5500:3" ></gitem>

euroflo
Posts: 25
Joined: Wed Dec 19, 2018 8:23 pm

Re: Fadal 4020 upgrade

Post by euroflo »

i sort of figured it out, are you using the art work to go onto the buttons.?

mycnc
Posts: 1049
Joined: Thu May 10, 2018 2:42 pm
Location: Ottawa, Canada
Contact:

Re: Fadal 4020 upgrade

Post by mycnc »

Inputs/outputs definition should be added to pins.h header file of Hardware PLC

Code: Select all

#define OUTPUT_SPINDLE			14
#define OUTPUT_CCW_SPINDLE	13
#define OUTPUT_LOW_SPINDLE_SPEED	 7
#define OUTPUT_LOCK_SPINDLE_ORIENTATION		4
#define INPUT_SPINDLE_POSITION
#define OUTPUT_TURRET_EXTEND1		6
#define OUTPUT_TURRET_EXTEND2		2
#define OUTPUT_DRAWBAR_LOCK			12

mycnc
Posts: 1049
Joined: Thu May 10, 2018 2:42 pm
Location: Ottawa, Canada
Contact:

Re: Fadal 4020 upgrade

Post by mycnc »

For the last screen styles, colours defined in XML files and SVG icon colour can be "indexed" colours.
Colour names started with symbols "##" in XML configuration files are replaced inside the software by colours configured in the software "Colors" dialog.
About the same is for SVG colours. Color range from #abcde0 to #abcdef are replaced on the fly in the software when the software starting.

No need to change SVG icons, and XML files, just change indexes in "Colors" dialog to get a new palette.

Like this -
mycnc-profiles--39.png
mycnc-profiles--38.png
mycnc-profiles--37.png

mycnc
Posts: 1049
Joined: Thu May 10, 2018 2:42 pm
Location: Ottawa, Canada
Contact:

Re: Fadal 4020 upgrade

Post by mycnc »

euroflo wrote:
Sat Jan 05, 2019 12:04 am
mate I am trying to change the colours inside the buttons of the X,Y,Z, so it looks like my original screen is this the place to change them cnc-screen...???

"xp" name="glview" type="glview" position="80;80" width="930" height="395"
singlepath="no" bgColor="##b-ncview"
ColorT0="white:1" ColorT1="#00DD00:1" ColorT2="#0000DD:1" ColorT3="#DDDD00:1"
ColorT4="#00DDDD:1" ColorT5="#00DD00:1" ColorT6="#DD5500:1"
HColorT0="transparent:0" HColorT1="#DD0000:3" HColorT2="#0000DD:3" HColorT3="#DDDD00:3"
HColorT4="#DD00DD:3" HColorT5="#00DD00:3" HColorT6="#DD5500:3" ></gitem>
For 2D Visualisation, we made "Tool highlighting".
It's possible to define a colour for each tool number.
You may have a marking tool and plasma cutting tool on plasma cutting table.
For tangential knife cutters, customers have a knife, creasing wheel, spindle, half-knife, marking pen etc. They like this feature.

mycnc
Posts: 1049
Joined: Thu May 10, 2018 2:42 pm
Location: Ottawa, Canada
Contact:

Re: Fadal 4020 upgrade

Post by mycnc »

euroflo wrote:
Fri Dec 28, 2018 5:15 am
M06 procedure will need to go something like this..
move Z to 0.00 ( Z to tool change height)

Code: Select all

G90 G53 G0 Z0 (Move to machine Z=0)
euroflo wrote:
Fri Dec 28, 2018 5:15 am
output 7 ON ( low range spindle speed)

output 4 ON ( spindle orientation locking arm into position)

output 14 ON ( spindle CW ) 10 RPM wait until input 4 is active ( spindle position switch) then turn spindle OFF. ( on this machine it has a direction switch CW (14) or CCW (13) and DAC 0-10V )

turn output 6 and 2 ON ( turret extend) wait for input 2 ON then turn OFF 6+2. ( I think we should have a timer here say 3 secs, then if input 2 does not come ON it should do an emergency stop and show a warning that there is a ATC Fault )

output 12 ON ( drawbar locking solenoid ) wait 2 secs

Code: Select all

M601
euroflo wrote:
Fri Dec 28, 2018 5:15 am
then move Z +150mm

Code: Select all

G90 G53 G0 Z150 
euroflo wrote:
Fri Dec 28, 2018 5:15 am
next rotate the turret to the next tool either CW or CCW depending on position. Turrent CW is output 9 CCW is output 9+8
use input 3 to count the position or turret/tool. ( We may need a delay/gain here to adjust the timing of the motor on the turret)

Code: Select all

M610

euroflo wrote:
Fri Dec 28, 2018 5:15 am
once tool is in position move Z to 0.00

Code: Select all

G90 G53 G0 Z0 
euroflo wrote:
Fri Dec 28, 2018 5:15 am
turn output 12 OFF ( drawbar lock )

turn output 2 ON ( turret retract) wait for input 1 to come ON to signal ATC home. ( I think a timer here as well )

turn output 4 OFF ( orientation locking arm retract)

Code: Select all

M602
euroflo wrote:
Fri Dec 28, 2018 5:15 am
use new tool offsets .........end of M06...

Code: Select all

G10 L81 P5400 Q5409

A complete M6 macro is

Code: Select all

G90 G53 G0 Z0 (Move to machine Z=0)
M601 (ATC Stage 1)
G90 G53 G0 Z150 (Move to machine Z=150)
M610 (ATC rotate to the next tool)
G90 G53 G0 Z0 (Move to machine Z=0)
M602 (ATC Stage 2)
G10 L81 P5400 Q5409

mycnc
Posts: 1049
Joined: Thu May 10, 2018 2:42 pm
Location: Ottawa, Canada
Contact:

Re: Fadal 4020 upgrade

Post by mycnc »

M601 PLC code is

Code: Select all

#include pins.h

main()
{
  portset(OUTPUT_LOW_SPINDLE_SPEED);					// 7 - ON
  portset(OUTPUT_LOCK_SPINDLE_ORIENTATION);	// 4 - ON

  portset(OUTPUT_SPINDLE);			// 14 - ON SPINDLE
  portclr(OUTPUT_CCW_SPINDLE);	// 13 - OFF
  dac01=rmp10;  // What is the DAC value to get 10RPM?

  do{
		a=portget(INPUT_SPINDLE_POSITION);	//4
  }while(a!=0);  //wait till SPINLDE POSITION INPUT is active

  portclr(OUTPUT_SPINDLE);			// 14 - OFF SPINDLE

  portset(OUTPUT_TURRET_EXTEND1); //6 - ON
  portset(OUTPUT_TURRET_EXTEND2); // 2 - ON

  timer=0;
  do{
		a=portget(2);	// What's name for input #2 ?
         timer++;
         if (timer>3000) //ERROR
         {
            message=PLCCMD_MOTION_BREAK;
            timer=2;do{timer--;}while(timer>0);
            exit(99);
         };
  }while(a!=0);  //wait till SPINLDE POSITION INPUT is active

  portclr(OUTPUT_TURRET_EXTEND1); // 6 - OFF
  portclr(OUTPUT_TURRET_EXTEND2); // 2 - OFF

  portset(OUTPUT_DRAWBAR_LOCK);//  12 - ON
  timer=2000;
  do{ timer--;} while(timer>0);

  exit(99);
};


M602 PLC code is

Code: Select all

#include pins.h

main()
{
  portclr(OUTPUT_DRAWBAR_LOCK);//  12 - OFF

  portset(OUTPUT_TURRET_EXTEND1); //6 - ON
  portset(OUTPUT_TURRET_EXTEND2); // 2 - ON

  timer=0;
  do{
		a=portget(2);	// What's name for input #2 ?
         timer++;
         if (timer>3000) //ERROR
         {
            message=PLCCMD_MOTION_BREAK;
            timer=2;do{timer--;}while(timer>0);
            exit(99);
         };
  }while(a!=0);  //wait till SPINLDE POSITION INPUT is active

  portclr(OUTPUT_TURRET_EXTEND1); // 6 - OFF
  portclr(OUTPUT_TURRET_EXTEND2); // 2 - OFF

  portclr(OUTPUT_LOCK_SPINDLE_ORIENTATION);	// 4 - OFF

  exit(99);
};
M610 code to turn the changer until the next tool will be later.

All of this is just concept for a test.
I hope this description will be useful for other projects.

euroflo
Posts: 25
Joined: Wed Dec 19, 2018 8:23 pm

Re: Fadal 4020 upgrade

Post by euroflo »

Hi mate, thanks for that will give it a go and see what happens...
On the M602.(turret retract) we only need the output 2 on, so can we just delete the output 6 line..?

euroflo
Posts: 25
Joined: Wed Dec 19, 2018 8:23 pm

Re: Fadal 4020 upgrade

Post by euroflo »

like this..?



M602 PLC code is

Code: Select all

#include pins.h

main()
{
  portclr(OUTPUT_DRAWBAR_LOCK);//  12 - OFF

 
  portset(OUTPUT_TURRET_EXTEND2); // 2 - ON

  timer=0;
  do{
		a=portget(1);	// Turret home #1 ?
         timer++;
         if (timer>3000) //ERROR
         {
            message=PLCCMD_MOTION_BREAK;
            timer=2;do{timer--;}while(timer>0);
            exit(99);
         };
  }while(a!=0);  //wait till SPINLDE POSITION INPUT is active

  portclr(OUTPUT_TURRET_EXTEND1); // 6 - OFF
  portclr(OUTPUT_TURRET_EXTEND2); // 2 - OFF

  portclr(OUTPUT_LOCK_SPINDLE_ORIENTATION);	// 4 - OFF

  exit(99);
};
M610 code to turn the changer until the next tool will be later.

All of this is just concept for a test.
I hope this description will be useful for other projects.
[/quote]

euroflo
Posts: 25
Joined: Wed Dec 19, 2018 8:23 pm

Re: Fadal 4020 upgrade

Post by euroflo »

DAC value..??? dont know. I will have to have a look at his and see if I can come up with a reading

Post Reply