Giter VIP home page Giter VIP logo

helios_dac's Introduction

Helios Laser DAC

Digital to Analog Converter for laser projectors.

Open source, low cost USB DAC for the ISP-DB25 (ILDA) laser protocol. Allows you to control an ILDA laser projector via computer over USB. Supports lots of third party software (see link above). This repository consists of:

  • SDK (with examples in C++, Python and C#/.NET)
  • Hardware (PCB schematic in KiCAD)
  • Firmware (Atmel Studio project)
  • Extras (firmware update tool, media etc.)

Developer guide

Third party software integration

Navigate to the folder "sdk" to find the relevant code for interfacing with the Helios DAC in your software. The core SDK is written in C++, documented in HeliosDac.h. But libraries with exported functions that you can call from many languages such as python or C# are available, documented in HeliosDacAPI.h. You can also find examples of usage in the examples folder.

The C++ code depends on libusb. You can use the included libusb binary libraries for Win32, Mac or Linux, or you can build your own. You can find the libusb source on libusb.info, or binaries on https://sourceforge.net/projects/libusb/files/libusb-1.0/

If you wish to use the shared library, there are ready-made builds for Win32 (.dll) and 64-bit linux (.so) in the sdk folder. NB: Only the Windows binary is guaranteed to be up to date. For Mac and Linux it is recommended to build your own or use the C++ classes.

New: There is a native .NET library with example code in sdk/dotnet.

If you are adding support for the Helios in your program, let me know and I can link it on the Helios' home page.

Steps to compiling shared library (.so) for Linux based systems yourself is below. For macOS, try replacing ".so" with ".dylib". For Windows, there is a Visual Studio project in the sdk source directory.

g++ -Wall -std=c++14 -fPIC -O2 -c HeliosDacAPI.cpp
g++ -Wall -std=c++14 -fPIC -O2 -c HeliosDac.cpp
g++ -shared -o libHeliosDacAPI.so HeliosDacAPI.o HeliosDac.o libusb-1.0.so

To use the device on Linux you either need root privileges or need to set up udev rules (see https://bitlasers.com/helios-laser-dac/)

A more detailed guide for compiling for Raspberry Pi (Linux ARM) is also available in the docs folder.

Hardware and firmware modification

The PCB is drawn in Kicad. The firmware is written and built with Atmel Studio for the ATSAM4S2B microcontroller. New firmware can be uploaded to the device over USB. To do this, you must reset the "GPNVM1" bit in the flash memory, which will make the microcontroller boot to the SAM-BA bootloader. You can do this by sending a special interrupt packet to the DAC. You can then access the flash using Atmel's SAM-BA software or BOSSA. There is an automatic tool for firmware updating:

  • Download the firmware updating tool (only for Windows as of now, Mac/Linux partially done): utility/FirmwareUpdater/cli/firmwareupdater_script.zip
  • Unzip, plug in the DAC and run the file "flash.bat".
  • Follow the instructions on the screen (you may need to unplug and replug the device a couple of times as instructed).

helios_dac's People

Contributors

grix avatar halcyon1945 avatar ssteve avatar trojek avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

helios_dac's Issues

Frames with 45 points are ignored

Sending a frame with exactly 45 points to the DAC does not cause the laser to turn on. Problem seems to be that Atmel Software Framework's USB driver reports a wrong length of the USB transfer, causing the frame to not be parsed properly. Will investigate more.

Hardware schematic update request

Hi, looking Helios schematics i found some mismatchings between Kicad files and both Bill Of Materials and your PCB photos. For example, from BOM and photos i can see that your DC-DC converter provides +-12V, while the schematic include a +-9V DC-DC converter. Moreover DC-DC converter isolated ground (called 0V) is connected with the main GND, making the isolation useless. I think that schematic files are not updated to the last review, can you correct this incongruences please?

Thank you very much for your amazing work!

Enclosure type

I'm interested in building a unit but only the PCB parts are shown in the BOM. Where is the enclosure part?

Having issues linking against x64 .lib file

When I compile I get the following error and I didn't see a libusb-1.0_x64.lib

Source\ThirdParty\HeliosDacLibrary\x64\Release\libusb-1.0.lib : warning LNK4272: library machine type 'x86' conflicts with target machine type 'x64'

.net library doesn't close down properly

I am using the .net helios library which works perfectly. However, after closing the program down the thread controlling the laser does not resulting in me having to close it within windows task manager.

Golang support

I want to use HeliosDacAPI in Golang. I try to wrap c++ code using swig but I got a lot of errors. Do anyone has some experience in this topic and can help me to preapere instructions how to use HeliosDacAPI from Go?

Linux python example issues

Hey

I recently purchased a Helios DAC and I`m having problems using the python example for linux.

I used an oszilloscope to display the output of the DAC and to eliminate any influence of other hardware. If If run LaserShowGen on OS X everything seems to work fine. The DAC is recognised and frames are shown just fine (even though somehow distorted on the oszilloscope).

However if I try to run the python example file on Ubuntu (also on a macbook) the DAC is recognized and loads the first frame but gets stuck afterwards. I tried to analyze the problem further and found that after loading the first frame HeliosLib.GetStatus(j) keeps returning 0, so it`s never ready to receive another frame.

I tried using a frame with fewer points (down to 1) but nothing changed. I also tried changing the flags of "int WriteFrame" in all sorts of combinations but wasn`t lucky either.

Has anyone observerd something similar or has any ideas how to solve the issue?

Thanks a lot for any help!

Kind regards
Malte

compiling shared library for macs

Admittedly I didn't totally know what I was doing, but when I compiled the shared library on my Mac, I got the error, " warning: ignoring file libusb-1.0.so, building for macOS-x86_64 but attempting to link with file built for unknown-unsupported file format."

I resolved the issue by replacing libusb-1.0.so with libusb-1.0.0.dylib in the g++ command. This might be an obvious substitution, but I struggled to figure this out for a while. Might be helpful to others to include a hint in the readme. thanks!

Angle optimization

The Journal of the Society for Art and Science Vol. 7 No. 4 pp. 155 - 169
contains an easy way to improve sharpness of picture quality by
compensate for the inertia effects when the laser is taking a sharp turns.
the paper reveal that there is an almost linear relationship between the angle of the turn and the delay to be used to mitigate the effect. - page 161
http://art-science.org/journal/v7n4/v7n4pp155/artsci-v7n4pp155.pdf

found this while browsing http://www.fab-favreau.com/index.php/Main/LaserShowResearch

The XY Channel Offset

Hi Grix,
I have a question about the X/Y Channel Offset.
As shown in the schematic, the voltage of Offset will be 2.5V/2/1.165=1.073V. The voltage range of X/Y should be 0.417V ~ 2.083V. The Offset voltage does not lie on the center of the X/Y range.
1

This means that the +X/+Y output range is -3.976 to 6.121V, the -X/-Y output range is -6.121 to 3.976V, and the differential voltage is between -7.952 to 12.242V. But the ILDA standard requires a +-10V differential output.
2

I wonder if my calulation is correct. Besides, is it possible to remove R22?

Thanks a lot.

Shutter

I would like to use the shutter to send voltage to control a relay. Is that possible?

Disconnect ILDA ground when inactive

Would it be possible to disconnect the ground of the ILDA connection until actual data is transmitted ?
I'm using a Laserworld DS1000 which has 2 inputs ILDA and ethernet.
I'd like to have keep cables connected but the ethernet input is disabled as soon as the ILDA cable is connected to the DAC.
This is by design, the manufacturer advises me to disconnect the ILDA cable at the DAC to use ethernet.
But he mentions that disconnecting the ILDA ground signal would also do the trick.
So I'm wondering if that could be done by the Helios DAC.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.