Eos 400d ( Rebel XTI ) - page 180 - DSLR Hack development - CHDK Forum

Eos 400d ( Rebel XTI )

  • 1871 Replies
  • 879286 Views
Re: Eos 400d ( Rebel XTI )
« Reply #1790 on: 12 / September / 2013, 15:32:28 »
Advertisements
It's pretty important for us, to be able to upload files to the card. Please report if you succeed.
BTW what's the total price for the card and the adapter (reference price)

Hi.

:D :D :D :D !!!!!! Success !!!!!! :D :D :D :D

In fact it is soooo easy (though it took me a while to realize)

After following http://haxit.blogspot.de/2013/08/hacking-transcend-wifi-sd-cards.html with installing chrome in my linux-vm trying and all the other stuff described on this site for several hours I realized that you only have to do this:
  • Create a script (named autorun.sh) in the root of the SD card (did this using Win8 & Notepad++, Windows users be aware: some editors may have problems creating LINUX conform linefeeds)
  • copy the busybox-armv5l binary (download link is given on the site) also to the root of the SD

autorun.sh
Code: [Select]
cp /mnt/sd/busybox-armv5l /sbin/busybox
chmod a+x /sbin/busybox
/sbin/busybox telnetd -l /bin/bash &
/sbin/busybox tcpsvd 0.0.0.0 21 ftpd -w / &
(Change / to /mnt/sd in the last line in case you only want access the 'normal' CF-card area instead of the linux system running on the SD card)

Now you can either telnet (telnet 192.168.11.254 that's the SD cards default IP) into the SD-card or transfer files via ftp (tested up-/downloading using Firefox & FireFTP addon)

The cool thing is if you can create files via 400plus (e.g. just an empty file in any subdirectory) you could have a simple bash script watching for the existence of this file and execute another script (e.g. for transferring your pictures to a NAS, etc.) You may think of very fancy stuff as with this SD card you have another computer running in your camera. As somebody commented on the original hack site
Quote
Amazing!!
16/32GB flash, 32MB RAM, 400+ BogoMIPS processor, wifi connectivity...inside a SD card!!

Regards

BTW SD card was ~50€ incl. shipping via eBay, I already owned the Sd to CF Adapter but you should get one for ~20€

*

Offline 0xAF

  • ***
  • 220
    • 0xAF
Re: Eos 400d ( Rebel XTI )
« Reply #1791 on: 12 / September / 2013, 15:47:26 »
It's pretty important for us, to be able to upload files to the card. Please report if you succeed.
BTW what's the total price for the card and the adapter (reference price)

Hi.

:D :D :D :D !!!!!! Success !!!!!! :D :D :D :D

In fact it is soooo easy (though it took me a while to realize)

After following http://haxit.blogspot.de/2013/08/hacking-transcend-wifi-sd-cards.html with installing chrome in my linux-vm trying and all the other stuff described on this site for several hours I realized that you only have to do this:
  • Create a script (named autorun.sh) in the root of the SD card (did this using Win8 & Notepad++, Windows users be aware: some editors may have problems creating LINUX conform linefeeds)
  • copy the busybox-armv5l binary (download link is given on the site) also to the root of the SD

autorun.sh
Code: [Select]
cp /mnt/sd/busybox-armv5l /sbin/busybox
chmod a+x /sbin/busybox
/sbin/busybox telnetd -l /bin/bash &
/sbin/busybox tcpsvd 0.0.0.0 21 ftpd -w / &
(Change / to /mnt/sd in the last line in case you only want access the 'normal' CF-card area instead of the linux system running on the SD card)

Now you can either telnet (telnet 192.168.11.254 that's the SD cards default IP) into the SD-card or transfer files via ftp (tested up-/downloading using Firefox & FireFTP addon)

The cool thing is if you can create files via 400plus (e.g. just an empty file in any subdirectory) you could have a simple bash script watching for the existence of this file and execute another script (e.g. for transferring your pictures to a NAS, etc.) You may think of very fancy stuff as with this SD card you have another computer running in your camera. As somebody commented on the original hack site
Quote
Amazing!!
16/32GB flash, 32MB RAM, 400+ BogoMIPS processor, wifi connectivity...inside a SD card!!

Regards

BTW SD card was ~50€ incl. shipping via eBay, I already owned the Sd to CF Adapter but you should get one for ~20€


Thanks for the update. This info is refreshing.
Many possibilities with these SD cards. :)
Thanks again.
// AF

Re: Eos 400d ( Rebel XTI )
« Reply #1792 on: 12 / September / 2013, 16:04:54 »
Thanks for the update. This info is refreshing.
Many possibilities with these SD cards. :)
Thanks again.

