Showing posts with label Beagleboard. Show all posts
Showing posts with label Beagleboard. Show all posts

Monday, March 9, 2009

Touchbook - Netbook based on ARM

Came across this 'Touchbook' - a netbook based on ARM platform - recently.

So what, you might ask? Well, one - its OpenSource - based on OpenHardware and ofcourse, Opensource software. Hardware - specifically, the Beagleboard and software - Angstrom distro. More on this here.

The Touchbook has a plethora of features:

Dimensions: 9.4" X 7" X 1.4"
Weight: 2 lbs with keyboard
Storage: 8GB micro SD Card
Display: 1024 X 600; 8.9" Touchscreen
3D Accelerometer
Wifi 802.11 b/g/n
10 to 15 hrs of battery life
speakers, microphone and headphone slots
6 USB slots
Formfactor capable of using the device in multiple ways: as a laptop, handheld gaming device, video player etc.
Two modes of operation - one that uses keyboard and the other that uses the touchscreen.

More about the features - here.

In Me's opinion - this is one helluva device. Needless to say, one that Me'll target to buy in the recent future.

--
Me.

Sunday, January 18, 2009

OMAP - in brief

OMAP and DaVinci Software For Dummies - THE book for beginners:

omap_dummies_cover

Since a couple of weeks (or probably more), www.beagleboard.org has had a mention about a book called "OMAP and DaVinci Software For  Dummies". The companion website was pretty impressive too. Especially since Me was an absolute novice when it came to OMAP or any of TI's products, excepting the recent experiences with Beagle. Proceeded to order it thru myTI, expecting that it might cost me, that too in dollars. Was pleasantly surprised to see that the order went through without a mention of any charge at all.

A couple of weeks later, this nice little book dropped into my mail box. About 106 pages in all, it was written for absolute novices - who knew nothing about OMAP or DaVinci. And that, precisely, is what Me needed at this juncture.

The reading experience was a cruise. Took about a couple of hours of my train journey from Bangalore to Hyderabad. Apart from covering all major aspects of OMAP and DaVinci, this book also featured a good set of cartoons at few places - my fav one being "The 5th Wave" by Rich Tennant - "Oh come on... how fatal can it be?". Here's a copy of the cartoon - all credits to Rich Tennant. The authors - Steve Blonstein and Alan Campbell - did a pretty good job at striking a right balance between keeping the language simple and yet driving home the point about how sophisticated this stuff is. Worthy of mention are the icons that draw the attention of reader to some specific tit bits of information. There are a lot of TLA's dispersed around in the book - but are just right in volume - atleast Me didn't get driven away mad. ;-)

The book has three parts:

The first part starts with a good discussion about how multi-core architectures have come to be of such prominence in today's world, introduces the OMAP and DaVinci platforms, discusses the operating systems and kernels available, the various standards that TI had come up with to make the lives of developers easy and the software frameworks in place for these platforms.

The second part walks the reader through a hands-on. If followed through, the reader can end up with software that utilizes the video and audio parts of OMAP processor.

The last part - gather that this is a standard feature of all For Dummies books - gives very useful information - TI's recommendations for Codecs and pointers to resources that will help developers.

OMAP and DaVinci Platforms:

OMAP and DaVinci SOCs are hybrid in nature - they typically contain a GPP (General Purpose Processor) and a DSP (Digital Signal Processor). The task scheduler for the DSP is a lightweight scheduler called DSP/ BIOS. The For the GPP the SOC leverages the wonderful world of Linux (other operating systems can also be ported though.)

DSP/BIOS - there is apparently a perennial discussion about if this is actually an operating system or if it is a scheduling kernel - is ideal for the real time DSP task scheduling due to its key attributes - high scalability, high speed and low latency. The book prescribes Linux - community based or the commercial ones - as the right platform that can leverage the GPP in these SOCs to the best possible extent.

TI seems to have done tremendous work in the world of Codecs and addressed a lot of problems related to inter-operability, packaging and deploying quite efficiently. XDAIS, XDM, RTSC etc., seem to give a system integrator the freedom to try various Codecs and the scalability to switch between platforms easily.

TI apparently also has a whole lot of supporting software for these platforms - various VISA codecs, DVSDKs, Code Composer Studio, QualiTI, packaging tools - that make the lives of a system integrator far easier that what it was before. The best part, most of these software are available free for the community. The platform specific packages, Me gathers, leverage the potential of open source communities to a good extent.

All in all, a wonderful book for beginners. A perfect ten on ten for the way the material is presented - simple and interesting. Gave me a good list of things to try on Beagle. A must for everyone starting off on OMAP or DaVinci platforms.

