User Tools

Site Tools


Keyence 3D image to STL

3D data must be collected using “Depth Up” on the keyence microscope

Keyence Software for Conversion

The Keyence has the ability to use its motorized objective and focus sensing to create 3D depth maps by scanning the focal point of the microscope up and down across the sample. This 3D data is saved within the .jpg or .tiff file, and must be exported to a .csv file before STL conversion.

Exporting .csv data from .jpg or .tiff file

Obtaining 3D data from these files requires Keyence software. This is available on the computer used for the CNC mill. To find it, open the Windows search bar and search for “vhx3d”.

Once opened, the software will prompt you to select a file that contains 3D data. Choose a file and press the “Save CSV” file to get a “.csv” file from 3D data embedded in the image file.

The exported .csv files contain height data in microns. No x and y data is given, for these you should refer to the datasheet on 3D pixel sizes.

Exporting to STL

  1. Download the Matlab scripts “surf2stl.m” and “stl_maker.m”, making sure they reside within the same file path folder as the .csv file exported earlier
  2. Launch STL maker within Matlab
  3. Change the file name path within “stl_maker.m” to match that of the exported .csv file \\
  4. Run the script, matlab will automatically export the STL file to the file path This PC→Documents→MATLAB with the file name of your csv file appended with _STL.
  5. The exported STL will simply be a mesh file of the surface scan generated by the keyence. Importing the STL into Solidworks or another mesh file editor should allow surfaces to be added and the mesh to be closed if solid 3D prints are desired.
keyencetostl.txt · Last modified: 2021/06/09 17:34 by furst