* Init port of Cura's MM interlocking
* Refactor a bit
* Fix crash when bottom surface is multi-color
* Fix crash when boundary avoidance is 0
* Add config
---------
Co-authored-by: zhimin.zeng <zhimin.zeng@bambulab.com>
jira: none
Change-Id: I81cacddf46ad5921a7a2a23fff07cc17addceb6f
1. Do not consider empty filament when selecting group for ams
2. Function "collect_filaments_in_groups" is frequently called,
optimize memory allocation to speed up.
jira: NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Iad8c9a257bc2dd832c77e650f8c052fb9d8379a0
1. Machine with multi extruder should set length of extruder offset
to extruder num
2. Register retract_restart_extra
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Ic3eb324cb91dc70b091c8922936d2709c361cc38
1.Caused by uninitialized filament map in mapping for AMS
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: I71ce6001fc6f2e72eb9303fcaba0bac16ad70dc9
1.Only consider groups with a distance within the threshold
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: I91526a796a0f7f1ed3e77c41076c1f85620dd944
1.Use max flow network to handle limit
2.Support setting master extruder id
3.Fix the issue in the KMedoids algorithm where data is overwritten
after each retry.
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Idd2bedf39f61e7a65eb4199852f60b8fbebe0a7d
1.Set the default size of ams filament to 2
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Ie985ecfa44cb9fcaf21406303e32bb56e731f351
1.If the group result differs little in flush,we will choose the one
that best fits the ams filaments
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Icd147b406e3494c841ef13564ad1b1231ad798fd
1. Caused by setting the current filament to filaments used
in machine start gcode
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: If6789b1e02aadc6d03610b7b7cc4c829ae767a7d
1.Use float to store the weight copmputed in the procedure.Avoid the
issue where filament weight remains at 0 after changing filaments
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Iff0cfc6e22f34affbc232dbfe196f27ee06d2d9e
Jira: none
if the fist print filement as same as the filament be set on start gcode
not insert filment change
Signed-off-by: qing.zhang <qing.zhang@bambulab.com>
Change-Id: I0114f287fff9be276a90772537d1910df18dec61
1. Nozzle Volume and Nozzle Type support multi extruder now
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Ie171b5105bd3830db3a992cadd365b785008c47a
Should use filament id instead of extruder id
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: I669092da6902158ad5f89d4814c78eabdfb2e7c7
1. auto mode dragdrop is not allowed
2. not display filament_map when there is no result in auto mode
jira:none
Change-Id: I0800e0d832e27fe459a17bb1aa829b5e72d0ee8f
1.Use min cost max flow to solve the tool order
jira:NEW
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: I909845039b67c7fe3ddd42580ad3f1d71d52262d
1. also remove original nozzle_volume_type from printer
and move into project config
2. support save nozzle_volume_type into appconfig
and load from it at beginning or printer switch
jira: no-jira
Change-Id: I01fc82d142fc633fc59a238796a71b9f8d180efb
1.Save multi extruder state in gcode processor
2.Add machine exturder change time
3.Fix some naming issues
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: I9785331290515eeb908ff0ff01aad5aac44212d9
1.In auto mode,display the statistics of auto mode and single
extruder
2.In manual mode,display the statistics of manual mode and auto mode
3.Support by object mode
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: If54c4db79f33d5278c0f18d01ab0518e8660f9c7
1.Should calculate cost if filament used in that layer is 1,because
we should consider the last filament used in previous layer
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: I5838af77f1d73bfa07c65bd6ee12ae352dc3b571
1.Use forcast when filament num in current layer and next layer both
smaller than limit number
jira:NEW
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Ia21bb22ce353f0c74eeaf748c6d9f9c4b315ec18
1.Add filament flush,filament change count reduced by multi
extruder
NTOE: cases when printing by object haven't been handled
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Iaaea5f8ffae2345df5a6f1dc605342d835974d48
1.When n becomes large,the original algorithm to get best filament
sequence will cost too much time and memory.Use a greedy algorithm
instead.Always select the next filament with fewest flush
jira:NONE
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Iabc924e1bdb0a07af0a6ef0bbdd62e54ce54f052
1. always resize filament count when not matched in full_fff_print
2. remove no-use codes in Preset::normalize
jira: no-jira
Change-Id: Ie15a5977d28f28e0f63ba84f27f98f77d16665c0
1.During the filament change, the extruder will extrude an extra length
of grap_length for the corresponding detection, so the purge volume can
reduce this length.
jira:NEW
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: I14f55a3200c1dd48b1603e50280d0c29e1319ebe
1.When filament <10, do the reorder with next layer.This can reduce
10% flush in some cases
2.Support custom filament seq
3.Use caches to speed the algorithm
jira:NEW
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Ie1af9841f7165802d350eae962efe8febafbb357
1.When capacity is greater than the num of filaments, always choose the
map result that can be accommodated
2.In BestFit strategy,always try to fill up the existing capacity
3.In BestCost strategy, just try the group with fewest flush
jira:NEW
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: Ifd6d64b77774039e57ffff26cf2243a4d3f89054
and fix bug when switching printer preset between single-nozzle and double-nozzle, prompt the modification of extruder_count
jira:none
Change-Id: I1d5f0b2f002493378d2f482d08cfd5a72b35b99f
1.When n<10, calc all case cost
2.When n>10, first k-medoids algorithm first
3.Enable setting group size
jira:NEW
Signed-off-by: xun.zhang <xun.zhang@bambulab.com>
Change-Id: I625f47e0235c70e440c6d489b052a156fbffca3f
1. backend support multi_extrude data structure
2. Compatible with third-party calibration
3. fix bug when get extruder in gocde export process
Change-Id: I5dac9abdd9907a521a1ba9b480f9e05640591bc1