@@ -365,11 +365,11 @@ void lpc_reset(struct lpc_device *dev, int isp) {
serial_setline(dev->port, SERIAL_DTR, 0);
if(isp) {
sprog_sleep(50);
- lpc_ispmode(dev, 0);
}
void lpc_close(struct lpc_device *dev) {
+ lpc_ispmode(dev, 0);
lpc_reset(dev, 0);
serial_close(dev->port);
free(dev);