Me's never bothered to check, so far, what TI has been upto with its products, in detail. The more Me learns about their products and their passion towards keeping things open - Me's becoming quite a fan of TI.

Me.

Further reading:

Dummies Book online: www.ti.com/dummiesbook

Thursday, January 15, 2009

Synergy works!

Me had worked around the problems Me was facing with getting the keyboard to work.

  • Me could log into angstrom from the serial connection. Realized that this would be just another login session as far as Angstrom was concerned.
  • Ethernet was working without any problem, so could run opkg install commands.
  • Installed Synergy and started it as a client.
  • Configured Synergy on my PC as a server.

 

Voila! Now, Me can use my keyboard and mouse connected to my PC to work with beagle!

The first thing Me did was to enable autologin in Angstrom, and add the synergy client to startup.

Alleviates some pain till Me gets a USB keyboard to check with the USB hub and beagle.

-Me.

Keyboard problems!

Once Me got my USB A to Mini-AB cable done, my next task was to get a minimal set of peripherals working with the Angstrom demo distribution.

So, this is what my setup looked like.

USB-A to mini-AB connected to a female-USB to female-USB adapter, which was connected to a self powered USB 2.0 hub. Connected to the hub were a USB to ethernet adapter and a USB to PS2 adapter, to which a PS2 keyboard and mouse were connected.

When angstrom booted in, Me couldn't log in - neither the keyboard and mouse were working. Had to go about the elimination way to figure out what was happening.

When Me had only a USB mouse connected to the hub, Angstrom booted with mouse enabled and Me could log in. Connected the USB to ethernet adapter and was glad to see the ethernet work too.

However, the moment Me connected the USB to PS2 adapter, the USB to ethernet was disabled, and neither did the mouse work. Noticed a bunch of statements on the serial port - which indicated that the corresponding USB ports were disabled.

Looks like the USB to PS2 adapter is the culprit. Can't exactly figure out what was happening, but Me thinks its drawing too much power off the hub due to which the hub was disabling the other ports. Or its probably that the hub itself was faulty. What perplexes me is that the USB to PS2 adapter to keyboard-and-mouse works fine on my Windows laptop without these problems.

Can't quite explain or pin down the problem to a particular component. However, the next immediate steps would be to:

  1. Check if a USB keyboard works fine along with the mouse and USB to Ethernet connected to the hub.
  2. If that doesn't work, then check with a different USB hub.

 

-Me.

USB-OTG - A brief

Dealing with the USB OTG on Beagle has been quite a learning experience, especially, since my knowledge of USB was very minimal. This is Me's attempt at providing a brief about USB OTG.

USB was first introduced to address desktop's connectivity with various peripherals - printer, mouse, keyboard, serial, parallel, PS2 etc. It was quite successful - so much so that almost all peripherals and devices that need PC connectivity these days use USB.

USB has further been extended to other devices, mobile phones in particular and the functionality has been extended from mere PC connectivity to include charging, transferring video etc.

The USB master/ slave architecture that USB generally used - where a host acts as a protocol master and a USB device (peripherals) act as the slave - were sufficient to address most usage scenarios. The host always initiated the configuration/ data transfer from the peripherals in these cases.

Specifically, a usage model started emerging - the one where a device needed to either act as a host or a peripheral based on the situation. A typical example would be when two mobile phones could be connected for data transfer - where one would act as a device and the other as a peripheral. The same mobile also needed to act as a peripheral when connected to a PC. A need to have one connector on the mobile for all purposes - charging, to connect audio headsets, for data transfer - also played an important role in the introduction of USB OTG during late 2005 - early 2006 timeframe. The miniature nature of these devices also resulted in mini USB connectors to suit their form factors.

USB On The Go - USB OTG in short - introduced  two new protocols: SRP - Session Request Protocol and HNP - Host Negotiation Protocol.

SRP allows both communicating devices to control when the link's power session is active. This was not available in the standard USB spec - only the host was capable of doing so. This fine control over the power consumption resulted in significant power savings in battery operated devices like cameras and mobile phones.

HNP allows the two devices to exchange their Host/Device roles, provided both are OTG dual-role devices.

USB OTG protocols cannot pass through a standard USB hub - since they are based on physical electrical signalling.

USB OTG defines two roles of devices: OTG A-device and OTG B-device. The terminology defines which side supplies power to the link, and which is initially the host.

OTG A-device is a power supplier, and an OTG B-device is a power consumer. The default link configuration is that A-device acts as a USB host and B-device is a USB device. The modes may be exchanged later by using HNP.

