Somehow, I managed to pocket-dial my way to a factory restore on my Android phone. Yeah... no idea how. Anyway, while I'm quite good at backing things up, I have lost about 10 days worth of journal entries, a few photos, and some GPS tracks. Certainly not the end of the world, but annoying.
So, I figured this is a good time to see what is recoverable from internal storage on an Android device after a format. I'm no expert here, and I'm writing this as a way of taking notes. This isn't intended to be a how-to guide for everyone that's made a foolish mistake. It's not intended to be a complete reference for experts either. It's just what I did while learning how to do it. I write notes as I go, and I figured I might as well share. If you find this useful, then buy me a cup of coffee.
So, surprise, surprise... I've got 24GB of free space in my internal storage. Nice shiny new unconfigured interface, factory default everything except the scratches. Dang!
As I write this, I'm copying said 24GB to an image file on my desktop system. I'll run some recovery tools on that when it's done. Here's how I got to this point:
For some reason, my phone has the option to mount internal storage as an SDcard via USB, but nothing shows up on my Linux desktop. Switching to MTP shows the file system, but that's pretty much useless for me as there's nothing there but what comes stock. By design, the raw storage is not available.
So, I installed the Android Development Toolkit:
sudo apt-get install android-tools-adb
That would show a connection via:
adb devices
but said "insufficient permissions for device"
So, I rooted the device. I wasn't keen on that as any writes to the device risk wiping the data I want to recover, but whatever. I chose KingRoot. Whatever works for your device. That made no difference. Sigh...
I found out that I should restart the ADB service via sudo:
adb kill-server
sudo adb start-server
That worked, I can now run ADB commands against the device.
Next up, I needed to figure out what partition to copy. I used:
adb shell su -c "cat /proc/emmc"
and then:
adb shell su -c "cat /proc/partitions"
to cross-reference the partition for "userdata". In my case, it was /dev/block/mmcblk0p22
Then, I copied the entire partition to my desktop via:
adb shell su -c "dd if=/dev/block/mmcblk0p22" > ~/backup22.image
Anyway, that command is half-way finished now. Considering this will be a 24GB file, from here on in, the commands I run are going to take their sweet time. I'll update this as I go... maybe I'll actually get that 2KB of journal text file recovered, maybe the 20MB of photos, and a few other MB of map tracks. Maybe I won't. At least I've learned a few things already.
Hope this helps...
Update 1:
The first try at capturing the image stopped at 10.1GB. The next ran to 27GB(?). Neither Testdisk nor Photorec managed to get anything useful off either. As well, after having decided to get it over with and factory-reset my phone to get rid of KingRoot, which seems rather invasive, I discovered that pocket-dialling my way to a factory-reset is near impossible. The system is designed to avoid this. Thus, something else must have happened. Maybe, it crashed and scrambled the partitions enough that the phone decided to rebuild the file system? Just guessing at this point. In any event, I've decided to grab everything I can off the phone before doing the reset. Thus:
adb shell su -c "dd if=/dev/block/mmcblk0" > ~/backupAll.image
I'll let that run tonight and see what I can get off it later.
Update 2:
A factory-restore does not remove KingRoot. Apparently, using its own uninstall does. At least it appears to be gone. Note that the above adb shell su ... commands no longer work, so my phone does not come rooted and does require this for access. Still not having any luck with testdisk on the latest dd image.
Showing posts with label Linux. Show all posts
Showing posts with label Linux. Show all posts
2017-01-06
Getting Started with a MonoPrice Select Mini 3D Printer
This post documents my entry into 3D printing via Linux. Obviously, I'm no expert. Rather, this is where I'm recording what I learn along the way. The intent is, more or less, just sharing my study notes. I needed a place to write things down... might as well share. Nothing original here, no great insights, just organising information in a way I find useful so I can find it again. That's all. If you find it useful then buy me a cup of coffee.
This is a living document... Still printing, and starting to figure out the Cura settings. Now experimenting with TPE-80A filament.
I decided to get into 3D printing with a MonoPrice Select Mini 3D Printer. Why? Because it's cheap, because it's getting rave reviews, and because there seems to already be a great community building up around it.
The graphics gcode terminal: Pronterface.py from Printrun. This is used to set some parameters, upload gcode files to the SD card via USB, and can directly print a gcode file as well.
This is a living document... Still printing, and starting to figure out the Cura settings. Now experimenting with TPE-80A filament.
I decided to get into 3D printing with a MonoPrice Select Mini 3D Printer. Why? Because it's cheap, because it's getting rave reviews, and because there seems to already be a great community building up around it.
Background Info:
- The best newbie startup guide I've found so far is here:
http://www.thetylergibson.com/3d-printing-for-the-absolute-beginner-monoprice-select-mini-2/ - The review that set off this particular adventure is here:
http://hackaday.com/2016/06/13/review-monoprice-mp-select-mini-3d-printer/ - The WIKI is here:
http://mpselectmini.com/ - The google Doc:
https://docs.google.com/document/d/1HJaLIcUD4oiIUYu6In7Bxf7WxAOiT3n48RvOe5pvSHk/edit
The Tools:
The slicer: Cura This is the part that takes the model and converts it to printer-specific gcode.
- Install under linux via custom PPA:
sudo add-apt-repository ppa:thopiekar/cura - Update and then sudo apt-get install cura
- Add custom printer to Cura with settings from Tyler Gibson's blog (above).
- Add your material(s) with specifications.
- Apparently, it's possible to import settings from a demo gcode file supplied with the printer. (never bothered). I've learned that it will only do this if the gcode was created by Cura and the versions are compatible.
- Cura's interface is a bit odd and takes some figuring to get the profile info to stick. It also updates daily via the PPA, or so it seems so far. But, it seems to do well as a slicer.
- Linux prep:
sudo apt-get install python python-serial python-wxgtk3.0 python-tk git-core python-pyglet python-psutil python-numpy - Use GIT to get the scripted app:
git clone https://github.com/kliment/Printrun.git - Running via commandline: (seems to require admin privs)
cd Printrun
sudo ./pronterface.py
- Adding a 3D printer model involves going into the 3D Print environment, Other printers, and making some change to any existing printer (like setting it to default). This creates an xml file under %appdata%\Autodesk\Inventor 2017\3DprinterDescriptions.xml. Manually edit that file, duplicating a line, and setting a random GUID and other values as appropriate.
- Download and install Print Studio (a free Autodesk add-on)
- Restart
- At that point, using the 3D Print environment and from there running Print Studio gives various options under the media type (advanced tab).
- Settings do not seem to be quite as fine as with Cura, but there are more options for editing supports.
Fusion 360: The free for hobby/student CAD to gcode option.
- Starting to use this for a variety of reasons. I quite like it actually. It uses the same Print Studio that Inventor does, and I've still not figured it out. Still using Cura.
- I am starting to really like Fusion 360. Even the Render environment is a lot of fun.
Things to do after unpacking the box:
- Update firmware (seems to be 2 halves). Mine is 24.42, newer than the blogs say.
- Enable and configure the WIFI settings. Not yet.
- Change PID setting for printhead temp regulation and, optionally, the table heater regulation. Used Printrun's pronterface to set them to values in Tyler Gibson's blog.
- Apply table covering of choice. (I've bought tape but it appears tablet screen glass protectors are now the rage). Mine came with tape, so I left it. Had to trim off the corners to get at the levelling screws.
- Level table and set print height. Uses the same 4 screws. Mine appears to be slightly crowned, so I set it for the middle. Note that using pronterface to move the table around is way easier than the printer menu and jog wheel.
- Lots of reports of loose screws and connectors, so a once-over may be in order. Didn't bother, feels nice, no odd noises.
- Set up the printer and filament in Cura, mostly as per Tyler Gibson's blog.
- Print the first demo (as specified in the manual) and adjust the print height accordingly. Didn't bother, went straight to printing a token I made in TinkerCAD, exported as an STL, sliced with Cura to gcode, then loaded the gcode into pronterface and told it to print. Came out well. Once it was finished, I raised the bed temperature to 70deg and popped the trinket off. Pictures in a bit.
So, all things considered, it works way easier and better than I had expected. It was, as intended a very easy first print, but still...
I think I'm going to have a lot of fun with this.
Second Print
Feeling lucky, I decided to print a bigger file that I downloaded. A smartphone stand: (3.5 hr print)- I uncompressed the ZIP.
- Loaded the STL into Cura.
- Rotated to print it on its side.
- Chose a "grid" fill for this print as it seemed more sensible.
- Cura said it was nearly a 3hr print. Good enough as a real test.
- Saved the gcode file.
- Loaded the gcode file into Pronterface.
- Connected the printer (in menu - printer was already connected via USB)
- Chose SD from the bar above the model pane.
- Chose to Upload (note the status bar at the bottom that shows progress).
- When done, I used the printer menu to print it.
- I disconnected Pronterface during the print. No untoward effect on the printer.
- The printer is not that noisy, though it gets annoying when everything else is quiet. I actually find it very difficult to sleep with, even in the next room. Just something about the non-regular whistling and lower tones mixing together... no more overnight printing for me.
More Prints
Going great. I'm still printing at what I've found is "medium" resolution, with a layer height of 0.175. No issues with adhesion at the start, and all the prints are turning out better than I had expected. Settings as follows:
- Bed temp of 50deg to print, cranking up to 60deg to separate when done.
- Layer height of 0.175
- Wall thickness set to .8 (x2) for some prints. A bit thin but works. I'd say the finish is a little rougher though.
- Speed is 50, with a wall speed of 25.
Starting to run out of the obvious test things to print so now it's a matter of getting into the editing side. Oh, and I created superfine to superrough profiles in Cura to match the layer thicknesses as suggested in the wiki, with other settings that seem to match (just guessing at this point). The 0.175 seems to be about middle. Haven't tried these alternative settings yet.
My Cura Settings
I'm not recommending these... I've no idea what I'm doing yet, but these are the settings I'm playing with at the moment and needed to write them down. This is as good a place as any. Note that the settings includes a page that makes these settings visible.PLA-SuperFine:
- layer height = 0.0437
- initial layer height = 0.175
- line width (all) = 0.4
- Wall thickness = 0.4 (1 count)
- Top/bot thickness = 0.6
- Top/Bottom Pattern = Concentric
- Infill = 15%
- Pattern = defaulting to grid but may change depending on print
- Printing temp = 210 (pla)
- Printing temp initial layer = 215
- Build plate temp = 50
- Material diam = 1.75mm
- Material flow = 100%
- Enable retraction
- Print speed = 30mm/s
- Infill speed = 30mm/s
- Wall speed = 20mm/s
- Top/Bottom Speed = 15mm/s
- Travel speed = 100mm/s
- Initial Layer speed = 15mm/s
- Skirt/Brim Speed = 15mm/s
- Number of slow layers = 2
- Enable print cooling
- Support = default to off, model dependent
- Build plate adhesion = default to skirt, model dependent
- Skirt minimum length = 350mm
- Print sequence = all at once
PLA-Fine:
- layer height = 0.0875
- initial layer height = 0.2188
- line width (all) = 0.4
- Wall thickness = 0.8 (2 count)
- Top/bot thickness = 0.8
- Top/Bottom Pattern = Concentric
- Infill = 20%
- Pattern = defaulting to grid but may change depending on print
- Printing temp = 210 (pla)
- Printing temp initial layer = 215
- Build plate temp = 50
- Material diam = 1.75mm
- Material flow = 100%
- Enable retraction
- Print speed = 40mm/s
- Infill speed = 40mm/s
- Wall speed = 20mm/s
- Top/Bottom Speed = 20mm/s
- Travel speed = 120mm/s
- Initial Layer speed = 20mm/s
- Skirt/Brim Speed = 20mm/s
- Number of slow layers = 2
- Equalize filament flow
- Enable print cooling
- Support = default to off, model dependent
- Build plate adhesion = default to skirt, model dependent
- Skirt minimum length = 350mm
- Print sequence = all at once
PLA-Normal:
- layer height = 0.175
- initial layer height = 0.3
- line width (all) = 0.4
- Wall thickness = 1.2 (3 count)
- Top/bot thickness = 0.8
- Top/Bottom Pattern = Concentric
- Infill = 20%
- Pattern = defaulting to grid but may change depending on print
- Printing temp = 210 (pla)
- Printing temp initial layer = 215
- Build plate temp = 50
- Material diam = 1.75mm
- Material flow = 100%
- Enable retraction
- Print speed = 50mm/s
- Infill speed = 50mm/s
- Wall speed = 25mm/s
- Top/Bottom Speed = 25mm/s
- Travel speed = 120mm/s
- Initial Layer speed = 25mm/s
- Skirt/Brim Speed = 25mm/s
- Number of slow layers = 2
- Equalize filament flow
- Enable print cooling
- Support = default to off, model dependent
- Build plate adhesion = default to skirt, model dependent
- Skirt minimum length = 350mm
- Print sequence = all at once
PLA-Rough:
- layer height = 0.2625
- initial layer height = 0.3
- line width (all) = 0.4
- Wall thickness = 1.2 (3 count)
- Top/bot thickness = 0.8
- Top/Bottom Pattern = Concentric
- Infill = 20%
- Pattern = defaulting to grid but may change depending on print
- Printing temp = 210 (pla)
- Printing temp initial layer = 215
- Build plate temp = 50
- Material diam = 1.75mm
- Material flow = 100%
- Enable retraction
- Print speed = 60mm/s
- Infill speed = 60mm/s
- Wall speed = 40mm/s
- Top/Bottom Speed = 30mm/s
- Travel speed = 120mm/s
- Initial Layer speed = 30mm/s
- Skirt/Brim Speed = 30mm/s
- Number of slow layers = 2
- Equalize filament flow
- Enable print cooling
- Support = default to off, model dependent
- Build plate adhesion = default to skirt, model dependent
- Skirt minimum length = 350mm
- Print sequence = all at once
PLA-Super Rough:
- layer height = 0.3063
- initial layer height = 0.3063
- line width (all) = 0.4
- Wall thickness = 1.2 (3 count)
- Top/bot thickness = 0.8
- Top/Bottom Pattern = Concentric
- Infill = 15%
- Pattern = defaulting to grid but may change depending on print
- Printing temp = 210 (pla)
- Printing temp initial layer = 215
- Build plate temp = 50
- Material diam = 1.75mm
- Material flow = 100%
- Enable retraction
- Print speed = 75mm/s
- Infill speed = 75mm/s
- Wall speed = 37.5mm/s
- Top/Bottom Speed = 37.5mm/s
- Travel speed = 120mm/s
- Initial Layer speed = 37.5mm/s
- Skirt/Brim Speed = 37.5mm/s
- Number of slow layers = 2
- Equalize filament flow = off
- Enable print cooling
- Support = default to off, model dependent
- Build plate adhesion = default to skirt, model dependent
- Skirt minimum length = 350mm
- Print sequence = all at once
TPE-80A-Normal:
- layer height = 0.175
- initial layer height = 0.3
- line width (all) = 0.4
- Wall thickness = 1.2 (3 count)
- Top/bot thickness = 0.8
- Top/Bottom Pattern = Concentric
- Infill = 40%
- Pattern = defaulting to grid but may change depending on print
- Printing temp = 240
- Printing temp initial layer = 240
- Build plate temp = 0 (using double-sided tape on top of masking tape)
- Material diam = 1.75mm
- Material flow = 100%
- Enable retraction = No
- Print speed = 20mm/s
- Infill speed = 20mm/s
- Wall speed = 20mm/s
- Top/Bottom Speed = 20mm/s
- Travel speed = 60mm/s
- Initial Layer speed = 20mm/s
- Skirt/Brim Speed = 20mm/s
- Number of slow layers = 2
- Equalize filament flow = No
- Enable print cooling
- Support = default to off, model dependent
- Build plate adhesion = default to skirt, model dependent
- Skirt minimum length = 350mm
- Print sequence = all at once
More Printing
Had some failures, mostly with adhesion. I was printing a model downloaded from ThingiVerse, a Dremel nose finger guard, and part of it kept breaking free during the print. I first tried replacing the stock masking tape with some green painter's tape and that was worse. After much futzing around with using brims instead of skirts, adding supports, and sanding the tape, I managed to get a print that stuck. After that, I realised that the tape is way slipperier than regular masking tape. I replaced the tape and had better luck, though still not as good as the factory tape. I've got a couple of iPhone 5S tempered glass screen protectors on the way from China... which are supposed to be the solution to this problem. Time will tell.... (update) and, no. I had no luck with the glass and went back to regular masking tape, sanded a bit, and now with glue stick before each print. Seems to work well enough. I may try the glass with glue stick at some point, but I'll also see if I can find any of that fabled "blue painters tape" everyone keeps mentioning.
Another print, a whistle (another ThingiVerse download) also failed due to adhesion. This time it lifted up on one side from warping, but I let it print through. That was a mistake as... well... it's a whistle and compressing the tube you blow in kind of changes things. Live and learn. Anyway, after my initial success, I've now got a small but growing collection of failed prints. More successful ones as well... that ThingiVerse can be quite addictive and the printer has been working hard. The first roll of filament is noticeably down so I've ordered 2 more PLA. I think I'll avoid ABS until it's warm enough to put the printer outside while printing.
Note that I'm uploading designs and prints on PinShape. No point duplicating the pictures here.
Note that I'm uploading designs and prints on PinShape. No point duplicating the pictures here.
Filaments
I've ordered a 12-roll variety pack from Filament.ca as well as some TPE-80A and Nylon-645. At this point, I've spent more on filament than the printer, which I consider to be a good thing. I'll be working through the various types, seeing how they do, over the next while.TPE-80A Filament
I've been experimenting with this soft filament, somewhat rubber-like though it's not. I'd say if feels like it would make good drive belt material. That kind of strength and texture. Actually, I'd say the filament would be a very useful addition to the toolkit, but it is quite difficult to print with. First off, it is too soft to easily feed down the Bowden tube, instead going out sideways at the feed mechanism. Thus, I had to make a part to fill in the spaces so it couldn't escape. That part is here: MSM MK-IV Space Eraser, on PinShape. Solving that problem, the next issue is that it appears to shrink so much after printing that getting it to stay stuck to the bed is near impossible. After a few failed attempts, I decided to use double-sided carpet tape on top of masking tape (to protect the bed). It stuck quite well to the carpet tape but I still had issues with the carpet tape separating from the masking tape. Yeah, it pulls that hard. The next issue appears to be that it slips when trying to feed directly from the spool, and that causes missing lines in the print. The solution to that will be some kind of ball-bearing roller for the spool. Yes, a lot of hassle, but if I can figure out this filament, the rest should be easy.
Some Pictures
Some downloaded models from Thingiverse and PinShape:
The surprisingly hard thing to print:
And, some stuff I drew in Inventor and uploaded to PinShape
The surprisingly hard thing to print:
And, some stuff I drew in Inventor and uploaded to PinShape
Tomy Plarail track bits...
Current Stats:
Nearly 1KG of PLA printed, with about 17% of that as waste. Yeah, I've been keeping all my failures, and supports, in a bag so I can weight it. Just curious.
2016-04-30
My Linux for Kids Notes
This is not a "how to" guide, a definitive list, nor even a recommendation for what to do for your kid. It's simply my notes. I needed to keep them somewhere, I needed a place where I could update them easily, and I wanted it "in the cloud" so I could always find it. Oddly enough, a blog is actually a good place to do this. I don't mind sharing my notes and if you find them useful... good for you. If you have some other recommendations, feel free to comment.
I'll be updating this as I go...
The list of linux apps I install, suitable for cut and paste into a sudo apt-get install command for a debian-based linux distro, because that's how I do it:
Via playonlinux, install:
Other stuff to remember:
* Celestia - no current install candidate.
I'll be updating this as I go...
The list of linux apps I install, suitable for cut and paste into a sudo apt-get install command for a debian-based linux distro, because that's how I do it:
sudo apt-get install gcompris tuxpaint tuxpaint-config tuxmath tuxtype ktuberling stopmotion playonlinux extremetuxracer neverputt pingus funnyboat pysiogame stellarium stellarium-data supertuxkart sugar connectagram
Via playonlinux, install:
- 3d train studio - downloads free version via script. Pretty awesome for kids that like trains.
- 20 trains (running) is a fun one to download.
- gcompris - a big bundle of kids games, puzzles, and educational activities. Highly recommended.
- tuxpaint - awesome painting program with lots of stamps. The config allows various settings.
- tuxmath - still seeing if my kid likes it.
- tuxtype - my kid loves this typing tutor, from about 1yr old. Seriously.
- ktuberling - Mr Potato Head goes cyberspace.
- stopmotion - makes stopmotion - still testing this one
- playonlinux - scripts to install many Windows apps under wine. Most, but not all, require the CD
- extremetuxtracer - 3D racing game, with Tux sliding down a ski slope.
- neverputt - a minigolf game
- pingus - a funny game for kids that like penguins, and what kid doesn't?
- funnyboat - great kids game.
- pysiogame - another educational game suite like gcompris, slightly more advanced.
- stellarium - study the planets and stars.
- supertuxkart - 3D racing game in go-karts.
- sugar - the One Laptop Per Child OS. Still experimenting.
- connectagram - word de-scramble game.
Other stuff to remember:
* Celestia - no current install candidate.
Subscribe to:
Posts (Atom)







