- Open Access
- Total Downloads : 8
- Authors : Vinay Vaishnav, Amit Tiwari, Musharraf Shaikh, S.Raghuvenkatesh, Ashwini Jayawant
- Paper ID : IJERTCONV2IS04052
- Volume & Issue : ICONET – 2014 (Volume 2 – Issue 04)
- Published (First Online): 30-07-2018
- ISSN (Online) : 2278-0181
- Publisher Name : IJERT
- License: This work is licensed under a Creative Commons Attribution 4.0 International License
Raspberry Pi : The Master Key
Raspberry Pi : The Master Key
Vinay Vaishnav1, Amit Tiwari2, Musharraf Shaikp, S.Raghuvenkatesh4,Prof. Ashwini Jayawant5
Department of Electronics & Telecommunication, KCCEMSR, Thane, India
1jiggy1106@ gmail.com, 2tamit484@ gmail.com,3memush007in@ gmail .com,4raghu.15angels@ gmail.com,
Abstract The Raspberry Pi developed in this paper is providing a unique idea of making wireless internet radio alongwith interfacing electronic device like stepper motor to it
.The Raspberry Pi is said the master key because it uses a simple and portable hardware which can perform all computer operations and simultaneously interface electronic devices.
KeywordsInternet radio, Master key, stepper motor.
The Raspberry Pi is a credit-card-sized single-board computer developed in the UK by the Raspberry Pi Foundation with the intention of promoting the teaching of basic computer science in schools and colleges. Its tempting to think of the Raspberry Pi as a microcontroller development board like Arduino, or as a laptop replacement. In fact it is more like the exposed innards of a mobile device, with lots of maker-friendly headers for the various ports and functions. Our project is a flexible low-cost computer. It provides an ideal environment for experimenting with programming and electronics. The computer has a credit-card sized footprint and consumes at most a few watts of power.
The Raspberry Pi is a computer that plugs into TV and a keyboard. Its a capable little PC which can be used for many of the things that your desktop PC does, like spreadsheets, word-processing and games. It also plays high-definition video. A Raspberry -Pi leads, a power supply or SD cards that are not included but can be purchased later. One can buy preloaded SD cards too. The Raspberry Pi measures 85.60mm x 53.98mm x 17mm, with a little overlap for the SD card and connectors which project over the edges. It weighs around 45g. Overall real world performance is something like a 300MHz Pentium 2. Raspberry-Pi cannot boot without an SD card.
There are a number of operating systems running, ported or in the process of being ported to Raspberry-Pi. Like, AROS, Android 4.0,Arch Linux ARM, Debian Squeeze, Firefox OS etc.The Raspberry Pi uses Linux kernel-based operating systems. Raspbian, a Debian-based free operating system optimized for the Raspberry Pi hardware, is the current recommended system.
This project describes how to create an Internet Radio using the Raspberry PI educational computer. It contains
instructions for building the radio using either the HDD44780 LCD directly wired to the
Raspberry PI GPIO pins or using an Adafruit RGB-backlit LCD plate for Raspberry PI.
The features of the radio are:
Raspberry PI running standard Music Player Daemon (MPD)
Three different LCDs supported
2 x 16 character LCD with HD44780 controller
4 x 20 character LCD with HD44780 controller
Adafruit LCD plate with 5 push buttons (I2C interface)
Clock display or IP address display (for web interface)
Five push button operation (Menu, Volume Up, Down, Channel Up, Down)
Artist and track scrolling search function
Plays music from a USB stick or from a Network drive (NAS)
Menu option to display a single RSS news feed
Web interface using snoopy and others
Plays Radio streams or MP3 and WMA tracks
Controlled by an Object Orientated Python application
Support for European character sets (Limited by LCD capabilities)
Fig.1 System block diagram used in our design
The principle hardware required to build the radio consists of the following components:
A Raspberry PI computer
An HD44780 LCD display or an Adafruit RGB-backlit LCD plate for the Raspberry PI
LCD and switches interface board
The Raspberry Pi is a credit-card-sized single-board computer developed in the United Kingdom by the Raspberry Pi Foundation with the intention of promoting the teaching of basic computer science in schools.
Fig.2 Raspberry Pi hardware
Fig.3 Raspberry Pi Model-B
The Raspberry Pi board contains a processor and graphics chip, program memory (RAM) and various interfaces and connectors for external devices. Some of these devices are essential, others are optional. RPi operates in the same way as a standard PC, requiring a keyboard for commandentry, a display unit and a power supply. It also requires mass- storage, but a hard disk drive of the type found in a typical PC is not really in keeping with the miniature size of RPi. Instead we will use an SD Flash memory card normally used in digital cameras, configured in such a way to look like a hard drive to RPis processor. RPi will boot (load the Operating System into RAM) from this card in the same way as a PC boots up into Windows from its hard disk.
The following are essential to get started:
SD card containing Linux Operating system
TV or monitor (with HDMI, DVI, Composite or SCART input)
Video cable to suit the TV or monitor used
THE HD44780 LCD DISPLAY
The HDD44780 LCD interface is an industry standard interface for a variety of LCD displays.These can come in various sizes but the two lines by 16 character display is the most popular.
Fig.4 The HD44780 LCD display used as indicator/monitor
As the RPi has no internal mass storage or built-in operating system it requires an SD cardpreloaded with a version of the Linux Operating System.
Fig.5 SD card used for raspberry pi
SD card setup Steps:
Formatting the SD card via the mkcard.txt script
Formatting the SD card via fdisk "Expert mode"
Setting up the boot partition
Writing the image to the SD card and booting GNU/Linux
SD Card Cloning/Backup
Reading an image from the SD Card
Copying an image to the SD Card
The unit is powered via the micro USB connector (only the power pins are connected, so it will not transfer data over this connection).
Fig.6 Stepper motor used for interfacing
The motor connects to the controller board with a pre-supplied connector.The controller board has 4+2 pins that need to be connected to the Pi header (P1).
KEYBOARD AND MOUSE
Most standard USB keyboards and mice will work with the RPi. Wireless keyboard/mice should also function.
You will need one or more cables to connect up your RPi system.
Video cable alternatives:
HDMI-A cable + DVI adapter
Composite video cable
Composite video cable + SCART adaptor
Audio cable (not needed if you use the HDMI video connection to a TV)
You my decide you want to use various other devices with your RPi, such as Flash Drives/Portable Hard Drives, Speakers etc.
This may be via an Ethernet/LAN cable (standard RJ45 connector) or a USB WiFi adaptor. The RPi Model B Ethernet port is auto-sensing which means that it may be connected to a router or directly to another computer (without the need for a crossover cable).
In order to connect additional devices to the RPi, you may want to obtain a USB hub, which will allow multiple devices
to be used. It is recommended that a powered hub is used – this will provide any additional power to the devices without affecting the RPi itself.
Since the RPi is supplied without a case, it will be important to ensure that you do not use it in places where it will come into contact with conductive metal or liquids, unless suitably protected.
EXPANSION AND LOW-LEVEL PERIPHERALS
If you plan on making use of the low-level interfaces available on the RPi, then ensure you have a suitable plug for the GPIO header pins. Also if you have a particular low-level project in mind, then ensure you design-in suitable protection circuits to keep your RPi safe.
GENERAL PURPOSE INPUT OUTPUT PINS (GPIO)
The figure shows the available pins for external access to the Raspberry Pi. Grayed out pins N/C are not for external connections and are used internally. GPIO pins 17, 18, 21, 22, 23, 24, 25 are available for external I/O connections. The pins are numbered from 1 to 26, left to right and top to bottom. The 5V pin is marked in red as a caution since the Raspberry Pi operates at the 3.3V level only. Incoming 5V signals must be voltage divided to yield only up to 3.3V before entering the Raspberry Pi. The unit is powered via the micro USB connector (only the power pins are connected, so it will not transfer data over this connection). A standard modern phone charger
Fig.7 GPIO pins (arrowed) used in our design
Fig.8 Special function pins
LEFT COLUMN OF PINS:
SDA Serial Data Line 0
SCL Serial Clock Line 1
4 General Purpose Clock
10 MOSI Master Output Slave Input
9 MISO Master Input Slave Output
11 SCKL Serial Clock
RIGHT COLUMN OF PINS:
TXD UART Transmit (TXD)
RXD UART Receive (RXD)
8 Chip Select 0 (1st Slave)
7 Chip Select 1 (2nd Slave)
We choose Linux and not windows or other operating system because its open source and we have its special version dedicated for Raspberry Pi called as Debian PI.Linux understanding is very important as entire configuration of Raspberry Pi will be done on Linux console (command prompt).
Python is high level programming (Scripting) language specially designed for Linux platform. Its needed for developing any kind of applications on raspberry pi.
MUSIC PLAYER DAEMON
Fig.9 Music player daemon design
Music Player Daemon (MPD) is a free and open source music player server. It plays audio files, organizes playlists and maintains a music database.In order to interact with it, a separate client is needed.
MPD simply runs in the background playing music from its playlist. Client programs communicate with MPD to manipulate playback, the playlist, and the database. It is not a full-featured music player program such as Amarok, but its clients can serve such role. MPD uses a flat file database to maintain the basic music file information when it is not running. Once the daemon is started, the database is kept completely in-memory and no hard disk access is necessary to look up or search for local audio files.Usually, music files must be below the music root directory and are only added to the database when the update command is
sent to the server. Playback of arbitrary files is only allowed for local clients which are connected to the server via Unix Domain Sockets. MPD does not provide a built-in tag editor; this functionality is handled by clients or external programs, though 3rd party patches do exist to add this functionality to the server. The clientserver model provides several advantages over all-inclusive music players. Clients may communicate with the server remotely over an intranet or over the Internet. The server can be aheadless computer located anywhere on the network. Music playback can continue seamlessly when not using X or restarting X. Different clients can be used for different purposes a lightweight client left open all the time for controlling playback with a more fully featured client used for intensive database searches. Several clients can use the same database, even running simultaneously side-by-side, remotely or under different user accounts.
Plays Ogg Vorbis, FLAC, WavPack, MP2, MP3, MP4/AAC, MOD, Musepack, wave files and any other files supported by FFmpeg.
Remotely control MPD over a network (IPv4 and IPv6 supported).
Play FLAC, OggFLAC, MP3 and Ogg Vorbis HTTP streams.
Reads and caches metadata information (ID3: ID3v1 and ID3v2), Vorbis Comments, and MP4 Metadata.
Metadata information can be searched.
Buffer support for playback (prevents skipping due to high load or network latency).
Gapless playback. 7.Crossfading support. 8.Seeking support.
9.Save, load, and manage playlists (in M3U format). 10.Native Zeroconf support.
libsamplerate and native sample rate conversion
Support for ALSA, PulseAudio, OSS, MVP, JACK, Windows, and Mac OS X.
Can be used as a source for an Icecast stream, in Ogg Vorbis and MP3. Other formats can be converted to Ogg/MP3 on the fly before output to the stream server.
Built-in HTTP streaming server, capable of producing Ogg Vorbis and MP3 streams of a chosen quality on-the-fly.
Independent of a GUI. Music will continue playing whether a front-end is open or not,and will continue playing even if the X server is killed.
MPD has a variety of front-ends which communicate with the server using a custom protocol over a TCP connection. Clients usually implement different types of interfaces.
mpc (part of the MPD project) is a simple command line interface to most of the server's functions
ncmpc is a more fully featured ncurses client similar in concept to MOC
ncmpcpp is another ncurses client that clones ncmpc's functionality, but includes new features, such as a tag editor.
Sonata uses GTK+ to provide a GUI for playing files and managing playlists.
Intelligent Music Player Client (IMPC) uses GTK+ 3.0 and supports loading related information (articles, covers, images) with actually playing song and it learns to classify related content.
Cantata uses Qt to manage the library or playlists, with extras like tags editor, lyrics, cover fetching and support for mass storage devices.
Qmobilempd provides a Qt4 client especially for mobile devices like Symbian.
Qmpdplasmoid provides a client directly embedded into the KDE desktop.
Ario uses tabs in its interface.
Gimmix provides a simple interface with a very small memory footprint.
mpdlirc interfaces MPD via an infrared remote control For a more complete list, see the Clients MPD Wiki.
Simple clients can script the mpc program to issue commands to the server. Some clients run within a web browser and can
be located on the same computer as the server, requiring only a browser be installed on the client machine.There is a client implemented as a Firefox add-on, one as a Xfce panel plugin and one as a Wii aplication. and one as a Windows Store application for Windows 8/Windows RT.
Libraries exist to interface with MPD from many programming languages, including C, Python, Ruby, Perl and Lua.
In this paper, a novel method of wireless internet radio and simultaneously using a stepper motor for any applications, using a portable mini computer system known as raspberry pi will be desingned and linux operating system is used and python programming language is used. This paper mainly describes the design and simulation of Internet Radio alongwith Stepper Motor which is based on Raspberry Pi, Linux OS, Python Programming and GPIO pins.
1] Official site: www.raspberrypi.org
2] FAQs. Raspberry Pi. Retrieved 3 November 2011.
3] "BCM2835 Media Processor; Broadcom". Broadcom.com. 1 September 2011. Retrieved 6
4] Introducing turbo mode: upto 50% more performance for free. Raspberrypi.org. Retrieved 20 September 2012.
5] At first, for a short time, revision 2 boards were made that had 256 MB of RAM
6] Raspberry Pi: Cheat Sheet. Silicon.com. Retrieved 6 May 2012.
7] Price, Peter (3 June 2011). Can a Â£15 computer solve the programming gap? BBC Click. Retrieved 2 July 2011.
8] Bush, Steve (25 May 2011). Dongle computer lets kids discover programming on a TV". Electronics Weekly. Retrieved 11 July 2011