Background: I have many years of experience with AVR and ARM Cortex PLCs and I feel very comfortable using them in projects but I am not an EE or SE. So, if I make a mistake or misunderstand something, keep that in mind. Thanks.
I cracked open the case on my Maker Select v2.1 and I noticed that I have a 2x3 header that is labeled ISP. This is fairly standard for the AVR PLCs and the Melzi board that I have uses the ATMEGA1284P.
I have asked at numerous forums and nobody seems to really know the answer (the downside to RepRap--people use but don't fully understand).
I'm wondering if I can tweak the Repetier firmware (I'm using the stock version 0.91) to use the ISP headers as a standard SPI bus. It has the SCK, MOSI, and MISO pins but it doesn't have the SS pin.
What I want to do is put a port expander on the SPI bus and break out additional usable GPIOs.
So, is there a hardware limitation or any other reason why I wouldn't be able to repurpose the ISP headers into an SPI bus?
In theory, you can; but, you may need those pins to attach an external programmer to bring your system back to life when playing around with the code.
Here are a couple of articles that could help if you still want to pursue that path:
- Can SPI programmer interfere with other components on same pins?
- Can I reuse ISP pins for other tasks?(Target: Atmega164p)
Another option (the one I chose) is to just buy a RAMPS board set. I got one on ebay for $19 and it have lots of more options for IO. That way you can play and still go back and plug in your stock Melzi and print whenever you need it.
I got all this for $40 - boards, display, cables, power supply, and even shipping enter image description here">
Here is a really nice detailed description of converting a Duplicator i3 from Melzi to RAMPS. The process would likely be very similar for your printer.
The biggest challenge will likely be setting up the firmware
BTW, what printer did you get?