Set Fan as PWM laser control

New Home Forum Mostly Printed CNC – MPCNC Troubleshooting – MPCNC Set Fan as PWM laser control

This topic contains 7 replies, has 2 voices, and was last updated by  Vincent Pollaro 5 months, 3 weeks ago.

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #28239

    OmegaII
    Participant

    On to the second problem we are having. Next to the homing problem.

    We would like to control the laser through the Marlin board. It seems the easiest way, and how it’s explained, is through the firmware edit to change Pin 9 to 44 for the fan control, and then connect the 2 pins to the laser.
    Now, if we change this in the firmware, compile it, and upload it. The measured voltage is +-0.05V. It’s the AUX2 part on the ramp board, left up ground, second from the bottom right should be 44 when we follow the guide.

    pin's we connected, and measured

    The part I’ve changed in the firmware is pins_RAMPS.h #define RAMPS_D9_PIN 9 to #define RAMPS_D9_PIN 44, but nothing.
    When changing the fan status and power through Repetier, of M116 S### M117, didn’t make a change.

    All help appreciated.

    #28280

    Vincent Pollaro
    Participant

    Looks like you followed the steps correctly. The command for turning the fan on/off is M106 Sxxx / M107, rather than M116/M117. Give that a try and you should see 5v at S255 and about 2.5v at S127.

    #28281

    OmegaII
    Participant

    Sorry for the confusion, I must have mistyped the codes in the above text. You are right, I’ve tested it with M106 S255 / M107 to shut off. It showed the correct things happening in Repetier, but I could not measure any significant voltage on the board itself. Still can’t.

    #28282

    Vincent Pollaro
    Participant

    I just noticed – You mentioned changing the pin assignment in pins_RAMPS.h not pins_RAMPS_13.h. Double check that you modified the correct file.

    #if MB(RAMPS_13_EFF) || ENABLED(IS_RAMPS_EFB)
    #define FAN_PIN 9// (Sprinter config)

    to

    #if MB(RAMPS_13_EFF) || ENABLED(IS_RAMPS_EFB)
    #define FAN_PIN 44// (Sprinter config)

    After this you should get voltage on AUX2 pin 44 and nothing on D9.

    #28336

    OmegaII
    Participant

    I did indeed change it in the pins_RAMPS.h and not pins_RAMPS_13.h as I could not find any mention in the _13 code for fans. And the only thing pins_RAMPS_13.h does is load the pins_RAMPS.h

    #ifndef BOARD_NAME
      #define BOARD_NAME "RAMPS 1.3"
    #endif
    
    #define IS_RAMPS_13
    #include "pins_RAMPS.h"

    The Github comment also mentions

    pins_RAMPS_14.h => pins_RAMPS.h

    As far as I can see it is an excert from older code?

    `

    #28348

    Vincent Pollaro
    Participant

    Interesting! What version of the firmware are you using? I see that the different configs provided on this site do have differing versions of pins_RAMPS_13.h in them. I am using B16_21-LCD-112515 and the pins_RAMPS_13.h file is larger and does contain the code, where RC7_MPCNC_LCD_9916 does not!

    Attachments:
    1. pins_RAMPS_13.h
    #28481

    OmegaII
    Participant

    We are using the latest RC8 firmware which was linked in the software part of the how to: https://www.vicious1.com/marlin-firmware/
    But maybe we should just try to switch back to the RC7. As I see it only mainly fixed LCD issues, which we don’t have ( an LCD that is ).

    #28583

    Vincent Pollaro
    Participant

    Yeah, I can’t comment on the RC8, as I have only used the RC7 provided here on this machine. If you do switch back, I can guarantee it will work for the control signal on pin 44, barring a hardware problem with the RAMPS/Mega.

Viewing 8 posts - 1 through 8 (of 8 total)

You must be logged in to reply to this topic.