Best way to use an Arduino as an input ?
-
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 !
-
Use one of the paneldue serial headers
The BLV neopixel code should give you a good starter for 10 https://github.com/mule1972/NeoPixelBLVmgn -
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). -
@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 -
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
-
@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).
Another option you have is to use gcode to print messages and watch them in the console.