USB OTG standard introduces a new plug receptacle called mini-AB. It can accept either a mini-A connector or a mini-B connector. USB OTG also adds a fifth pin to the standard USB connector called the ID-pin.

The mini-A connector has the ID pin grounded (connected to GND), while the ID in the mini-B connector is floating (non-grounded).

A device that has a mini-A plugged in becomes an OTG A-device and the one that has mini-B plugged in becomes a OTG B-device. The type of the plug inserted is detected by the state of the ID pin.

Beagle Context:

Beagle has a mini-AB connector and has both modes of operation. When connected to a PC it is a peripheral and when it is connected to other devices like a USB hub, keyboard, mouse, USB Ethernet etc, it playes the role of a host. When Beagle is required to play the role of a host, the cable that is required would need to be in the OTG-A mode.

In the market, almost all USB cables with a mini-AB connector are of OTG-B configuration. Me had scourged the local markets in Bangalore and Hyderabad, and couldn't find a cable that was made in a mini-A configuration. What makes matters worse that none of these cables had any indication about whether the cable has OTG-A or OTG-B configurations. The shopkeepers would hardly understand OTG, complicating things a little further.

2009-01-10-32267

So, to get USB on my Beagle working, Me had to choose between meddling with the board and modifying a cable. For obvious reasons, Me choose to modify the cable. Lucky for me the connector opened up pretty easily. But unfortunately, unlike the other pins, the ID pin was trimmed off making it very challenging to connect it to the GND pin.

After a whole lot of struggle, ended up with a connection as shown in the picture here. Had to take a small strand from a USB cable that Me had opened up earlier, use the solder to firm it up, and then put up a struggle to connect it between the ID and GND pins, making sure that it didn't touch any of the other pins.

Me's opinion - USB standard or atleast the cable manufacturers should come up with a standard way of indicating the OTG configuration that the USB A to mini-AB cables are made of. If not anything, that'd save some time and effort for folks who scourge the markets for specific cables.

-Me.

Further reading:

USB OTG on Wikipedia: http://en.wikipedia.org/wiki/USB_On-The-Go

USB OTG on the USB.org website: http://www.usb.org/developers/onthego

Maxim's app note on USB On-The-Go Basics: http://www.maxim-ic.com/appnotes.cfm/an_pk/1822

Friday, December 26, 2008

BeagleBoard - A few observations

The best source of information about Beagle is the System Reference Manual. For the latest hardware revision available, this can be found here. This document details every aspect of the board - from the various components on the board and their features to detailed specifications and even the board verification procedures.

Here, Me's trying to summarize 'interesting' aspects of beagle, that Me has figured while reading up the System Reference Manual:
  • Beagleboard uses OMAP3530 version ES2.1. However, when you look on the beagleboard, you will not find a component called OMAP3530. This is 'cause Beagle comes in a .4mm pitch POP package. POP (Package on Package) is a technique where the memory, NAND and SDRAM, are mounted on top of the OMAP3530.
  • The Micron POP memory has 256MB of NAND memory and 128MB SDRAM @ 166MHz.
  • Apart from being a communication/ interfacing peripheral, USB OTG on the board is the primary source of power for Beagle. It derives power from the PC over a USB cable. Thus, the client port is limited to about 500mA, as dictated by the USB standard. However, it is possible to draw more power using a USB Y cable, as shown below. (Picture from the System Reference Manual)
  • The 4-pin din connector for S-Video can carry a video signal (for TV) that is different from the one on the DVI-D output. It can support both NTSC and PAL, default being NTSC.
  • Beagle has a HDMI connector to drive a DVI-D signal. This DOES NOT support HDMI interface, and has the DVI-D interface ONLY. Also, Beagle does not generate the analog component of the DVI-D signal, so connectors like HDMI to VGA or DVI-D to VGA will not work.
  • In order to boot from the MMC/ SD card, the card must be a 3V, 4 bit card. 
  • As of rev B6, the reset button on the board will not work when the Linux kernel is running. To reset the board from the kernel operation, a power cycle is required.
  • The user button provided on the board can have two uses: (a) to force a change in boot sequence (b) as an application button that can be used by software as need be.
  • If the user button is NOT pressed while the RESET button is released, the boot sequence is NAND -> USB -> UART3 -> MMC1.
  • If the user button is pressed while the RESET button is released, the boot sequence becomes USB-> UART3 -> MMC1 -> NAND.
  • One cool way to power up Beagle is to use a USB to 5.5mm barrel power adapter cable as pictured below. The self powered USB hub could power, among a variety of other peripherals, this cable as well - this could be used to power up beagle!
  • Beagle has a switch that ensures that when both USB and the power adapter are connected, the board powers up using the power adapter and not the USB. USB in this mode will function either in client/ host modes as need be.
