CHDK install script for Mac here - CHDK Releases - CHDK Forum  

CHDK install script for Mac here

  • 2 Replies
  • 4572 Views
CHDK install script for Mac here
« on: 24 / April / 2011, 22:07:12 »
Advertisements
I wrote a shell script for Mac that will install CHDK (once you've downloaded the correct version!), no hex editing required.  I did this before I noticed Owen had written one in Applescript, so I didn't even give his a shot.  But if anyone likes doing things in Terminal, this will make it less tedious.

To get it, just run the following command in Terminal.  I'd recommend you first cd into the same directory that the CHDK files you downloaded are in.

wget -qO install_chdk.sh http://zwisslertech.com/projects/chdk/install_chdk.sh && chmod 755 install_chdk.sh

That will download it, put it in your current directory and fix the permissions.  To run it, just type:

./install_chdk.sh

If you're in the same directory as the DISKBOOT.BIN this should be all you need to do, as it will try to automatically find your SD card device.  But if you want to manually spec your SD device, or the path to your CHDK binaries, there are flags for that:

bash-3.2$ ./install_chdk.sh -c ~/s95_100e_v11
Finding SD device......found /dev/disk1
Would you like to proceed using device /dev/disk1 (reported size is 16.1 GB)? (y/n): y
Disk size is 16.1 GB, using multiple partitions
diskutil: Started partitioning on disk1
diskutil: Unmounting disk
diskutil: Creating partition map
diskutil: Waiting for disks to reappear
diskutil: Formatting disk1s1 as MS-DOS (FAT12) with name CHDK
diskutil: Formatting disk1s2 as MS-DOS (FAT32) with name Canon_DC
diskutil: Finished partitioning on disk1
diskutil: /dev/disk1
diskutil:    #:                       TYPE NAME                    SIZE       IDENTIFIER
diskutil:    0:     FDisk_partition_scheme                        *16.1 GB    disk1
diskutil:    1:                 DOS_FAT_12 CHDK                    4.0 MB     disk1s1
diskutil:    2:                 DOS_FAT_32 CANON_DC                16.1 GB    disk1s2
Unmount of all volumes on disk1 was successful
Making /dev/disk1s1 bootable for CHDK...
Your SD card has been made bootable.
Mounting filesystems...Volume(s) mounted successfully
Mounted to /Volumes/CHDK
Copying /Users/robzr/s95_100e_v11/PS.FI2
Copying /Users/robzr/s95_100e_v11/DISKBOOT.BIN
Creating ver.req
unmounting filesystems...Unmount of all volumes on disk1 was successful
To run CHDK, lock your SD card, insert in the camera and fire it up!
bash-3.2$

To get help, run it with -h:

bash-3.2$ ./install_chdk.sh -h
Usage: ./install_chdk.sh [-c path_to_CHDK_files] [-d SD_device_path] [-f] [-y]
       -c defaults to the current directory (.)
       -d defaults to autofind (with confirm)
       -f overrides sanity checks on SD device
       -y assumes yes to answer questions (non-interactive)

It is pretty conservative, does a lot of sanity checks and it asks you before writing anything, so it should be pretty safe.  Hope this can be of help to some!  (Also, I'm attaching a copy of the script to this post, so you can download from here instead of running wget).

Rob

Re: CHDK install script for Mac here
« Reply #1 on: 24 / April / 2011, 22:09:01 »
Oh I should also add this script will automatically partition your SD card and format it as either a single FAT-16 partition (if it's 4 GB or less), or as a 4 MB FAT-12 CHDK partition + a second FAT-32 partition for the remainder if the card is larger than 4 GB.

Rob

*

Offline zeno

  • *****
  • 891
Re: CHDK install script for Mac here
« Reply #2 on: 25 / April / 2011, 04:36:43 »
My SDMInst app (http://www.zenoshrdlu.com/clickpansdm/sdminst.html) does pretty much what your script does (despite the name it will install CHDK as well as SDM).
A570, S100, Ixus 127
Author of ASSIST, STICK, WASP, ACID, SDMInst, LICKS, WICKS, MacBoot, UBDB, CFGEdit

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal