SAMMYC21 ERCF
-
Hey everyone, I have a bit of a strange issue that I'm wondering if anyone has seen or tried.
I built the Canned ERCF board from @Gixxerfast and have been playing with it on and off. I tweaked the SAMMY firmware to support UART steppers and I got things moving around. Today, I finally got to the point of getting some macros created to automate things and ran into a bit of an issue.
I am have setup the ERCF drive motor as another motor on the existing tool:
M584 X1.2 Y1.1 Z0.0:0.1:0.2:0.3 E1.0:124.1 M563 P0 D0:1 H1 F0
With that setup, if I run these commands (in a nutshell):
G1 E0:10 M400 G1 E10:10 M400 G1 E10
In this example, the filament is fed down to the extruder, run the two extruders in tandem for a bit, and then advance the toolhead extruder for normal printing. This is great and I can make this work.
Now, since the drive is essentially the second motor for the extruder, I thought I could use the ERCF infrared sensor as a pulsed filament sensor and since both the motor and sensor are on the same board, this should work. Right? . So I issue the command
M591 P7 C"124.io3.in" S1 D1 A1
I get an error:
M591 P7 C"124.io3.in" S1 D1 A1
Error: M591: Response timeout: CAN addr 124, req type 6046, RID=38My assumption is that it's an issue with SAMMYm judging by the "out of memory" in the diag, but I don't have enough knowledge about the firmware to check into it. Has anyone seen this? If so, any pointers?
Here's the M122:
M122 B124 Diagnostics for board 124: Duet SAMMYC21 firmware version 3.4.2 (2022-10-03 19:14:08) Bootloader ID: SAMMY-C21 bootloader version 2.4 (2021-12-10) All averaging filters OK Never used RAM 92, free system stack 88 words Tasks: Move(notifyWait,0.0%,153) HEAT(notifyWait,0.1%,115) CanAsync(notifyWait,0.0%,64) CanRecv(notifyWait,0.0%,77) CanClock(notifyWait,0.0%,64) TMC(notifyWait,2.0%,45) MAIN(running,94.4%,440) IDLE(ready,0.0%,41) AIN(notifyWait,3.5%,142), total 100.0% Last reset 00:17:23 ago, cause: software Last software reset at 2023-01-07 18:28, reason: OutOfMemory, available RAM 92, slot 2 Software reset code 0x01c0 ICSR 0x00000000 SP 0x20002888 Task MAIN Freestk 534 ok Stack: 20000d0c 00012afb 20000d0c 0001eea5 20000d0c 00000070 20003184 0001ed81 00000000 20003180 20000d0c 0001edd9 20000d0c 00000068 00000000 00000068 20007138 00000001 00000004 0001ec6d 00000068 00019b19 00000007 0000c4f3 a5a5a5a5 a5a5a5a5 a5a5a5a5 Driver 0: pos 0, 80.0 steps/mm,standstill, SG min 0, read errors 0, write errors 1, ifcnt 139, reads 42770, writes 9, timeouts 0, DMA errors 0, CC errors 0, steps req 0 done 0 Driver 1: pos 0, 80.0 steps/mm,standstill, SG min 2, read errors 0, write errors 1, ifcnt 152, reads 42770, writes 9, timeouts 0, DMA errors 0, CC errors 0, steps req 0 done 0 Moves scheduled 0, completed 0, in progress 0, hiccups 0, step errors 0, maxPrep 0, maxOverdue 0, maxInc 0, mcErrs 0, gcmErrs 0 Peak sync jitter 7/19, peak Rx sync delay 201, resyncs 0/0, no step interrupt scheduled VIN voltage: min 29.8, current 30.1, max 30.5 MCU temperature: min 24.7C, current 24.8C, max 25.2C Last sensors broadcast 0x00000000 found 0 156 ticks ago, 0 ordering errs, loop time 0 CAN messages queued 8374, send timeouts 0, received 13569, lost 0, free buffers 37, min 37, error reg 0 dup 0, oos 0/0/0/0, bm 0, wbm 0, rxMotionDelay 0
-
@Th0mpy yes it appears that there is insufficient RAM to create the filament monitor. The SAMC21 has only 32kb. However, the Duet3D tool board supports a driver, filament monitor and accelerometer, so that combination at least should work. What other devices do you have connected to the board and configured? Do you have more than one driver?
-
@dc42 theres 2 drivers on the ERCF
-
How much extra memory does the UART-driver take? Or is it a replacement for the SPI driver? Maybe you have to clean up the code?
...and wtH is ERCF? Any pointers, please?
-
@o_lampe Enraged rabbit carrot feeder, similar to smuff. It's a Multi filament unit.
-
@Th0mpy you could try the Duet3Expansion 3.5 source together with the 3.5 source for CANlib and CoreN2G. It has about 200 bytes more RAM available.
You could also reduce the sizes of the debug UART transmit and receive buffers in file Hardware/SAME5x_C21/SAMC21/Devices.cpp. They are currently both set to 512 bytes, which is much larger than necessary.
PS - I've just reduced those buffer sizes in the 3.5-dev source code.
-
This is great!
From a hardware perspective I just have the two steppers, ir switch, servo, and endstop. There is another unused output but not tied to anything yet.
I will give that a try this evening.
I appreciate the pointers!
-
@dc42 That seemed to fix it. Just updating alone to 3.5 was enough to handle the filament sensor, but when I enabled the end-stop it crashed again. I had to reduce a little further so I also reduced buffer sizes for UART.
Everything works together now. Thank you for your help! I have a bunch of manual macros working now so I just need to automate it all.
-
-
If you decide to undertake the ERCF, hit me up. I have a few boards that I made. You can't buy just one. I also made some adjustments (manually) to the board to solve the servo issue experienced by some.
I'll post about it later in another thread once I get it a little more automated.
-
@Th0mpy are you using the ERCF sensor under the extruder?
-
@jay_s_uk Not at the moment. I am only using the 1/2 bondtech gear in the ERCF itself for confirmation of bowden distance to load the extruder.
I am thinking of adding a sensor in the extruder to simplify, but there is no eloquent way to add a reliable filament sensor (i.e. magnetic filament monitor) to the stealthburner yet. They do have a simple switch sensor but I really don't like the washer approach.
That said, I am playing with the laser filament monitor, which would fit into the stealthburner nicely. It does not, however, work as well with the PET filament. I did contact the manufacturer to get their specs and programming guide for the sensor, but I haven't had time to play with it yet.
-
@Th0mpy it may be worth looking into https://reprap.org/forum/read.php?424,889788
-
@oliof Good ole Forest Mimms, I had a few of his books from Radio Shack when I grew up.
I will have to check this out, I was considering something like that but was leaning towards something already manufactured. This is cool!
-
@oliof
That is cool.
Have you integrated it on RRF?
If so, can you detail it (in a new post)? -
@OwenD Of course! I plan to share what I have this weekend(ish). I'll post a new thread on the subject.
-
@OwenD I have not built that myself, nor integrated into RRF. I am just reading that section of the venerable reprapforum and sometimes interesting stuff comes up.
-
@OwenD Did you make a new Post? I am soldering my own canned ercf board now. Can you share the firmware card you used?
-
@VoodooBane
I think you need to ask @Th0mpy
I'm just an onlooker -
Hey thompy, Do you have any of the boards still? I would like one from you if you do
@Gixxerfast I sourced a bunch of the SMD components myself. However, it looks to be that some components are missing from your Excel document. I didn't think to look for whatever reason before buying components.
The components you did not include in the Excel sheet and what I am missing.
D1, D2
C3, C4, C6
R8, R11, R12, R13, R14, R15, R16, R17, R18, R19I really hope I am not screwed...
See my screenshot.