SCROLL

finalProject 0000 0001 CAD 0010 cutting 0011 programmer 0100 3Dprinting 0101 elecDesign 0110 makeBig 0111 embedProg 1000 moldCast 1001 inputs 1010 outputs 1011 networks 1100 machine 1101 interface 1110 wildcard 1111 notes

Notes

SEARCH THIS PAGE ( COMMAND + F ) FOR KEYWORDS

Documentation

I started off documenting by hand in a notebook and taking photos with my phone. I would then type up the documentation more completely in html. I had to upload photo's, name each one, put it in the correct folder (after compressing) then link to it in my html. This was quite a process, one that was eating up way to much of my time.

Over the last couple weeks I have been experimenting with using Typora, a markdown editor, for note taking (this page is being written in Typora). Typora has proven to be a great tool for writing HTML (you can export your file as html) without having to tag all of my headers, lists, bold and italicised text.

Images have still been taking a long time as between screenshots and photos from my phone they're all stored in different places. This week I had to find all the photos, consolidate them in one folder, name them and link to them correctly in Typora, not for where they were currently, but for where their copies would end up in my class folder. This was an extremely tedious process so today I went in search of a solution.

Image Solution

Style Solution

I have a separate stylesheet for my site that I was linking to for my earlier hand-written HTML pages. I actually prefer the Typora style now, but I would like to keep the side navigation menu on the pages I write in Typora. Here's how to do that:

Screen Shot 2019-10-08 at 11.02.42 PM

 

 

Typora will recognise the HTML and hide it from view. It will even try to render the content.

Once you export the whole doc in HTML to your site directory it will look like the page you're on now.

 

Laser Cutting

I've been having issues with significant numbers of lines missing when opening DXF files created in Fusion360 in the Thunder Laser software. Not entirely sure on why this happens, but judging by my google searches, it effects a lot of people trying to do similar things.

The work around I found is to import the Fusion DXF into Rhino and then export it using the lowest line count (2007). The Thunder software can then render all of the lines properly. From what I can tell there is no (visible) loss to the geometry.

 

CAD and 3D printing

 

ffmpeg

Compression and other manipulations of video and audio files

for mp4:

ffmpeg -i inFile.mp4 -crf 18 outFile.mp4

-i = input

-crf = quality control (lower the number - higher the quality)

 

bitrate

audioBitrate

 

change screenshot save location

Terminal:

defaults write com.apple.screencapture location User/donaghmahon/Desktop/screenshots

Alternatively:

command + shift + 5 > options

^ this is also how to screen record

 

HTML and CSS

Photoshop - Batch Image Compression and Conversion

File > Scripts > Image Processing

 

ImageMagic - batch image compression and conversion

CAREFUL WITH MOGRIFY - OVERWRITES FILES

mogrify -format png *.jpg

mogrify -quality 50% -resize 500 -format png *.png

USE CONVERT TO WORK ON INDIVIDUAL IMAGES

convert coolTermOutput.png -quality 50% -resize 500 ~/harvardsite/Harvard_machine_2019/media/coolTermOutput.jpg

ROTATE IMAGES BASED ON EXIF DATA

mogrify -auto-orient *.JPG

 

git and terminal commands

git status

git add .

git commit -m"comment goes here"

git pull origin master

git push origin master

cd = change directory

pwd = print working directiory

ls - list files in directory

ls -la = list is ling form (-l) and include hidden files (-a)

cd .. = move up one directory in file tree

du -sh -- * | sort -h = list files in directory by size

-h = human readable

open -a "Sublime Text" index.html = open file with particular application

touch newFile.html = create a new file

cp ./Typora/typImages/whyMerge.jpg ~/harvardsite/people/donagh/typImages/ = copy a file to another location

ioreg -p IOUSB -w0 | sed 's/[^o]*o //; s/@.*$//' | grep -v '^Root.*' = list usb devices

To create a shortcut command:

open ~/.bash_profile

Add this to bottom of file:

aliascommand + s to save and then quit terminal

Reopen terminal and test command

 

Issues

If when pushing or pulling and you get this:

whyMerge

Do this:

 

If you get this:

swp

 

Press 'D' to delete the incomplete git commit or git merge

 

If you get something like "Your branch and 'origin/master' have diverged, # and have 1 and 1 different commit(s) each, respectively.", do this:

Then git pull origin master and retry