mirror of
				https://github.com/node-red/node-red.git
				synced 2025-03-01 10:36:34 +00:00 
			
		
		
		
	Better serial port error handling
This commit is contained in:
		@@ -46,7 +46,6 @@ function SerialOutNode(n) {
 | 
				
			|||||||
            return;
 | 
					            return;
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        node.port.on("ready",function() {
 | 
					 | 
				
			||||||
        node.on("input",function(msg) {
 | 
					        node.on("input",function(msg) {
 | 
				
			||||||
                //console.log("{",msg,"}");
 | 
					                //console.log("{",msg,"}");
 | 
				
			||||||
                node.port.write(msg.payload,function(err,res) {
 | 
					                node.port.write(msg.payload,function(err,res) {
 | 
				
			||||||
@@ -55,7 +54,6 @@ function SerialOutNode(n) {
 | 
				
			|||||||
                        }
 | 
					                        }
 | 
				
			||||||
                });
 | 
					                });
 | 
				
			||||||
        });
 | 
					        });
 | 
				
			||||||
        });
 | 
					 | 
				
			||||||
    } else {
 | 
					    } else {
 | 
				
			||||||
        this.error("missing serial config");
 | 
					        this.error("missing serial config");
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user