You are welcome. Happy that I could give a small piece back to those who are creating this great stuff

Regards

*

Offline 0xAF

  • ***
  • 220
    • 0xAF
Re: Eos 400d ( Rebel XTI )
« Reply #1793 on: 12 / September / 2013, 16:28:39 »
You are welcome. Happy that I could give a small piece back to those who are creating this great stuff

Regards


We are all making great stuff, given that we live a life.
Some more, some less, but all of us are doing great things in our lives :)
Keep dreaming and you will be one of the important people in this world !

Thanks.
// AF

Re: Eos 400d ( Rebel XTI )
« Reply #1794 on: 13 / September / 2013, 15:28:59 »
Hi.

It'll be really cool if any of the devs would include new submenu in a new release - maybe called Transcend WiFi  :) - with two entries named 1 & 2 or On & Off that each would simply write an empty file (named correspondingly) at a predefined location (maybe in a directory called trans_wifi)

[!Transcend_WiFi >]
[1] writes the empty file 1 in directory trans_wifi on the CF card
[2] writes the empty file 2 in directory trans_wifi on the CF card

Of course the more the better.

That would allow me to try certain things with the wifi card (see few post above in this thread)

I'll write a corresponding feature request too.

Thanks in advance for considering to do or even doing it.

Regards

*

Offline 0xAF

  • ***
  • 220
    • 0xAF
Re: Eos 400d ( Rebel XTI )
« Reply #1795 on: 13 / September / 2013, 15:50:59 »
Hi.

It'll be really cool if any of the devs would include new submenu in a new release - maybe called Transcend WiFi  :) - with two entries named 1 & 2 or On & Off that each would simply write an empty file (named correspondingly) at a predefined location (maybe in a directory called trans_wifi)

[!Transcend_WiFi >]
[1] writes the empty file 1 in directory trans_wifi on the CF card
[2] writes the empty file 2 in directory trans_wifi on the CF card

Of course the more the better.

That would allow me to try certain things with the wifi card (see few post above in this thread)

I'll write a corresponding feature request too.

Thanks in advance for considering to do or even doing it.

Regards

Sounds relatively easy to be done... though i do not have the camera with me at the moment.... I can do this when I find some time ...

Just to coordinate with Edu...
Edu, do you think this should come with our firmware or it should be in separate testing version ?
My vote goes for main firmware.
 
// AF

Re: Eos 400d ( Rebel XTI )
« Reply #1796 on: 13 / September / 2013, 17:59:56 »
Hi! I am really busy lately, I have literally one year of photographs pending to edit. But this is way too interesting to let it pass; I'll try to find the time to do it.

*

Offline 0xAF

  • ***
  • 220
    • 0xAF
Re: Eos 400d ( Rebel XTI )
« Reply #1797 on: 14 / September / 2013, 05:17:32 »
Hi! I am really busy lately, I have literally one year of photographs pending to edit. But this is way too interesting to let it pass; I'll try to find the time to do it.
Don't worry I can do it too. Just wanted to coordinate with you.
My only problem is that the camera is not with me. I gave it to my sister for a trip.

@Knatterman, I would need you to test what I do. We can collaborate on Jabber/GMail if you have one.
Drop me a PM if you're interested.
// AF

