Duet3D Logo Duet3D
    • Tags
    • Documentation
    • Order
    • Register
    • Login

    Best way to use an Arduino as an input ?

    Scheduled Pinned Locked Moved
    General Discussion
    3
    6
    313
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • tpraundefined
      tpra
      last edited by

      Hi,

      I'm currently working on a small printer add-on based on an arduino.
      It's standalone, but it would be a cool feature to display some of the datas computed by the arduino into Duet Web Control (basically 2 or 3 integers or floats, but nothing else).

      ... and i have absolutly no idea where to start or which protocol to use, or which pins on the duet wait for what, or whatever.

      Not asking for a copy paste solution 🙂 but if someone can point me to the right direction that'll help a lot !

      1 Reply Last reply Reply Quote 0
      • jay_s_ukundefined
        jay_s_uk
        last edited by

        Use one of the paneldue serial headers
        The BLV neopixel code should give you a good starter for 10 https://github.com/mule1972/NeoPixelBLVmgn

        Owns various duet boards and is the main wiki maintainer for the Teamgloomy LPC/STM32 port of RRF. Assume I'm running whatever the latest beta/stable build is

        1 Reply Last reply Reply Quote 0
        • tpraundefined
          tpra
          last edited by tpra

          Thanks ! reading... i assume there are not that much real life examples in the direction i want (arduino to duet) but serial is a good start 🙂

          I was lazy enough to think about faking a sensor with an arduino output.
          So that i don't have to modify anything into Duet's code. Plus I want the thing to be available to anybody without modifying the firmware -- even maybe the 8bits board users with other firmwares).

          jay_s_ukundefined 1 Reply Last reply Reply Quote 0
          • jay_s_ukundefined
            jay_s_uk @tpra
            last edited by

            @tpra that link is using an arduino to communicate with the duet.
            Theres also the CNC pendant that works in the same manner https://duet3d.dozuki.com/Wiki/CNC_Pendant

            Owns various duet boards and is the main wiki maintainer for the Teamgloomy LPC/STM32 port of RRF. Assume I'm running whatever the latest beta/stable build is

            1 Reply Last reply Reply Quote 0
            • tpraundefined
              tpra
              last edited by

              OK. CNCpendant's a bit more self-explainatory to me!

              And about displaying a custom value into DWC ?
              Let's say for example i want to display the humidity level into DWC.

              It looks easy to send gcodes with the value i want to the board, but how can i just store it to a variable that i can hook into WDC ? Or any other mechanism i did not think about.

              Modifying WDC to display my custom value shouldn't be too much of a problem, but if i can avoid digging into rrf for such a small modification the lazy me would be happy 🙂

              zaptaundefined 1 Reply Last reply Reply Quote 0
              • zaptaundefined
                zapta @tpra
                last edited by

                @tpra said in Best way to use an Arduino as an input ?:

                And about displaying a custom value into DWC ?

                I am using the standby temp fields by setting them up using gcode. In the example below, my print has 0 hours and 5 minutes to complete (based on slicer's estimation).

                0b5fdb09-cb4a-426f-a2f6-ba405c14723c-image.png

                Another option you have is to use gcode to print messages and watch them in the console.

                1 Reply Last reply Reply Quote 1
                • First post
                  Last post
                Unless otherwise noted, all forum content is licensed under CC-BY-SA