Welcome! Log In Create A New Profile


Mega2560+Marlin additional memory

Posted by CliveB 
Mega2560+Marlin additional memory
March 18, 2020 05:52AM
I am building a specialised 3D printer - now on prototype Mk3, I won't go into much details except to say that the 'bed' surface is not smooth - liken it to a map with contours.
I built a bed plotting mechanism using a digital dial gauge and a Arduino Nano pre-processing results and providing additional control to the printing gantry, this communicates via I2C to the main Mega2560 which has a RAMPS1.4 board and is running Marlin 2.
I have over 1000 plot points, which is outside of the memory limits of the Mega2560. I would like to keep this hardware configuration as I have other machines using it.

I have developed the terrain mapping and tracking software and this is working OK, if only I could store all the plot points.
To make things easier I print from Xmin to Xmax then increment the Y axis and then print Xmax to Xmin. never at any angle (well at this stage of the print that is)
There is memory space to store one of these complete movements so I don't need to retrieve the stored data point by point but rather line by line.

I have tried 2 approaches
1) Using the SD card as a store. I can create the file using card.openFileWrite("PROBE.PNT") and I can manipulate the index and write using card.write_command.
I would like to use the underlying file open/write and read commands but have lost my way within Marlin.

2) Using a sio memory device 23LC1024 piggybacked onto the expansion board to the RepRapDiscount Full Graphics Smart Controller for the SCK, MISO, MOSI, Vcc, Vss pins and A12/D66 on AUX2 for CSS pin. I thought that the EEPROM routines would work even though the device is RAM. I have had no joy exploring this either.

I have scoured this forum and the web in general and have seen others trying this back several years ago, but no final answers .

If anyone has achieved the end result of adding memory that does not need to be blindingly fast - it is only read/written every few seconds - or can assist in any way, I would be very grateful.
Re: Mega2560+Marlin additional memory
March 18, 2020 02:38PM
My advice is to stop wasting your time with obsolete electronics and get a 32-bit board.

Large delta printer [miscsolutions.wordpress.com], Robotdigg SCARA printer, Crane Quad and Ormerod

Disclosure: I design Duet electronics and work on RepRapFirmware, [duet3d.com].
Re: Mega2560+Marlin additional memory
March 19, 2020 02:07AM
In a lot of ways I agree with you.
I have no knowledge of boards compatible with the programming I have done with the existing combo and with the current wiring, and thought it best to stick with what I know (or what I thought I knew!)
I will start investigating but what boards would you suggest?
Re: Mega2560+Marlin additional memory
March 19, 2020 03:21AM
... I'm working with ArduinoDue and Marlin4Due or Marlin2 ...

Aufruf zum Projekt "Müll-freie Meere" - [reprap.org] -- Deutsche Facebook-Gruppe - [www.facebook.com]

Call for the project "garbage-free seas" - [reprap.org]
Re: Mega2560+Marlin additional memory
May 18, 2020 04:08PM
If this can help, I modified Marlin 1 a long time ago to write spool usage in a small database on an external 24LC256.
I'm using a good old Mega2560 with RAMPS1.4. It's communicating with the EPROM by I2C. I attached the modified firmware.
You can reuse eepromi2c.h and write some code inspired by how it's used in Marlin_main.cpp (look for EXTEEPROM in the code)
open | download - Marlin_.7z (313.2 KB)
Sorry, only registered users may post in this forum.

Click here to login