rfm - RepRapFirmware FileManager [duetbackup successor]
-
@fma I'm glad it was that simple.
-
Release v1.1.1
v1.1.1 has been release and can be found at GitHub Releases page.
Changes
- New
-debug
option to output the HTTP requests being sent to RRF - Add CRC32 checksum as HTTP header to file uploads (supported by RRF 2.04RC3 and newer).
- New
-
This post is deleted! -
@wilriker Is it possibble to upload a file and start the print?
Best
-
@PCR No, this is not a feature of
rfm
. It was and is intended to manage files on the SD card but not further interaction with the RepRapFirmware. -
Ah OK. Thank you! BTW will it work with an DUET3 with a PI?
Best
-
@PCR said in rfm - RepRapFirmware FileManager [duetbackup successor]:
BTW will it work with an DUET3 with a PI?
No, it won't because in that setup the files are located on the RPi and for Linux there are much better file managers than I could ever come up with.
-
It would be nice to have rfm support RRF3 with SBC for consistency's sake though (-:
-
@oliof I second this
-
I was just directed to RFM for backing up our Duet. Thank you to @wilriker it's amazing!
However, getting it started was a little slower than it needed to be. If you are on Windows and looking for a way to backup your Duet, here is a quickstart guide / manual that might help speed things up for you. (The guide may help if you aren't on Windows, but you'll need to adapt file paths etc as appropriate).
Download and unzip to C:\Users\YourUserName and name the folder 'DuetBackupRFM' Open Command prompt (Start - cmd - enter) which will open at c:\Users\YourUserName Chang the cmd prompt folder to the one you just unzipped to: Type: cd DuetBackupRFM ; and hit enter Now you are ready to use RFM to backup your Duet. Read below. RFM Duet Backup Commands: **note: must use program name, command name, then can use options and parameters/arguments. **ONCE a device has been specified (a device profile is created on first use), you can refer to the device without networking options by using the device name. RFM Command Syntax Explanation: Valid Example command: rfm backup -device YourPrinterName sys 0:/sys Explanation: rfm backup -device YourPrinterName sys 0:/sys program name command name option name parameter for option local comp. folder to save to Duet folder to do command to Things you likely want to do: STEP 1. connect to the Duet (creates a config for the Duet as the -device name) and list The Duet's root directory: rfm ls -domain 192.168.1.12 -port 80 -password YourDuetPassword -device YourPrinterName STEP 2. Backup the sys folder on your duet (already created in step 1 in RFM) into a folder on your computer called 'sys' (which will be located in the same folder RFM.exe is located). Note: RFM will create the folder on your computer if it does not exist. RFM will also use UNC / absolute paths if preferred (so you can redirect outside of the RFM folder - see examples at end). rfm backup -device YourPrinterName sys 0:/sys STEP 3. Backup the macros folder for your duet (already created in RFM) to a local 'macros' folder: rfm backup -device YourPrinterName macros 0:/macros STEP 4. Backup the filaments folder for your duet ((already created in RFM) to a local 'filaments' folder: rfm backup -device YourPrinterName filaments 0:/filaments STEP 5. Backup the gcode files on your duet (already created in RFM) to a local 'macros' folder: rfm backup -device YourPrinterName gcodes 0:/gcodes - - Some other Examples: - - List all the files in the folders in the root of your duet: rfm backup -device YourPrinterName List all the files in the sys folder on your duet: rfm backup -device YourPrinterName 0:/sys List all the files in a folder on duet with spaces in its name: rfm ls -device YourPrinterName "0:/macros/calibration/bed leveling" If you are using spaces in your RFM backup path or on duet - enclose in quotation marks: rfm backup -device YourPrinterName "C:users/yourusername/DUET BACKUP RFM" "0:/macros/calibration/bed leveling"
-
Write script for bash (GNU/Linux) to backup all files.
#!/bin/bash # ---------------------------------- Parameters ------------------------------------- temp="temp" # Temp folder for backup output="backup_rrf_$(date +%F_%H-%M-%S).tgz" # Archive name for backup # ----------------------------------------------------------------------------------- mkdir -p $temp # Create temp folder ./rfm ls | while read line # Parse list of files and folders do if [[ `echo "$line" | grep "\[f\]"` ]] # Processing files then filename=`echo ${line##* }` ./rfm download "$filename" "$temp/$filename" echo "$filename - File downloaded" elif [[ `echo "$line" | grep "\[d\]"` ]] # Processing folders then foldername=`echo ${line##* }` ./rfm backup -exclude overlays "$temp/$foldername" "$foldername" echo -e "\n" else echo "$line - Strange line" fi done tar czPf "$output" "$temp" # Create archive rm -rf "$temp" # Delete temp folder
-
-
-
I am trying out rfm. I go into the folder that has rfm in it and do:
./rfm backup -domain 192.168.1.163
this backs up the /sys folder on the duet card that is at 192.168.1.163.
If I want to back up the macro folder on that Duet, what should the command look like? Based on the help section of rfm, I was trying ./rfm backup /macros -domain 192.168.1.163 but I get 'directory not found'. -
Hi @wilriker
This is a great project and I would like to implement it on my system, but I (generally) manage the system remotely.
Specifically, I have a Mac (in the house) and use the Microsoft Remote Desktop (RD) app to connect to my Surface Pro (in the shed), via a wired network, which is hard-wired to the Duet3 MB6HC control board running my CNC machine (I don't run the CNC machine remotely, before anyone asks!)
The first question I have is, should I install rfm on the Mac and run it from there, or install it on the Surface Pro and run rfm from the Mac (via RD), and the second question is, which version should I use if it's installed on the Mac?
I'm running RRF version 3.4.4
Thank you
-
@jens55 said in rfm - RepRapFirmware FileManager [duetbackup successor]:
If I want to back up the macro folder on that Duet, what should the command look like? Based on the help section of rfm, I was trying ./rfm backup /macros -domain 192.168.1.163 but I get 'directory not found'.
You need to switch the order of parameters:
rfm backup -domain 192.168.1.163 <local-path> 0:/macros
Note that
local-path
is mandatory if you specify a remote path. -
@Nightowl said in rfm - RepRapFirmware FileManager [duetbackup successor]:
The first question I have is, should I install rfm on the Mac and run it from there, or install it on the Surface Pro and run rfm from the Mac (via RD), and the second question is, which version should I use if it's installed on the Mac?
Actually this just depends on what is more convenient for you. As long as
rfm
is able to connect to RRF via network this does not matter.I personally would probably install it on the Surface Pro just because it is closer. But again, it just boils down to what is more convenient for you. Mine is installed on a Raspberry Pi that is lingering around somewhere in the house and runs a background task that periodically checks if it can backup anything or not.
If you want to install it an the Mac use
darwin
binary. Although this will not work on a M1 MacBook. When I compiledrfm
the last time there were not M1's around AFAIR. -
Thank you, @wilriker
Mine's an i5, so that would be OK - but logic, and your comments, tell me I should install it on the PC!
Thank you
-
@wilriker, thank you!
-
@wilriker
Further to my last post, I'm a bit of a biff with these newfangled things, so I need a couple of simple steps to follow - at least I think I do.I understand the file has to be run from the command line, but where would be the best folder to locate rfm? I appreciate it can be accessed wherever it is, but I would like to pre-configure everything, so it would be a simple process of 'clicking a shortcut' for the card to be 'backed up'.
I'm assuming all the folders (firmware, gcodes, macros, sys and www) should be backed up, but does rfm process them all (if the correct parameters are set, clearly) or do I need to run rfm for each folder?
This is what I think...
rfm backup Weeble O:/ //Libraries/CNC Files/Backups
...where Weeble is the device name, O:/the root of the SD card and afp://SynologyHome._afpovertcp._tcp.local/Libraries/CNC Files/Backups where the files are to be backed up to?
BTW, I haven't tested this yet!
Thank you.
EDIT: Is there a naming protocol for the backup files, or will they be overwritten every time they're backed up? P
-
@wilriker I am getting the following error when I run the RFM tool. I have attempted on mac and PC, and have tried multiple variants of the command, too. My duet is a Duet3MB6HC in SBC mode running RRF 3.4.5.
Here is a screenshot of the output from terminal:
Best,
Garth -
@Garth_42
rfm
is intended to be used with boards in standalone-mode. AFAIR SBC builds do not support the full HTTP interface for file management plus any SBC has much more powerful means to interact with files than I could ever implement.