Lighting up my AM8. Will this work?



  • I would like to add a strip of RGB LEDs (12v common anode) to the frame of my AM8 (Duet Wifi) so that I can see what is happening to in progress prints. I would also like to change the colour of the LEDs at various stages such as Bed heating (Red) Printing (White) and Print complete (Blue).

    I plan on using a ULN 2803 Darlington array and a separate 12v dc power supply as an interface between the Duet board and the LED strip as per the attached schematic:
    0_1537848144011_LED Diagram.jpg

    I plan on using Heater Pins 4, 5 and 6 to switch each of the RGB colours on or off and assume this will require an
    M307 H# A-1 C-1 D-1 command in Config.H for each of the 3 pins.

    I have seen examples of people using an M42 command to turn the various LEDs on/off in the Start and End G-code in Cura but I am unsure of how to achieve a change from Red to White when the Bed and Hot End reach temperature and the print begins.
    So (noting that my electronics expertise is somewhat limited) some questions:

    1. Is there a smarter way of achieving this with the Duet WiFi board?
    2. Should the M42 commands belong in Start and End G codes or in a macro in the Duet online monitor?
    3. How do I get the LEDs to change colour when the heaters reach temperature?
    4. Is it wise to issue an M400 command before each series of M42 commands?

    My thanks in anticipation
    Peter


  • administrators

    That looks OK to me. I assume your LED strips have the series resistors built in - if they are 12V then they should.

    To get the colour changes, I think the best option is to control the heating yourself in the slicer start GCode script (most slicers let you do this) and put the M42 commands in that script.

    There is no need to use M400 before the M42 commands because M42 uis synchronised to the movement command queue, except in very old firmware.

    HTH David



  • Thanks David I will give that a try. Just need to build the board and then test it.


 

Looks like your connection to Duet3D was lost, please wait while we try to reconnect.