1. Got a question or need help troubleshooting? Post to the troubleshooting forum or Search the forums!

Solved Matter Control & Arduino are not connecting.

Discussion in 'Troubleshooting' started by BrooklynBay, Jan 1, 2021.

  1. BrooklynBay

    BrooklynBay Active Member

    Joined:
    Apr 7, 2018
    Messages:
    424
    Likes Received:
    49
    The Arduino UI won't let me edit this error:
    struct fpos_t {
    /** stream position */
    uint32_t position;
    /** cluster for position */
    uint32_t cluster;
    fpos_t() : position(0), cluster(0) {}
    I want to edit fpos_t to say fpost. It won't save unless this error is corrected.
     
  2. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,632
    Likes Received:
    7,312
    #42 mark tomlinson, Jan 6, 2021
    Last edited: Jan 6, 2021
  3. BrooklynBay

    BrooklynBay Active Member

    Joined:
    Apr 7, 2018
    Messages:
    424
    Likes Received:
    49
    I have partial success! I was using firmware that was downloaded a few years ago which worked fine. The original was V1, then I downloaded V2. It seems like it only contained part of the files but not everything to run in the Arduino UI. There's another pinned thread with a link to download firmware. This version contains what I need but had an error compiling it. The sdbase zip has the correct files, and was able to install the firmware into the Arduino board.

    Matter Control connects to the Arduino. It has no RAMPS shield on it but is displaying false temperature readings. I think that installing the shield with thermistors should correct this.

    Here is my question. I think that I have an R1 since the bed says R1 without a plus. The R1 plus V2 firmware has been used for a few years making successful prints. I'm attaching a photo to show the lead screws or threaded rods. Could you identify the type of threaded rods from the photo?
     

    Attached Files:

  4. BrooklynBay

    BrooklynBay Active Member

    Joined:
    Apr 7, 2018
    Messages:
    424
    Likes Received:
    49
    Here's the next issue. I was trying to save my step settings for my Flexion extruder in the EEPROM through Matter Control but the program keeps reverting to the original default settings instead of saving the configuration. It worked previously but won't work now. How could I load the file through the Arduino UI? I'm attaching the file to this post.
     

    Attached Files:

  5. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,632
    Likes Received:
    7,312
    From the picture those are threaded rods -- not leadscrews
    So it is likely an R1 (if the bed were different it would be a Beta).
    Make sure you use the R1 firmware, not the R1+
     
  6. BrooklynBay

    BrooklynBay Active Member

    Joined:
    Apr 7, 2018
    Messages:
    424
    Likes Received:
    49
    I was able to load the firmware onto the MKS board with the Arduino UI too. I couldn't get anything to work previously. How do I update the steps onto the EEPROM? It doesn't seem to work with Matter Control for some reason. The file is attached a couple of posts up.
     
  7. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,632
    Likes Received:
    7,312
    You need to enable the Flash EEPROM:

    https://marlinfw.org/docs/features/eeprom.html

    In the configuration.h look for this:

    // EEPROM
    // The microcontroller can store settings in the EEPROM, e.g. max velocity...
    // M500 - stores parameters in EEPROM
    // M501 - reads parameters from EEPROM (if you need reset them after you changed them temporarily).
    // M502 - reverts to the default "factory settings". You still need to store them in EEPROM afterwards if you want to.
    //define this to enable EEPROM support
    //#define EEPROM_SETTINGS
    //to disable EEPROM Serial responses and decrease program space by ~1700 byte: comment this out:
    // please keep turned on if you can.
    //#define EEPROM_CHITCHAT


    Uncomment the line:
    #define EEPROM_SETTINGS

    (remove the "//" from the beginning of the line)
     
  8. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,632
    Likes Received:
    7,312
    Once you go down the road of customizing the firmware you have to be aware that things can get ... complicated :)
    Not hard really, but there is a lot of interaction between all of the modules.
     
  9. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,632
    Likes Received:
    7,312
    I would STRONGLY suggest that you save copies of the modified files from Marlin that you change and make a note of what you changed and why. Then when you need to come back and make any other changes you know what/where you are.
     
  10. BrooklynBay

    BrooklynBay Active Member

    Joined:
    Apr 7, 2018
    Messages:
    424
    Likes Received:
    49
    My configuration.h file looks identical to the one in post number 47 of this thread. So that means that EEPROM settings should already be turned on?
     
  11. BrooklynBay

    BrooklynBay Active Member

    Joined:
    Apr 7, 2018
    Messages:
    424
    Likes Received:
    49
    All of the things listed in Arduino UI are locked out for commenting. I saw the drop down menu to comment or uncomment but it just makes a ding noise when I click it. Why is the program locked from editing?
     
  12. BrooklynBay

    BrooklynBay Active Member

    Joined:
    Apr 7, 2018
    Messages:
    424
    Likes Received:
    49
    I wasn't able to edit the actual Arduino codes the regular way but I figured out how to work around them. I right clicked edit in configuration.h, and was able to edit the maximum temperatures of the extruder in notepad, and the bed. I went to the steps for the extruder, and edited the steps. I saved the old configuration.h file in a separate folder. I opened the Arduino IDE to verify, compile, and upload to the board. I went into Matter Control, and saw that these edits are now the default settings for the steps.

    I didn't see how to make the option for a second extruder in the MKS board into a second z axis stepper. I have the new modified firmware on the lower priced Arduino board from Micro Center, and didn't try to load it into the higher priced board. Maybe I'll just go ahead, and try to set up this board with the RAMPS 1.6 plus shield. I was previously using the regular RAMPS 1.6 shield. This RAMPS 1.6 plus version required soldering jumpers on each a4988 stepper between the sleep & reset terminals. There are jumpers under each stepper too. I hope that board is configured correctly. If it doesn't work, then I guess I'll just get a regular RAMPS 1.6 which I previously had.
     
  13. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,632
    Likes Received:
    7,312
    Excellent. Glad you made progress.
    I haven't used an MKS board recently so I am not going to be able to assist there.
    The RAMPS 1.4 should be straight forward to configure for that second extruder.
    There is no official RAMPS 1.6 from RepRap (1.4 was the last and 1.5 was designed, but never built or at least not by the RepRap organization) so the 1.6 boards are individually developed in Asia for various manufacturers -- to their own specs.

    There is some documentation about the BigTree Tech version on RepRap site so that may help: https://reprap.org/wiki/RAMPS_1.6

    RAMPS =>
    Reprap Arduino Mega Pololu Shield

    In case you were wondering :)
     
  14. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,632
    Likes Received:
    7,312
    I have not looked at that version... check the configuration.h and see if it is enabled. If not you will be unable to use the flash EPROM (I am just going to call it EEPROM from now on for brevity). Marlin has to enable it and that setting needs to be configured for it. Just look at the file and make sure it is.
     
  15. BrooklynBay

    BrooklynBay Active Member

    Joined:
    Apr 7, 2018
    Messages:
    424
    Likes Received:
    49
    My version of EEPROM settings looked identical to post number 47 so it should be enabled. I saw another place stating that M503 was disabled but I think that M500, M501, and M502 are the only codes for enabling the EEPROM. I still can't figure out how to edit these codes directly in the Arduino IDE without using notepad. Thanks for the help. This was a learning experience on how Marlin & Arduino work.
     
    mark tomlinson likes this.
  16. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,632
    Likes Received:
    7,312
    These are the only ones that work with Marlin:

    ==== EEPROM GCodes ====
    M500 Store current settings in EEPROM for the next startup or M501.
    M501 Read all parameters from EEPROM. (Or, undo changes.)
    M502 Reset current settings to defaults, as set in Configurations.h. (Follow with M500 to reset the EEPROM too.)
     
  17. BrooklynBay

    BrooklynBay Active Member

    Joined:
    Apr 7, 2018
    Messages:
    424
    Likes Received:
    49
    I have everything assembled but it's not working. Here's what's wrong:

    1. Movements are abrupt, only intermittently respond to commands, and don't match the mm movements that they should move.

    2. No response to limit switches.

    3. The servos emit a high pitched noise.

    4. The extruder servo vibrates but doesn't turn.

    5. The RAMPS has new a4988 stepper drivers. Installing old stepper drivers from my old board causes the Arduino to display USB error messages.

    6. One case fan burned out. The second one is very dim.

    Here's what's working:

    1. Matter Control is connecting to the Arduino.

    2. The thermistors, and all of the fans function correctly.

    From what I could tell, it seems like the RAMPS board is either defective or the jumper configuration is not set correctly. I can't tell if the new stepper drivers are bad but it seems like the old drivers are no good or not compatible with the RAMPS. I didn't have any of these issues when I installed the 1.6 board. This board is 1.6+.
     
  18. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,632
    Likes Received:
    7,312
    That does sound as if the steps on the RAMPS are configured incorrectly and/or the stepper drivers are not working correctly.
    Sadly, I can not give you any information targeted for the RAMPS you have. On the RAMPS 1.4 I would start by checking the steps jumpers which are under the stepper driver boards:

    RAMPS_top.jpg

    All three jumpers must be inserted.

    If that does not cure it then replace the stepper drivers -- they are not expensive. The fact that they do not generate enough current to make the stepper actually step is the symptom. Fix the other issues first then look at the stepper drivers.

    Make sure your limit switches are landed correctly on the RAMPS board. in the picture above that board only has two pins for each limit switch but often the boards have three (signal, +v and -v). You MUST only use the two shown on this picture. Otherwise you will short 12v+ to 12v- (which is why I really prefer this style of board since it only has signal and -v so you can't make that mistake)
     
  19. BrooklynBay

    BrooklynBay Active Member

    Joined:
    Apr 7, 2018
    Messages:
    424
    Likes Received:
    49
    Judging from the reviews on the RAMPS 1.6+ boards, it seems like a lot of people are having issues with the 4988 & 8825 steppers. They are designed for 2130 drivers. I saw a good deal for a complete kit (LCD, adapter, cables, RAMPS, Arduino, and 5 steppers) on Amazon for $20 so I'll try that. I hope that I could eventually get this machine working. It's been broken since last month.
     
    #59 BrooklynBay, Jan 8, 2021
    Last edited: Jan 8, 2021
    mark tomlinson likes this.
  20. mark tomlinson

    mark tomlinson ༼ つ ◕_ ◕ ༽つ
    Staff Member

    Joined:
    Feb 21, 2013
    Messages:
    23,632
    Likes Received:
    7,312
    That is entirely possible, good catch.

    Like I said I can't really speak for the 1.5.x/1.6.x RAMPS boards. Honestly if you have a RAMPS 1.4 and it includes heat-sinks on the MOSFETS that driver the steppers you are fine. Upgrading it is like moving off of the Arduino to a 32-bit controller. Just not worth it for a Cartesian printer -- it doesn't buy you any better performance since the 8-bit controller is more than capable of keep up with business.

    Something like a delta printer -- yes, you would certainly want a better combination of electronics particularly on a larger one.
     

Share This Page