More details will be updated as they are discovered! :-)

p.s.: The USB to 5.5mm barrel power adapter cable is available at Sparkfun. However, if someone knows how to get this cable in India, please let me know. What would be even better would be a DIY article for the same (Add to Me's homework!).

Friday, December 19, 2008

Serial Communication - a brief

Thought Me'd just scribble a few notes about serial communication - all that Me discovered after the first experiences with booting up Beagle and getting RS232/ serial communication working. 

Serial communication, in a nutshell, is a process of sending one bit at a time, sequentially, over a communication channel, usually a computer 'bus'. Historically, this mode of communication has been used for long haul communication. Offlate, serial computer buses (like USB) have become more common, 'cause of the advantages they have over another mode of communication, the parallel communication.

The most extensive usage of serial communication in history has been to network computers using modems. A serial port on the PC was designed to be connected directly to an external modem. Thus, it is termed as "Data Terminal Equipment" (DTE) and the modem is called "Data Communications Equipment" (DCE). 

RS232 is a standard developed by the Electronic Industries Association (EIA) and other interested parties, specifying the serial interface between Data Terminal Equipment (DTE) and Data Communications Equipment (DCE). The RS232 standard includes electrical signal characteristics (voltage levels), interface mechanical characteristics (connectors), functional description of interchange circuits (the function of each electrical signal), and some recipes for common kinds of terminal-to-modem connections. The most frequently encountered revision of this standard is called RS232C. Parts of this standard have been adopted (with various degrees of fidelity) for use in serial communications between computers and printers, modems, and other equipment. 

The serial ports on standard IBM-compatible personal computers follow RS232C, and are full-duplex devices, in that they can send and receive data at the same time. They are both male connectors, as given in the pictures below. These serial ports, typically, use two separate lines for transmitting and receiving data.



The pin assignments for the above connectors in both roles (as DTE and DCE) are as follows:


RS232C, however, does not define bit rate, character framing, communication protocol, character ecnoding, data compression and error detection, which must be agreed by both sending and receiving equipment for a successful transmission. These are typically manifested as settings in the software/ serial communication clients that are used by either ends.

The most commonly found and simple usage of serial communication is found in communication using Null modem cables. In this communication, the RxD of DCE is connected to TxD of DTE and vice versa, and the common grounds (G) are connected together.

Lately, serial ports are being deprecated in the latest platforms, and USB is taking its place. However, there are USB to serial adapters widely available, that make interactions with legacy systems possible. 

Beagle, exposes a RS232 port, to which an IDC10F to DB9M adapter can be connected to expose out a serial interface. The reference manual, very cleary indicates the wiring that's required on such an adapter. Me's had some trouble regarding this, as outlined in my earlier post.

More resources:


--
Me.

Saturday, December 13, 2008

Beginning Blues

So, Me got my Beagle board. I went shopping for the minimalist kit that should be good enough to boot it up. This was the apparatus with which I had started off my journey with beagle:
  1. Beagle board (ofcourse, :-p)
  2. USB A to USB mini A (OTG) cable, to power up the Beagle. 
  3. IDC10F to DB9M adapter
  4. HDMI to VGA cable.
  5. 5V DC power adapter.
  6. Null modem cable to connect the beagle to my PC.
Noticed that my power adapter has a switch to select the polarity. Had posted a query regarding to beagleboard's google group, enquiring about the polarity to be used and if the HDMI to VGA cable would work.

Gerald replied back saying all this is covered in the system reference manual - which me hadn't even gone thru till then. He also mentioned that the HDMI to VGA cable wouldn't work - since the signal that is output from the HDMI port is a DVI signal, and does not have neither the HDMI signal, nor the analog signal that would be required for the VGA cable to work.

Thus, had to go shopping again - this time for the HDMI male to DVI-D female adapter. 

The beagleboard that Me'd bought was rev B6. Downloaded the corresponding system reference manual, and noticed that it had more than enough information that anyone would require to get going with the beagle board. What interested me was the board validation procedure that apparently the manufacturing would use themselves to make sure that the boards are good. Me had decided that Me'd use to check if my board was working fine.

Checked my Null modem cable independently between PCs, and it was working fine. Connected the IDC10F to DB9M adapter to the beagle, and the PC on the other end using the null modem cable. Launched up hyperterminal, set the appropriate settings, and opened the connection. Was expecting the diagnostic messages to show up on the terminal when the beagle got powered up. However, that didn't happen.

Took some time to figure out what was happening. The IDC10 to DB9M adapter has two different configurations when it comes to internal wiring:
  1. IDC10F(1) to DB9M(1), IDC10F(2) to DB9M(6) , IDC10F(3) to DB9M(2) and so on.
  2. IDC10F(1) to DB9M(1), IDC10F(2) to DB9M(2), IDC10F(3) to DB9M(3)  and so on.
The configuration that would work with beagle's set up would be the one listed in (2) above. And the adapter Me had was wired like in (1). Rewired my adapter and it worked. Me could boot up into the board and could hear the crisp sound on the audio out as well.

The wiring that would be required on the DB9M to IDC10F adapter to work with Beagle will look like this:
The next step was to boot into the SD card on the MMC slot. The system reference manual detailed steps that would allow booting into the SD card and to play out a video file. It felt like an achievement to watch that video - Stephan Edberg playing a tennis match. 

The next milestone - to boot a demo linux image from SD card. There was a demo that Me'd seen at FOSS.IN - which had a full screen animation playing on it. Got to check that out.

Me.

Friday, December 12, 2008

Beagleboard - Grand Plan!

As my beagle was on its way, Me had started reading through various resources and gathering all possible information, trying to chalk out a plan about what to do once the board was in my hands.

Found these resources very helpful:
The beagleboard shopping list was pretty impressive. The minimalist kit listed out very well, all the minimum requirements and Section IV: Powering your Beagleboard explained in a concise manner, the various ways of powering up the Beagle board.

Roughly, this is my plan:
  1. First, boot up the board and have one of the demo images up and running so Me knows that everything on the board is working fine. In fact, this Beagleboard diagnostics page listed tests that would check every aspect of the board. Me was going to run these diagnostics on my beagle.
  2. Familiarize myself with the System Reference Manual.
  3. Get into exploring installing booting Linux on Beagle and enabling various peripherals.
  4. Work towards building a Car PC/ PVR for myself.
Was sure there would be obstacles to overcome. And frustrating moments too. Again, was hoping that Me'd have it in me to come over all those and stick to plan!

Regards,
Radha.

Thursday, December 11, 2008

Beagle - a push for innovation?

Opensource, Me believes thrives and has been so successful 'cause of the very tenets on which its based on - Freedom and community spirit. The freedom to modify software to suit one's needs, and the willingness to share information freely with the rest of the community have attracted me towards opensource stuff. Today, Me strongly believes in opensource and the qualities it brings to software/ hardware.

Beagle being opensource, Me believes, will foster in a lot of innovation. Me thinks that very soon, we'll have products being developed and shipped based on the design/ modified designs of Beagle. Me believes that the automotive infotainment space, personal PVR and projection systems will be the areas where Beagle will foster some good innovation. Mobiles and MIDs might be the other area.

To begin with, Me intends to use Beagle primarily for these purposes:
  1. To explore the world of ARM and Embedded Linux
  2. To try and see if Me can make a full fledged Car PC for myself. (More on that in a later post)
Here's wishing Me and my beagle the very best!

Beagle, my pal!

Had bumped into Beagle while looking out for some expandable platforms on which Me could try my ideas out. Must admit that Me was totally baffled at the power this small little 3"x3" beast packs in itself. Added to that, interesting videos like this and this and this and this gave me all the boost to go check it out at FOSS.IN where Khasim was hosting a talk about Beagle. Had a very good chat with him about the board, its features and how developers could use it.

And boy! what a revelation that interaction turned out to be! The first shocker was the fact that every part of this little thing is opensource! Right from the schematics to the software that enables the peripherals on the device, to the community based development of solutions - everything. Somehow, never imagined TI going the opensource way. My chat with Khasim firmed up my impression on Beagle even more. Khasim spoke about how he/ the beagle community can help small groups like us explore and try to work our dream products out.

Subbu also told me about how versatile a processor OMAP was and how Beagle would be the best companion to learn building linux devices from scratch.

At the end of FOSS.IN, Me was totally resolved that Me'd give this little thing a good shot. Lucky for Me, Sharat was returning from US, and Me had ordered a Beagle for myself through Digi-key, so he could get it here. Must point out here that the Live chat with Digi-key support staff was one feature that Me loved a lot.

A while later, 7th Dec 2008, Me met Beagle. Sharat was surprised to see that a 3"x3" board had support for so many functions. Its been a good 4 days since. Reading up the system reference manual, purchasing all the necessary peripherals, making up a kit with all these so Me could carry it around etc... etc...

Haven't been able to boot it up yet. And each of those attempts have been learnings of some sort. They'll follow in further posts.

Yes, slowly but steadily, our journey begins.

Me.