element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Members
    Members
    • Benefits of Membership
    • Achievement Levels
    • Members Area
    • Personal Blogs
    • Feedback and Support
    • What's New on element14
  • Learn
    Learn
    • Learning Center
    • eBooks
    • STEM Academy
    • Webinars, Training and Events
    • More
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • More
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • More
  • Products
    Products
    • Arduino
    • Dev Tools
    • Manufacturers
    • Raspberry Pi
    • RoadTests & Reviews
    • Avnet Boards Community
    • More
  • Store
    Store
    • Visit Your Store
    • Choose Another Store
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
Raspberry Pi Projects
  • Products
  • Raspberry Pi
  • Raspberry Pi Projects
  • More
  • Cancel
Raspberry Pi Projects
Blog Pi Ball – A Spherical and Interactive Raspberry Pi 2 Case
  • Blog
  • Documents
  • Events
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Raspberry Pi Projects requires membership for participation - click to join
Blog Post Actions
  • Subscribe by email
  • More
  • Cancel
  • Share
  • Subscribe by email
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: Catwell
  • Date Created: 25 Mar 2015 11:26 PM Date Created
  • Views 786 views
  • Likes 5 likes
  • Comments 9 comments
  • tutorial
  • project
  • build
  • rpi2
  • Design
  • cabeatwell
  • raspberry_pi_2
  • rpiexpert
  • steps
  • raspberry_pi_projects
  • pi_ball
  • innovation
Related
Recommended

Pi Ball – A Spherical and Interactive Raspberry Pi 2 Case

Catwell
Catwell
25 Mar 2015

Disclaimer: I’m an engineer, not a pro film maker. Be advised.

You don't have permission to edit metadata of this video.
Edit media
x
Upload Preview

Disclaimer: I’m an engineer, not a pro film maker. Be advised.

 

Raspberry Pi cases are all the rage. Everyone makes blocky cases, wood cases, cases shaped like computers or arcade cabinets. I wanted a case that could interact with the physical space around it-- why not put a Raspberry Pi 2 in a ball?

 

Here are just a few things I can do now--

 

  • bowl with it
  • wirelessly connect to the Internet
  • draw in 3D space with motion tracing
  • automated bounce counting

 

Meet the Pi Ball!

 

Here were my requirements

- Use a Pi (Raspberry Pi 2 in the case)

- Spherical case, that can be bounced, kicked, thrown

- Accelerometer onboard to monitor the motion of the ball

- Wireless everything! Wireless keyboard/mouse, networking, sound and video

 

  

   (Pi Ball in on! LEDs on! Wirelessly connected to the screen in the background - running the accelerometer tracking program.)

 

Project by sections

 

The Pi Ball enclosure:

 

The Pi Ball spherical enclosure consists of three pieces. Two hemisphere and the mounting plate attached in the middle.

  

   (The 3D model of my concept. I used Solidworks 2013.)

 

I wanted a smooth external appearance. No screws/bolts holding it together.

 

  

   (Here is the freshly printed enclosure components. A Pi 2 place on the mount plate for scale.)

 

  

   (Pi Ball parts layout. Had to stuff all that inside the enclosure!)

 

When the hemisphere lock together, they wedge the mounting plate in the middle. The hemispheres are made of “elasto-plastic” from Shapeways, and the mount plate is regular ridged ABS. The Elasto-plastic shells were quite bouncy – when empty. However, with all the components inside, the high bounce was gone.

 

  

   (The mount plate, Pi 2 attached using four M2.5 cap head bolts)

 

The middle mount plate has slots for passing wires and such, and the Pi is attached to the plate via standoffs printed on the surface. Those standoffs were tapped for M2.5 bolts.

 

  

   (Pi Ball, early Raspberry Pi 2 mount and wire routing.)

 

 

 

Wireless devices:

 

Making everything wireless turned out to be very easy with today’s tech. Wireless keyboard and mouse adapter was a single low profile USB transceiver. The WIFI adapter was exactly the same. The wireless HDMI comes via a Nyrius AERIES 1080p transmitter. (The HDMI receiver is attached to the screen. The one I used had a 165 foot line-of-sight range. But, I found that I could get about 90-100 feet without issue.)

 

  

 

To stay wireless, the devices need power. I used two onboard battery packs – for two different, but critical reasons.

 

ONE – The HDMI adapter needed 5V@ 1.5A, so to take the strain off the main battery I found a small 2200mAh external battery. Tool the enclosure off of it, and placed it on top. The Pi and the LEDs shared a 8400mAh external battery supplying 5V@ 2A.

 

TWO – The two separate batteries created a better balance inside the sphere. So, it rolled more like a ball than an egg.

 

  

   (Almost everything attached to the mount plate. Pi2 on top with the HDMI transmitter and 2200mAh battery (not shown). Bottom has the 8400mAh battery, USB hub, and accelerometer (not shown) )

 

  

   (NeoPixels on, via their own power source.)

 

The Adafruit NeoPixel LED strip needed to source more power than the Pi 2 could supply. So, I connected them to their own USB cable connected to the 8400mAh battery directly. Only the signal life from the NeoPixels connected to the Pi 2 (pin 12 to be exact)

 

  

   (About to close up the Pi Ball...)

 

  

   (Pi Ball is on... running the accelerometer sensor program - wirelessly connected to that LG TV.)

 

 

