Any progress on measuring and publishing new step rates for the 1XD? I've been regularly checking the 1XD docs, the "Duet maximum achievable step rates" post, and the google docs spreadsheet in said post but I have not seen any updated figures as of yet.

Posts made by crap
-
RE: 6XD vs 1XD performance
-
RE: 6XD vs 1XD performance
Thanks for the answers! I was leaning towards the JMC integrated servos rather than clearpath, these are about half the price and accept a maximum steprate of 200khz. Although clearpath is also an option I was considering, but using them would be the no-compromise route so then I would lean even more towards 6xd.
Either way I'm mostly limited in the time I can spend putting together new hardware, and going 1xd is a quicker fix. Like I said I just need to understand what performance I can expect so it doesnt end in dissappointment. If new measurement are posted in a week or two I'll wait for them to decide. Input shaping is not a dealbreaker for me since I have a very rigid machine.
Again big thanks!
-
6XD vs 1XD performance
Hi. I'm looking to get some insight in what performance limitations I may get when daisy-chaining four 1xd boards compared to using a 6XD board.
First: I believe the documentation on the 1XD boards i a bit outdated. The maximum step rates seem to be measurements on firmware version 3.2, but reading the step rate post in this forum and the firmware changelog it seems this was improved in version 3.3 (new rates not measured?). This may also have changed again due to input shaping? Anyone have a clue on what step rates I could expect today, using 4 boards on the CAN bus?
Also regarding input shaping the documentation has conflicting information, one place is saying that it will not be implemented and therefore 1XD boards should not be used to drive primary axis, and one place saying that it will be implemented. Looking at the firmware changelog it seems like it is already implemented? What is the actual status on this? And if I choose not to configure input shaping, does that improve step rates?
So the documentation on the 1XD needs some updating. But let me get to my actual core questions.
First: Is the 1XD a viable option for the main axis of a high performance machine, if I can accept step rates of (worst case) around 40kHz? The documentation says no but again that seems to be based on outdated information.
Second: The 6xd uses single ended signaling and not differential. If I want to combine this with integrated servos (driver mounted on the motor) Could I reliably send step-dir signals up to 200kHz over 4 meter long cables in parallel with power-feed cables? I could see this being a problem but electronics is not my field.
Third: are there other potential issues besides the step-rate and signaling to consider? I don't know how motion control is implemented on external boards, does axis synchronisation suffer due to latency in the CAN bus or is there some smart scheduling being done with synchronised clocks?The background: I have a CNC router currently driven by the 6mbhc. Ball screws 10mm pitch for x and y, 4mm pitch for Z. Double Y axis motors (så 4 motors in total). I use this CNC for production and I want more speed, power and reliability than I can get out of open loop steppers. Ideally I would like to go all in and add 3000rpm servos on all axis and turn the rapid feed and acceleration up so high that I'd need to bolt the machine to the floor. Cycle-time is money! To get the very best performance clearly the 6xd is the way to go. But I have limited to time spend on this conversion, and going this route would mean building an entirely new control box and redoing all the wiring before I can even start configuring the new system. Then I need to so servo tuning after that. I'm also concerned about signal integrity this way. I was planning to use integrated servos with the driver mounted on the motor, meaning the step-direction signals may need to be routed up to 4 meters in parallel with power feed cables for the other motors and the spindle. On the 6xd these signals are single-ended and not differential. I could see this being a problem if I have pulse rates up to 200kHz, but I am no expert on electronics.
The other option is adding 1xd boards to my 6hc motherboard. Given the limited step rates of 1xd servos would make no sense, so I would go with closed loop steppers. This will not improve feeds by much but it should improve acceleration and reliability. You answers will help me decide if I should settle for this option.
Thanks in advance. And sorry for the long post, part of it is because the documentation is a bit contradicting.
-
RE: Duet mb6hc suddenly lost ethernet
The board is more than a year old so no warranty, but regardless I went for the SBC route to just get it running. I realized version 3.3 actually uses the same SD card for SBC and standalone, and the first SD card I used was out of date. I can now connect via the SBC and the versions are matching for sure (all 3.3), so for a while I was relieved and thought I could start production again. But despite being the same version as I used last week my jobs and macros are partially broken, the code is interpreted differently.
I have macros that repeat the same job in a pattern to produce multiple parts efficiently. If I run them as a macro they will terminate after just 2 out of 25 instances the first time I run it with no error being reported. If I run the same macro again it completes the whole pattern, but the first two parts have now been run twice and may need to be scrapped. It's also a wast of time.
If I run the exact same file from the job folder it finishes 5 instances out of 25 and then will not run again because it does not clear the loop variables so they can not be reassigned.Also all my laser jobs (I have both a milling spindle and a laser mounted) now turns on the laser on the first G0 transport of each job, leaving a long straight line across the workpiece ruining it. Subsequent G0 moves are interpreted correctly.
Plus a bunch of other less critical issues...
I know, I know, the only thing to do is to upgrade to the latest version and hope that this resolves the issues. But I really just want this to run and I don't have the time to spend on it right now and I know syntax has changed for some M-codes in config and homing macros so it won't be a quick fix. I could not imagine that the jobs and macros would be broken just by running SBC mode...
-
RE: Duet mb6hc suddenly lost ethernet
Since I'm desperate to get this working I now tried connecting it via ribbon cable and a raspberry pi 3B v1.2. I had an old SD card with the raspberry pi image on it and the raspberry pi boots up and connects to ethernet. But it does not load a DWC, and when running
lsusb
it does not seem to find the duet. I will admit that I'm not 100% if the Pi image and the duet have the same version number, but I'm sure they are close (possibly the Pi is 3.2.2 while duet is 3.3. Is there a way to check Pi firmware version?).I have the duet powering the RasPi via jumper settings. It's a 3B pi with nothing else connected to it and both the duet and the Pi seem to run fine, except not communicating.
I'd still prefer having it working in standalone mode but if this is easier to fix I'll settle for that, so long as I get it running again quickly.
Results of
journalctl -u duetcontrolserver -e
Apr 19 16:18:53 duet3 systemd[1]: duetcontrolserver.service: Succeeded. Apr 19 16:18:58 duet3 systemd[1]: duetcontrolserver.service: Service RestartSec=5s expired, scheduling restart. Apr 19 16:18:58 duet3 systemd[1]: duetcontrolserver.service: Scheduled restart job, restart counter is at 49. Apr 19 16:18:58 duet3 systemd[1]: Stopped Duet Control Server. Apr 19 16:18:58 duet3 systemd[1]: Started Duet Control Server. Apr 19 16:18:58 duet3 DuetControlServer[2005]: Duet Control Server v1.1.0.5 Apr 19 16:18:58 duet3 DuetControlServer[2005]: Written by Christian Hammacher for Duet3D Apr 19 16:18:58 duet3 DuetControlServer[2005]: Licensed under the terms of the GNU Public License Version 3 Apr 19 16:18:58 duet3 DuetControlServer[2005]: Loading settings... Done! Apr 19 16:18:59 duet3 DuetControlServer[2005]: Initialising variables... Done! Apr 19 16:18:59 duet3 DuetControlServer[2005]: Connecting to RepRapFirmware... Error: Duet is not available Apr 19 16:18:59 duet3 systemd[1]: duetcontrolserver.service: Succeeded. Apr 19 16:19:04 duet3 systemd[1]: duetcontrolserver.service: Service RestartSec=5s expired, scheduling restart. Apr 19 16:19:04 duet3 systemd[1]: duetcontrolserver.service: Scheduled restart job, restart counter is at 50. Apr 19 16:19:04 duet3 systemd[1]: Stopped Duet Control Server. Apr 19 16:19:04 duet3 systemd[1]: Started Duet Control Server. Apr 19 16:19:05 duet3 DuetControlServer[2019]: Duet Control Server v1.1.0.5 Apr 19 16:19:05 duet3 DuetControlServer[2019]: Written by Christian Hammacher for Duet3D Apr 19 16:19:05 duet3 DuetControlServer[2019]: Licensed under the terms of the GNU Public License Version 3 Apr 19 16:19:05 duet3 DuetControlServer[2019]: Loading settings... Done! Apr 19 16:19:05 duet3 DuetControlServer[2019]: Initialising variables... Done! Apr 19 16:19:06 duet3 DuetControlServer[2019]: Connecting to RepRapFirmware... Error: Duet is not available Apr 19 16:19:06 duet3 systemd[1]: duetcontrolserver.service: Succeeded.
Results of M122:
[17:15:19:033] === Diagnostics ===␊ [17:15:19:033] RepRapFirmware for Duet 3 MB6HC version 3.3 (2021-06-15 21:45:47) running on Duet 3 MB6HC v1.01 or later (SBC mode)␊ [17:15:19:033] Board ID: 08DJM-956BA-NA3TN-6J9F0-3SJ6R-1V86U␊ [17:15:19:033] Used output buffers: 1 of 40 (1 max)␊ [17:15:19:033] === RTOS ===␊ [17:15:19:033] Static ram: 150904␊ [17:15:19:033] Dynamic ram: 59980 of which 0 recycled␊ [17:15:19:036] Never used RAM 143308, free system stack 190 words␊ [17:15:19:036] Tasks: SBC(ready,4.1%,606) HEAT(delaying,0.0%,405) Move(notifyWait,0.0%,352) CanReceiv(notifyWait,0.0%,944) CanSender(notifyWait,0.0%,374) CanClock(delaying,0.0%,339) TMC(notifyWait,7.0%,93) MAIN(running,88.8%,1244) IDLE(ready,0.1%,29), total 100.0%␊ [17:15:19:036] Owned mutexes: USB(MAIN)␊ [17:15:19:036] === Platform ===␊ [17:15:19:036] Last reset 00:01:56 ago, cause: power up␊ [17:15:19:036] Last software reset at 2023-04-06 19:09, reason: User, GCodes spinning, available RAM 107800, slot 1␊ [17:15:19:036] Software reset code 0x0003 HFSR 0x00000000 CFSR 0x00000000 ICSR 0x0044a000 BFAR 0x00000000 SP 0x00000000 Task MAIN Freestk 0 n/a␊ [17:15:19:036] Error status: 0x00␊ [17:15:19:036] Step timer max interval 14997␊ [17:15:19:036] MCU temperature: min 31.8, current 42.4, max 42.4␊ [17:15:19:036] Supply voltage: min 28.9, current 28.9, max 28.9, under voltage events: 0, over voltage events: 0, power good: yes␊ [17:15:19:036] 12V rail voltage: min 12.1, current 12.2, max 12.3, under voltage events: 0␊ [17:15:19:036] Heap OK, handles allocated/used 0/0, heap memory allocated/used/recyclable 0/0/0, gc cycles 0␊ [17:15:19:036] Driver 0: position 0, standstill, reads 63092, writes 11 timeouts 0, SG min/max 0/0␊ [17:15:19:036] Driver 1: position 0, standstill, reads 63092, writes 11 timeouts 0, SG min/max 0/0␊ [17:15:19:036] Driver 2: position 0, standstill, reads 63092, writes 11 timeouts 0, SG min/max 0/0␊ [17:15:19:036] Driver 3: position 0, standstill, reads 63092, writes 11 timeouts 0, SG min/max 0/0␊ [17:15:19:036] Driver 4: position 0, standstill, reads 63092, writes 11 timeouts 0, SG min/max 0/0␊ [17:15:19:036] Driver 5: position 0, standstill, reads 63092, writes 11 timeouts 0, SG min/max 0/0␊ [17:15:19:036] Date/time: 1970-01-01 00:00:00␊ [17:15:19:036] Slowest loop: 0.12ms; fastest: 0.00ms␊ [17:15:19:036] === Storage ===␊ [17:15:19:036] Free file entries: 10␊ [17:15:19:036] SD card 0 not detected, interface speed: 37.5MBytes/sec␊ [17:15:19:036] SD card longest read time 0.0ms, write time 0.0ms, max retries 0␊ [17:15:19:036] === Move ===␊ [17:15:19:036] DMs created 125, maxWait 0ms, bed compensation in use: none, comp offset 0.000␊ [17:15:19:036] === MainDDARing ===␊ [17:15:19:036] Scheduled moves 0, completed moves 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1␊ [17:15:19:036] === AuxDDARing ===␊ [17:15:19:036] Scheduled moves 0, completed moves 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1␊ [17:15:19:036] === Heat ===␊ [17:15:19:036] Bed heaters = -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1, chamberHeaters = -1 -1 -1 -1␊ [17:15:19:036] === GCodes ===␊ [17:15:19:036] Segments left: 0␊ [17:15:19:036] Movement lock held by null␊ [17:15:19:036] HTTP is idle in state(s) 0␊ [17:15:19:036] Telnet is idle in state(s) 0␊ [17:15:19:036] File is idle in state(s) 0␊ [17:15:19:036] USB is ready with "M122" in state(s) 0␊ [17:15:19:036] Aux is idle in state(s) 0␊ [17:15:19:036] Trigger is idle in state(s) 0␊ [17:15:19:036] Queue is idle in state(s) 0␊ [17:15:19:036] LCD is idle in state(s) 0␊ [17:15:19:036] SBC is idle in state(s) 0␊ [17:15:19:036] Daemon is idle in state(s) 0␊ [17:15:19:036] Aux2 is idle in state(s) 0␊ [17:15:19:036] Autopause is idle in state(s) 0␊ [17:15:19:036] Code queue is empty.␊ [17:15:19:036] === CAN ===␊ [17:15:19:036] Messages queued 583, received 0, lost 0, longest wait 0ms for reply type 0, peak Tx sync delay 0, free buffers 49 (min 49), ts 583/0/0␊ [17:15:19:036] Tx timeouts 0,0,582,0,0,0 last cancelled message type 30 dest 127␊ [17:15:19:036] ␊ [17:15:19:036] === SBC interface ===␊ [17:15:19:036] State: 0, failed transfers: 1, checksum errors: 3␊ [17:15:19:036] Last transfer: 99003ms ago␊ [17:15:19:036] RX/TX seq numbers: 1/1␊ [17:15:19:036] SPI underruns 0, overruns 0␊ [17:15:19:036] Disconnects: 0, timeouts: 0, IAP RAM available 0x2c83c␊ [17:15:19:036] Buffer RX/TX: 0/0-0␊ [17:15:19:036] ok␊
-
RE: Duet mb6hc suddenly lost ethernet
I did not, but I've tried two different internet routers, connecting from two different computers, with two different ethernet cables. All of which have been verified independently to be working. So i figured it would be unlikely to make a difference. I can still try if you think it makes sense, but I'm thinking there should be other things more relevant to try. Like reflashing the firmware? Can i place the install files in the sys folder on the SD card and trigger the install via USB? Or do I need to use Bossa for this if I cant access the DWC? And can I upload the same version or would it refuse because it is not an upgrade?
Either way I'm pretty desperate to get this working within a few days, I'm using the CNC for production in my startup. The last option would be to try using an SBC setup, but this takes some work and brings me no benefit so I hope it can be avoided. Very grateful for any help I get.
-
RE: Duet mb6hc suddenly lost ethernet
As a comment: I have removed the board from the CNC to work on this issue, so no other hardware is connected to it at the moment. It is connected only via USB and ethernet.
M122 results:[20:04:14:191] === Diagnostics ===␊
[20:04:14:191] RepRapFirmware for Duet 3 MB6HC version 3.3 (2021-06-15 21:45:47) running on Duet 3 MB6HC v1.01 or later (standalone mode)␊
[20:04:14:191] Board ID: 08DJM-956BA-NA3TN-6J9F0-3SJ6R-1V86U␊
[20:04:14:191] Used output buffers: 1 of 40 (14 max)␊
[20:04:14:191] === RTOS ===␊
[20:04:14:191] Static ram: 150904␊
[20:04:14:193] Dynamic ram: 91548 of which 0 recycled␊
[20:04:14:193] Never used RAM 111740, free system stack 190 words␊
[20:04:14:193] Tasks: NETWORK(ready,29.9%,429) ETHERNET(notifyWait,0.0%,204) HEAT(delaying,0.0%,414) Move(notifyWait,0.0%,352) CanReceiv(notifyWait,0.0%,944) CanSender(notifyWait,0.0%,374) CanClock(delaying,0.0%,343) TMC(notifyWait,0.0%,105) MAIN(running,70.1%,1131) IDLE(ready,0.0%,29), total 100.0%␊
[20:04:14:193] Owned mutexes: USB(MAIN)␊
[20:04:14:193] === Platform ===␊
[20:04:14:193] Last reset 00:02:35 ago, cause: power up␊
[20:04:14:193] Last software reset at 2023-04-06 19:09, reason: User, GCodes spinning, available RAM 107800, slot 1␊
[20:04:14:193] Software reset code 0x0003 HFSR 0x00000000 CFSR 0x00000000 ICSR 0x0044a000 BFAR 0x00000000 SP 0x00000000 Task MAIN Freestk 0 n/a␊
[20:04:14:193] Error status: 0x00␊
[20:04:14:193] Aux0 errors 0,0,0␊
[20:04:14:193] Step timer max interval 698␊
[20:04:14:193] MCU temperature: min 43.2, current 44.5, max 44.7␊
[20:04:14:193] Supply voltage: min 0.2, current 0.2, max 0.3, under voltage events: 0, over voltage events: 0, power good: no␊
[20:04:14:193] 12V rail voltage: min 0.1, current 0.1, max 0.2, under voltage events: 0␊
[20:04:14:193] Heap OK, handles allocated/used 0/0, heap memory allocated/used/recyclable 0/0/0, gc cycles 0␊
[20:04:14:193] Driver 0: position 0, ok, reads 0, writes 0 timeouts 0, SG min/max not available␊
[20:04:14:193] Driver 1: position 0, ok, reads 0, writes 0 timeouts 0, SG min/max not available␊
[20:04:14:193] Driver 2: position 0, ok, reads 0, writes 0 timeouts 0, SG min/max not available␊
[20:04:14:193] Driver 3: position 0, ok, reads 0, writes 0 timeouts 0, SG min/max not available␊
[20:04:14:193] Driver 4: position 0, ok, reads 0, writes 0 timeouts 0, SG min/max not available␊
[20:04:14:193] Driver 5: position 0, ok, reads 0, writes 0 timeouts 0, SG min/max not available␊
[20:04:14:193] Date/time: 1970-01-01 00:00:00␊
[20:04:14:193] Slowest loop: 9.15ms; fastest: 0.05ms␊
[20:04:14:193] === Storage ===␊
[20:04:14:193] Free file entries: 10␊
[20:04:14:193] SD card 0 detected, interface speed: 25.0MBytes/sec␊
[20:04:14:193] SD card longest read time 3.0ms, write time 0.0ms, max retries 0␊
[20:04:14:193] === Move ===␊
[20:04:14:193] DMs created 125, maxWait 0ms, bed compensation in use: none, comp offset 0.000␊
[20:04:14:193] === MainDDARing ===␊
[20:04:14:193] Scheduled moves 0, completed moves 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1␊
[20:04:14:193] === AuxDDARing ===␊
[20:04:14:193] Scheduled moves 0, completed moves 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1␊
[20:04:14:193] === Heat ===␊
[20:04:14:193] Bed heaters = -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1, chamberHeaters = -1 -1 -1 -1␊
[20:04:14:193] === GCodes ===␊
[20:04:14:193] Segments left: 0␊
[20:04:14:193] Movement lock held by null␊
[20:04:14:193] HTTP is idle in state(s) 0␊
[20:04:14:193] Telnet is idle in state(s) 0␊
[20:04:14:193] File is idle in state(s) 0␊
[20:04:14:193] USB is ready with "M122" in state(s) 0␊
[20:04:14:193] Aux is idle in state(s) 0␊
[20:04:14:193] Trigger is idle in state(s) 0␊
[20:04:14:193] Queue is idle in state(s) 0␊
[20:04:14:193] LCD is idle in state(s) 0␊
[20:04:14:193] SBC is idle in state(s) 0␊
[20:04:14:193] Daemon is idle in state(s) 0␊
[20:04:14:193] Aux2 is idle in state(s) 0␊
[20:04:14:193] Autopause is idle in state(s) 0␊
[20:04:14:193] Code queue is empty.␊
[20:04:14:193] === CAN ===␊
[20:04:14:193] Messages queued 406, received 0, lost 0, longest wait 0ms for reply type 0, peak Tx sync delay 0, free buffers 49 (min 49), ts 406/0/0␊
[20:04:14:193] Tx timeouts 0,0,406,0,0,0 last cancelled message type 30 dest 127␊
[20:04:14:193] ␊
[20:04:14:193] === Network ===␊
[20:04:14:193] Slowest loop: 0.11ms; fastest: 0.02ms␊
[20:04:14:193] Responder states: HTTP(0) HTTP(0) HTTP(0) HTTP(0) HTTP(0) HTTP(0) FTP(0) Telnet(0), 0 sessions Telnet(0), 0 sessions␊
[20:04:14:193] HTTP sessions: 0 of 8␊
[20:04:14:203] - Ethernet -␊
[20:04:14:203] State: active␊
[20:04:14:203] Error counts: 0 0 1 0 0␊
[20:04:14:203] Socket states: 2 2 2 2 2 0 0 0␊
[20:04:14:203] ok␊ -
Duet mb6hc suddenly lost ethernet
Hi! Hoping some here can help me figure this out.
I have an mb6hc running in standalone mode that was working fine very recently. Then I went away for a week, and now that I'm back I can't connect via ethernet. I've tried connecting via USB and it happily reports that ethernet is enabled, and reports both the configured IP and the actual IP (which is the same). But I can't connect to it, it doesn't even show up on the clients table on my internet router. I've tried connecting it via another router, and also directly to my computer (not sure if this would work without a crossed cable though).
The green LED on the ethernet port is mostly solid green, blinking once in a while. the other LED shows no activity whatsoever.
Where do I begin trying to fix this?
-
RE: Pattern jobs
@wwak84 I'm running version 3.3 (on a 6mbhc board). I did suspect it would be possible to call files in other directories using M98 knowing the correct syntax, thanks for telling me how. Nested jobs are not so rare in CNC industry actually, but probably not many hobbyists/makers use it.
-
RE: Pattern jobs
@wwak84 Adding variables to the batch job is a neat idea, I can see that being useful at some point. Although in this case I'd probably run the same parameters quite often so more likely I'll modify the macro instead when it needs changing. A slight issue I've found while trying this is that M98 only calls g code files from the macro directory, although I suppose I can place the job files there instead.
But I'm still surprised that it's not possible to have nested jobs with M32, whether I run the base program from the job directory or the macro directory it behaves differently but neither will allow me to call consecutive jobs from a single file. If using M98 and running everything from the macro folder solves it then fine by me, but it's not the behavior I would expect.
-
RE: Pattern jobs
@wwak84 Thanks for the pointers, I'll look into the meta commands. It would still be nice if I could call a g-code program and have it return and continue executing. I did consider pasting the job 25 times into the same file, but that would make for one nasty file. With your suggestion at least I would only need to paste the full job code once.
-
Pattern jobs
Hi all!
I have my Duet3 set up as a CNC router. I'm looking to produce a large number of identical parts out of wood, so I would really like to be able to repeat a job in patterns, in this case 5x5 for a total of 25 parts per batch. With the added twist that some of them are rotated to get better material use (got a separate g-code file for this).
I'd like to think this is easily done, to call the same two G-code files repeatedly from another G-code file while changing the origin point. But I can't seem to manage this. Here's what I've tried, to only make three parts of which one is upside down:
G54 (the G54 origin is set manually, and represents the first part to be milled) G0 Z36 G0 X0 Y0 G10 L20 P2 X-214 Y-120 Z36 (set G55 coordinates, used for the second part) G10 L20 P3 X-177 Y0 Z36 (set G56 coordinates, used for the third part) G54 M32 "Kanel_uppv_trimmad.g" G55 M32 "kanel_upponer_trimmad.g" G56 M32 "Kanel_uppv_trimmad.g"
Firstly: This doesn't work. If I run this from the Job folder in DWC, it will make only the first part and then stop. Surprisingly if I run it from the macro folder instead, it will only make the last part.
Secondly: This doesn't scale well since there are only 9 numbered origins (G54-G59.3), and I want to make 25 parts. I could still use this method if I redefine the origins as I go along, but I'd like to think there is another way. I tried G92 but the command seems fully broken on my firmware, a simple "G92 X0 Y0 Z0" does not make the current coordinates 0 in any coordinate system (neither machine coordinates nor any of the G5x).
I'm due for a firmware update either way so if anyone suggests a G92 way of doing this I suppose I could update the firmware and hope that it fixes the command, but I'd prefer to just get on with this job right now and update some other time. I know that several of the commands in my config.g have been redefined so it will take me a while to get the machine working again after the update.
Any suggestions on how to do this? Image below shows intended result.
-
RE: Pendant/dwc to hundredth
Alright, some results. This works:
output.print(((float) distance)/100); output.write('\n');
It was just the \n that was missing. I like this solution since it's very easy to read and modify the scale factor. And by using float you can have none-10 factors if you want. It does add about 1400 bytes to the program size, but that still only brings it up to 29% of total so it doesn't really matter.
Not sure though how many decimals are actually printed, since I don't have access to a ttl level serial monitor. I read something about two decimals being default in Arduino. For CNC use it is entirely possible some users would want 3 decimals.
About the machine lag, I did some more testing. if I change just one of the axis to use g0 while the other axis uses g1 I can't provoke it to start lagging. Which doesn't make sense, if I jog an axis that uses the g1 command it should still behave the same. Maybe it's just so sporadic that I can't figure it out, sometimes I can't make it lag and sometimes it's barely usable. Are G0 and G1 moves planned differently in any way? Maybe this theory is completely out of the question.
Either way it seems this is the end of my contribution, because after re-uploading the code so many times I eventually broke the micro-USB port off my arduino, traces and all. So no more updates on my pendant.
-
RE: Pendant/dwc to hundredth
@dc42 Now I feel really stupid. For sure I forgot to print \n on all my attempts. I think I either need to program more often or stay away from it completely...
Anyway, I'll share some of my latest findings:
-unrepentantgeek's code works for me (although I only copy-pasted the relevant lines, I didn't download the full code)-The original code has an obvious flaw: It sends G0 commands along with the F parameter in order to limit jog speed, but if the machine is in CNC mode then G0 commands are always at maximum feed and the F parameter is ignored. Pretty big flaw since jog wheels are mostly used for CNC builds (I think?). I changed this to G1.
-The machine lags terribly when I'm using the jog wheel now. Not sure if this happened with the original code since I barely used if before working on these changes. All commands are received and buffered, but the machine often comes to a near halt (moving so slow you can barely see the stepper rotate) for a few seconds before suddenly executing all moves that were buffered. Surely changing from G0 to G1 could not have this effect? I'll investigate more to see if mine or repentantgeeks changes caused this.
-
RE: Pendant/dwc to hundredth
@unrepentantgeek Thanks, I'll try your solution.
I also just spotted an obvious mistake in my own 5th attempt. The If conditions should have == instead of =. I may try that as well just to get some satisfaction if it works.
-
RE: Pendant/dwc to hundredth
+1 on this, especially the pendant. Would really like higher resolution on this since I use it primarily to set zeropoints, having it hardcoded to .1mm is a waste of precision. Also having up to 10mm steps on a jogwheel is totally overkill since you can rotate the wheel so much faster than you can press a button. I've tried desperately to modify the pendant code myself so I can get 100th of a millimeter but I just cannot make it work no matter what I try.
Original code:
output.print(distance/10); output.write('.'); output.print(distance % 10); output.write('\n');
attempt number 1:
output.print(((float) distance)/100);
attempt number 2:
char dist[4]; sprintf(dist, "%.2f", ((float) distance)/100) output.print(dist);
attempt number 3:
char dist[4]; sprintf(dist, "%.2f", ((float) distance)/100) for (char a : dist){ output.write(a); }
attempt number 4:
String dist=String(1.00); dist=String(((float) distance)/100); output.print(dist);
attempt number 5 (getting desperate here):
if (distance=1){ output.write('0'); output.write('.'); output.write('0'); output.write('1'); } if (distance=10){ output.write('0'); output.write('.'); output.write('1'); } if (distance=100){ output.write('1'); }
No luck. None of these work at all, they compile without issue but when connected the machine won't even respond to the jogwheel (pendant E-stop works though, so the code is running).
Admittedly i suck at programming, but thought I could at least manage to change the scale of a numerical command. Slightly depressing...
-
RE: G54 not persistent across power cycles
@dc42 Thanks for pointing this out, M500 P10 would do it. I thought saving these offsets happened by default. I'll add this to my "set zeropoint" macros. For a moment I thought about adding it to an M911 command to save on shutdown and get the behavior I was expecting, but then i realized M911 will not execute on a soft reset or emergency stop, right?
-
Servo signal for spindle
Hi! I have a feature request.
I would love if spindles could be defined that output a RC servo signal instead of a 0-100% duty cycle PWM. I'm using a brushless motor as a spindle, and I'm sure you've seen on the internet that I am not alone in doing so. Right now I'm controlling it using the M280 command, but this does not translate from RPM and is not compatible with any standard post-processor for CAM softwares. Also: Servos can not be defined as tools, which has implications when trying to implement a toolchanger which I plan to do.
For syntax, I suggest M950 C"pin" Rnn S Laaa:bbb
Where a naked S without a value indicates that the spindle should use a servo signal. Admittedly this in inconsistent with the current definition of M950 which does not allow having S and R in the same line, but perhaps that is acceptable. If possible it would also make sense for aaa and bbb to allow negative values, to intuitively define counter-clockwise rotation. Adding the Q parameter to this line should probably produce an error, unless the current servo implementation supports different frequencies?
Expected behavior:
M950 C"outputpin" R1 S L-10000:10000
should define spindle1 using servo signal on outputpin with max rpm 10000 in both directions.
M563 P1 R1
should define this spindle as as tool 1.
M5
should set active spindle to 0 rpm as interpolated between aaa and bbb (in this example outputpin to 1,5 ms pulse length). But not define rpm to 0 as interpreted by M3 or M4. Issuing an M3 or M4 without the S parameter after having issued an M5 should make the spindle resume last used RPM. I'm not entirely sure what the G-code standards say about toolchanges in this context, if the tool has changed (and/or the active spindle has changed), should the new tool/spindle inherit the last used RPM? I think it should, if you want another speed you should actively command this by including the S-parameter.
M3 S"5000"
should make outputpin generate 1,75 ms pulse length
M4 S"5000"
should make outputpin generate 1,25 ms pulse length
It may be wise to have the M950 command always initiate the output to 0 rpm upon define, to make sure that a connected ESC if powered intiatites properly and does not move. Alternatively it could be a recommendation in the G-code manual to always issue an M5 command directly after the define, but this would imply the M5 should have an additional argument to allow disabling any of the defined spindles, if there are more than one.
This may not be a high priority feature, but on the other hand since the duet can already output this type of signal I'm hoping that it's so easy to implement that it can be added pretty quickly. It would help me a lot, and I'm sure I won't be the only one to use this feature in the future.
This could also be achieved by more powerful parameters for the rpm, although it would be less user friendly. For an example, you could expand the L parameter to Laaa:AAA:bbb:BBB where aaa=minimum PRM, AAA is minimum duty cycle, bbb is max RPM, and BBB is the maximum duty cycle. If aaa and bbb also accepts negative values this would allow any type range of pwm to be defined, including 0-10v or 0-5v VFDs or industrial servo drives where 0 rpm is somewhere in the middle and they can rotate both ways. But it is important in all these cases that the M5 command outputs 0 rpm and not 0 pwm (plus pulling spindle enable pin low, if defined).
-
G54 not persistent across power cycles
As the topic says, I'm having the issue that my work coordinate systems are not persistent across power cycles. If I set G54 to some value (let's say x100 y150 z30), I can work with this only as long as I do not turn the controller off. If I perform an emergency stop or a cut power, then after restarting and homing G54 now reads X0 Y0 Z0.
I'm running a duet 3 6mbhc with firmware version 3.3. I am running it in standalone configuration and I am in CNC mode.
I'm certain that work coordinate systems should be persistent over power cycles, I've read this in multiple forum posts and it is also the behavior I would expect and need to use the machine efficiently. But for me this is just not the case. Where do I start looking for a solution to this?
-
RE: EXPERIMENTAL FreeCAD PostProcessor
Thanks for sharing this, I'll be trying it out in a week or so. I'm using the GRBL post processor so far which seems to work alright, but I'm sure there will be situations where this is better. I'll probably also be trying some modifications, for an example I've made my own brushless outrunner spindles that are controlled by a servo signal rather than a conventional spindle PWM so it would be great if I could have the postprocessor output
M280 P'servo number' S'pulselength'
where rpm is converted to pulselength by the postprocessor, instead of
M3 S'rpm'
It would be even better if the firmware would support this, to define spindles that uses servo signals instead of normal PWM. But modifying the firmware is more than I can manage. Also if I modify the firmware I will have to do it again whenever I want to upgrade, whereas a post processor will most likely work the same in the next version of FreeCAD.
I'll let you know how it works.