• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Convert bash script to windows

Hi, I have a problem with my FZ20 camera, 2gb SD card and TIFF pictures. Every time I take a TIFF picture with my camera on my 2gb card, it corrupts the file. This guy on Flickr made a bash script that cut out a 16kb block from the picture, "decorrupting" it but it's in bash.

Can any of you wizzie help me get this to work on my Windows XP machine? I'll install some software to make my Windows box recognize bash command if necessary.

Thanks!

The code :

#!/bin/sh

for FILE in "$@"
do
echo "Fixing file $FILE"
dd if=$FILE of=1 bs=16384 count=1
dd if=$FILE of=2 bs=16384 skip=2
cat 1 2 > temp/$FILE
rm 1 2
done
 
You could always use cygwin or MinGW.

Does the manufacturer know about the problem? Ultimately they should be the one releasing a firmware update for the camera, or a software workaround.

After you get cygwin you should put the code of that script in a file called "fixtiff.sh" (or whatever). Then, make it executable:

cd /folder/containing/script
chmod u+x ./fixtiff.sh

Each time you want to execute it:

cd /folder/containing/script (if you haven't already)
sh fixtiff.sh

-or-

sh /folder/containing/script/fixtiff.sh (although if you use this secondary method you may have to modify the script to use something other than the working directory)
 
Ok, I have this problem now :

Heretushi@amd64 ~
$ chmod u+x ./fixtiff.sh

Heretushi@amd64 ~
$ ./fixtiff.sh
: command not found2:
'/fixtiff.sh: line 4: syntax error near unexpected token `do
'/fixtiff.sh: line 4: `do

I downloaded Cygwin latest version, installed all default setting. I copied my file in my home dir (/home/Heretushi). And here I am. Any input?
 
And to answer your question :

1- Yes the manufacturer knows about this.
2- The official response that I know of is : "Your camera supports up to 1gb cards in TIFF mode".

I don't know of any firmware update or software workaround officially supported by Panasonic.
 
Back
Top