Jump to content

irishbeard

Dormant
  • Posts

    4
  • Joined

  • Last visited

Posts posted by irishbeard

  1. Hi,

    I'm interested in controlling some of the analog (ADC) pins as digital pins on the Ultimaker 2 board. I've seen that this can be done in Arduino using digitalWrite (https://www.arduino.cc/en/Tutorial/AnalogInputPins) and it also seems like it is possible to control them using the M42 command in marlin (http://marlinfw.org/docs/gcode/M042.html). Has anyone tried this or know if this is correct?

    I've found the pin map for the ATmega 2560 (https://www.arduino.cc/en/Hacking/PinMapping2560) and can determine the pin locations using the Ultimaker 2 schematics. However, I'm not sure how to interface with the ADC0-11 pins (M42 PA0 S255 doesn't work). Do the analog pins have a digital pin equivalent on the Ultimaker 2 board (ex: A0 = digital pin XX)? Do I need to set this up myself in the pins.h file?

    Any ideas / comments are greatly appreciated! :)

  2. I saw this thread and thought it was interesting. I've also been wanting to test a pressure actuated printing system. I've tested it out now and it works pretty well! One suggestions though is if you're using the standard firmware (Ulitmaker2Marlin 15.04.6) then there are some issues if you use the LED On/Off commands (M42, M43) for triggering the solenoid. I think this is due to conflicts with the LED "always on, always off, on while printing" settings in the firmware. I ended up switching to the fan PWM pin instead (using M106, M107) and it worked flawlessly. If you want to keep this pin for PWM, I think there are also other pins available that aren't PWM.

    After using it for a while, I noticed that there isn't that much support for slicing g-code compatible with solenoid control. At first, I wrote the g-code manually (good for learning) but is very tedious. You can also write custom post-processing scripts for Cura or Slic3r but it isn't as user friendly. Joseph Lenox helped me implement customization On/Off commands into Slic3r (https://github.com/alexrj/Slic3r/pull/3734). I found it pretty helpful so wanted to pass it along.

×
×
  • Create New...