You are here

Laser Focus improvement

Stephan R. from Germany sent us an improvement on the firmware focus code.

It's related to the way we reset the ADC every time the interrupt vector is invoked. Below you can see the code affected including the modification (commented lines in red).

Basically, we were re-starting the conversion using the sentence ADCSRA |= 1<<ADSC and really it is not needed because we configured the ADC to auto-trigger on the init function.

Although we have been focusing without any problem since we wrote that code we tested the modification and we saw that the driver can focus in the same way and probably better.

Stephan said he discovered it because his prototype had problems to focus and when he removed the lines mentioned the driver started to focus well. Probably this different behaviour between prototypes is produced by electric noise on the FE signal and using this modification the firmware is more robust and detects easily the s-curve needed for focusing. Stephan also confirmed us that once focused the laser prints correctly at 600dpi so it means it is really focused.

We will continue to test this improvement but if you experimented difficulties while focusing try to comment those lines (in red). Then compile it and upload the code to the Arduino. You will find the code at focus.cpp file on TwinTeethFirmware.