mirror of
				https://github.com/SoftFever/OrcaSlicer.git
				synced 2025-10-30 20:21:12 -06:00 
			
		
		
		
	Merge pull request #3353 from alexrj/feature-3308
Post process script for fan kickstart
This commit is contained in:
		
						commit
						2e1a3eaf16
					
				
					 1 changed files with 13 additions and 0 deletions
				
			
		
							
								
								
									
										13
									
								
								utils/post-processing/fan_kickstart.py
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								utils/post-processing/fan_kickstart.py
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,13 @@ | |||
| #!/usr/bin/python | ||||
| import sys | ||||
| import re | ||||
| 
 | ||||
| sea = re.compile("M106 S[1-9]+[0-9]*") | ||||
| rep = re.compile("M106 S255\n\g<0>") | ||||
| out = open(sys.argv[1]+"_fixed", 'w') | ||||
|   with open(sys.argv[1]) as f: | ||||
|     for r in f: | ||||
|       if re.search(sea, r) is not None: | ||||
|         out.write(re.sub(sea,"M106 S255\n\g<0>",r)) | ||||
|       else: | ||||
|         out.write(r) | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Joseph Lenox
						Joseph Lenox