Battery life:

 

   

   (The 2200mAh battery removed from its red case. This way it was much smaller to put on top of the HDMI adapter.)

 

The HDMI adapter on the 2200mAh battery was what gave out first. It lasted 3 hours of constant streaming. I could have easily doubled that with another 2200mAh battery, there was room.


  
   (Anker 8400mAh battery strapped to the back on the mount plate. An early step in the build.)

 

For the Pi 2 itself. the 8400mAh battery lasted about 12 hours of intermittent use. But, after 3 hours I did not have video output. That may have extended the life.

 

 

Software (all in Python):

Aside from running the full OS, where one could do regular computer work, tinkering, etc.. I had two specific Pi Ball applications.

 

- An on screen representation of the Pi Ball’s location and movement in an isometric representation on 3D space. It looks like a fading comet trail. I also put in a mode to trace the movement. My idea was for someone to hold the ball and draw in 3D. However, it only partially worked. I need to change it to take more samples.

 

- I also had a mode to count the # of impacts detected, like bouncing.

 

- The second feature was turning on LEDs inside the ball. The main feature was to react to the accelerometer data, and turn on, flash or chaser effects on one of those Adafruit Neopixel LED strips. This worked spotty at best. But, when it worked, it did what I wanted.

(I have an always on, always off, a constantly flashing/chasing, and accelerometer effected modes.)

 

 

The difficulties

 

- All the USB cables used inside the Pi Ball had copious amounts of rubber/plastic on the connector ends. I used a knife and shaved off the excess to make them more flexible and smaller.

 

  

    (Here is an example of cutting off wire thickness. This is the shaved HDMI cable. I also took some of the rubber shielding on the length to make it more flexible.)

 

- Fitting everything into the Spherical case. Perhaps if I make a version 2, I will up the size from 6” diameter to something like 8 or 10”. That way I could pack in more sensors and effects.

 

- Getting the Neopixels to work. Sometimes they would flash random colors or effects. They are  dependent on the frequency output of the Pi. I stuck with a white only color to just get it to work.

 

 

Schematic and Design

The only true schematic, is the accelerometer connection. See below:

 

 

Everything else is just standards. IE, plug in mouse/keyboard to the USB port, etc

 

 

Code

(See attached to the post)

 

 

BOM

 

  

QuantityPriceVendorPart #Description
1$35$35element1468X0156Raspberry Pi 2
1$37.00$37.00element1445P6651ADXL335 accelerometer and parts kits
1$2.19$2.19element1419C7200ANALOG TO DIGITAL CONVERTER ADC
1$0.12$0.12element1498K49951N4001 diode
1$220.00$220.00ShapewaysNA3D printed components
1$48.00$48.00AmazonNALogitech wireless keyboard and mouse
1$8.00$8.00AmazonNAWiFi adapter (generic)
1$200-400(new)$200.00AmazonNANyrius wireless HDMI adapter (Pro model)
1$25.00$25.00Adafruit1461NeoPixel 60 LED strip
1$4.49$4.49AmazonNAJgmax 2200mAh external battery
1$19.00$19.00AmazonNAAnker 8400mAh external battery
TOTAL$598.80

 

Other uses of the system

 

Aside from having a completly wireless Raspberry Pi 2 system, the Pi Ball could be used for any number of applications - Imagination is the limit.

 

- In its current form, it can be used for motion tracking.

- I have a mode that lets the user draw in 3D space, tracing the motion.

- Count the number of bounces.

- Any number of light based effects.

- Roll it in, let the fun begin! Use your imagination...

 

When I have more time, money, or people really like the Pi Ball

- Source cheaper components. For instance, the accelerometer. The Wireless HDMI adapter could be bought elsewhere. The 3D printing could happen in house.

- Make a new version with more internal hooks. I designed in only 4 attachment points between the two hemispheres. I would want to increase that to at least 6.

- Better battery design and mounting.

- Bouncier all around. I want to bounce it like a basketball, personally.

- More software and code to use the ball to the utmost.

Attachments:
Pi Ball 2D only.py.zip
Pi Ball 2D with LEDs.py.zip
Anonymous

Top Comments

  • Catwell
    Catwell over 7 years ago in reply to Former Member +1

    Alex,

     

    Yes, I suppose you can. I found that I could get about 30 feet away before the wireless keyboard and mouse stopped reporting.

     

    C    

Parents
  • Former Member
    Former Member over 7 years ago

    So could you hook it up to a portable hdmi tv,put the pi in a bag and use itlika a normal laptop? 

    • Cancel
    • Up 0 Down
    • Reply
    • More
    • Cancel
Comment
  • Former Member
    Former Member over 7 years ago

    So could you hook it up to a portable hdmi tv,put the pi in a bag and use itlika a normal laptop? 

    • Cancel
    • Up 0 Down
    • Reply
    • More
    • Cancel
Children
  • Catwell
    Catwell over 7 years ago in reply to Former Member

    Alex,

     

    Yes, I suppose you can. I found that I could get about 30 feet away before the wireless keyboard and mouse stopped reporting.

     

    C    

    • Cancel
    • Up +1 Down
    • Reply
    • More
    • Cancel
Element14

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2022 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • Facebook
  • Twitter
  • linkedin
  • YouTube