Trying to control two pins seperatly with M106/M107 commands

Right now, D10 will turn on and off with the m106 and m107 commands. I edited #define FEATURE_FAN2_CONTROL to be set to 1. This makes it so whatever FAN2_PIN is assigned, it will be controlled by M106 P1. But the problem I have is that the D9 LED will turn on when M106 P1 is called, but is extremely faint and looks to be blinking fastly. I am controlling the output of a welder with M106 on D10, but I now want to control another object in a similar fashion. Did I do something wrong, or am I going about this the incorrect way?


  • You need to make sure no other function uses the same pin or they influence each other. Look especially for extruder heater and cooler fan definitions. Heatbed normally uses D8 on ramps as that is the only one allowing 10A.
  • I am doing nothing but G commands to control the movement of an XY gantry, and using M106 to turn on a welder on D10, and now hopefully a solenoid on D9. Would D9 having other functions bound to it have this effect, even though I am not calling any other function than M106 P1? I used a multimeter when turning on D9, and got extremely low voltage (enough to just show it turns on practically) compared to D10 which shows 12V DC.

    I guess I am just confused on how the D9 pin being bound to other functions would limit its voltage even though I use no other functions that G movements and M106/M107/M114. In the meantime, I will make sure that D9 is only being used as FAN2 like you said
  • It does not matter if you use other commands using D9. If extruder cooler uses D9 it will also constantly set it's pwm value so you have 2 functions setting it to what they want and none gets what it wants. So only way is to check firmware configuration.h if any pin configured in extruder or bed use same pin.
  • Ah I see, Figured it out thanks! One of the pins was being used as the extruder cooler in Config header. Thanks
Sign In or Register to comment.