Re: Transcend WiFi SD access
« Reply #1798 on: 25 / September / 2013, 12:52:36 »

The cool thing is if you can create files via 400plus (e.g. just an empty file in any subdirectory) you could have a simple bash script watching for the existence of this file and execute another script (e.g. for transferring your pictures to a NAS, etc.) 

There's an issue to overcome there...

What you've effectively got, is an SD card that's connected to two computer systems at the same time - using a file system that doesn't have any support for such a configuration.

So if you create a file using 400plus, you can't necessarily see it from the Transcend CPU (because the FAT info is stale). Even if you overwrite an existing file with new data, you may or may not be able to see that data from the 'other side'; it depends on where precisely it got written on the card.

Maybe there's a mechanism in Linux to force the OS's view of the file system to be refreshed? ... the only thing I could think of, was to umount /dev/mmcblk0p1 and then re-mount it (on /mnt/sd). Unfortunately, every time I try it, the IP connection drops. Sometimes the link comes back up, without having to power-cycle, but I've not seen the mount command work yet (it gives "Invalid argument").

I bought my Transcend card to use with a Photo Frame, rather than the camera. When the 'card' boots, a script renames all the image directories, so that it doesn't always play the photos in the same order (a feature the Photo frame doesn't have as standard). Of course, this script was also running when I inserted the SD card into my PC to copy on new JPEGS - the result was instant corruption, due to the aforementioned stale FAT info. I ended up having to check for the presence of a 'flag file' on the card, in the Linux bash script.

As an aside, this card doesn't work in my Photo Frame's SD slot - but it does work in the USB slot, using the supplied SD card reader. Possibly the fact that it draws 150~250mA is the reason?

« Last Edit: 25 / September / 2013, 12:54:08 by PhilHornby »

Re: Transcend WiFi SD access
« Reply #1799 on: 26 / September / 2013, 06:46:11 »

The cool thing is if you can create files via 400plus (e.g. just an empty file in any subdirectory) you could have a simple bash script watching for the existence of this file and execute another script (e.g. for transferring your pictures to a NAS, etc.) 

There's an issue to overcome there...

What you've effectively got, is an SD card that's connected to two computer systems at the same time - using a file system that doesn't have any support for such a configuration.

So if you create a file using 400plus, you can't necessarily see it from the Transcend CPU (because the FAT info is stale). Even if you overwrite an existing file with new data, you may or may not be able to see that data from the 'other side'; it depends on where precisely it got written on the card.

Maybe there's a mechanism in Linux to force the OS's view of the file system to be refreshed? ... the only thing I could think of, was to umount /dev/mmcblk0p1 and then re-mount it (on /mnt/sd). Unfortunately, every time I try it, the IP connection drops. Sometimes the link comes back up, without having to power-cycle, but I've not seen the mount command work yet (it gives "Invalid argument").

I bought my Transcend card to use with a Photo Frame, rather than the camera. When the 'card' boots, a script renames all the image directories, so that it doesn't always play the photos in the same order (a feature the Photo frame doesn't have as standard). Of course, this script was also running when I inserted the SD card into my PC to copy on new JPEGS - the result was instant corruption, due to the aforementioned stale FAT info. I ended up having to check for the presence of a 'flag file' on the card, in the Linux bash script.

As an aside, this card doesn't work in my Photo Frame's SD slot - but it does work in the USB slot, using the supplied SD card reader. Possibly the fact that it draws 150~250mA is the reason?

I do not own one of those cards, but here are some of my "armchair ideas":

* Create a large file previously and fill it with random data, then use that file to communicate both processes: as far as I know, FAT does not move files around, even if the contents are changed (unless you change the length of the file, obviously), and no corruption should be expected using this method.

* If I recall correctly, the underlying format of a FAT filesystem is quite simple; once you have a file allocated, you could try to find it in the device, and access its content directly from "the Linux part" using read/write calls to the device. From "the camera part", I have no idea how to do low-level operations, however.

 

Related Topics


SimplePortal © 2008-2014, SimplePortal