Pi Zero Digital Frame Kiosk Uses OTG Right

USB On-The-Go (OTG) is one of the fun aspects of the USB standard. There are feelings about the other aspects, but that one is alright. Regardless, [Francesco] realized one day that the £3 digital picture frames he purchased at a charity sale really didn’t care if the files on the thumb drive mysteriously changed all the time. It would just keep pulling and displaying the latest file at a blistering 0.2 frames per second. That’s right, the concept [Francesco] went after is to show changing data, even animations, with an update of one frame every five seconds!

raspberry-pi-zero-otg-picture-frame-weatherHis initial tests showed good for the concept — the Pi can easily emulate a mass storage device, feeding in data whenever the picture frame looks for it. In addition to the Pi Zero board he added an Ethernet shield, a voltage regulator, a camera, and even some infrared LEDS. We suppose there are dreams for the future.

He has been developing scripts for this rig by logging in through a VNC. A cron job runs his scripts at regular intervals, grabbing useful data and making it available as an image. For example, one script opens up the weather in Epiphany (a web browser), takes a screenshot, and saves that screenshot to the mass storage being emulated using USB OTG. The digital picture frame blissfully updates, unaware of its strange appendages. Now the real limiting factor is how much you can accomplish with your mad Bash skills.

14 thoughts on “Pi Zero Digital Frame Kiosk Uses OTG Right

  1. This would be a good technique to turn old car stereos with USB mp3 capabilities into more generic digital sound systems
    if they could seamlessly play sound from one generated mp3 to another.

    1. I heard BT audio receivers which emulates USB MSD are exist.

      I read a review about one of it. Reviewer says it emulates USB MSD with long(almost infinite compared to usual car riding time) MP3 file in it. I think it matches what you think.

  2. The linked article explains that this didnt work.
    Updating the images corrupted the filesystem and the USB was dismounted after the slideshow would end.

    So it’s not the happy ending as the editorial suggests because it didn’t work fully.

      1. Potentially yes. But the device is still coming to the end of slideshow and dismounting it. That need tackling. Toggle the USB lines with some GPIO’s? (dismount at the zero end possible but is the virtual mass storage device sending out voltage signals that cannot be software controlled)

        I wanted to do this once upon a time with some non-network media players but the networked ones cost have comes down so much and well, hey, raspberry Pi zero media player…

    1. There are 2 linked articles, first he tried changing the images while his virtual filesystem was still mounted, failure. His photo frame had auto play feature so he had PI dismount itself update photos and remount problem solved.

  3. You could do it w/o a file system. Just read a graphic from a pre-determined LBA number.

    However as Daniel points out, this has nothing to do with OTG. This is device mode USB all the time. OTG is the ability to switch between host and device based on immediate use case. eg. a picture frame that would act as a mass storage device when plugged into a PC like this project and b) would also allow a USB mass storage stick to be plugged into it for reading a play-list of files.

  4. On my Deltaprintr 3D printer, I use a Toshiba FlashAir SD card that connects via WiFi. It has been great.
    I wonder if that would be a way to go instead of USB? The PiZero could serve files to the FlashAir via a WiFi dongle then it allows the picture frame to be placed in good display location and the PiZero elsewhere.
    Here is the Deltaprintr forum link…
    http://forums.deltaprintr.com/index.php?threads/spiral-printing.471/page-2#post-5459

Leave a Reply to Daniel Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.