Jun 15

LowPowerPCs.com contest! Win a RaspberryPi!

Just got an email from Jon at Low Power PCs.

They are holding a contest to win a Raspberry Pi.  From their site:

In order to win this pocket sized computer you must do your best to impress us by your geekyness and creativity. You should comment on this post with a link to a youtube clip that you’ve created to say/demonstrate why YOU should win the Rasperberry Pi.

The Rules

  • You MUST be based in the UK as we will only ship this to a UK address.
  • Post your entry as a comment to this post and include the link to your YouTube clip.
  • Entries that don’t include our website URL and Raspberry Pi in their content will be excluded from the results.
  • All entries must be received by 21:00 UK Time on the 6th July 2012.
  • We will review the entries on the 7h July 2012 and announce what we thought was the most impressive video (content wise, not necessarily technically) by the 8th July 2012.
  • Only 1 entry per person.
  • The winner of the Raspberry Pi will be announced on the 8th July 2012
  • By entering our competition you agree for us to publish your youtube clips on our website www.lowpowerpcs.co.uk

Good Luck!

-Shea

Jun 13

Raspberry Pi and MAME Part 2

THIS IS AN OLD POST!  Please go to the latest update here!

Hello everyone from raspberrypi.org!  Thanks for visiting, more updated tutorials and binaries are available by clicking the menu item Raspberry Pi Gaming!

UPDATE: New Raspbian Binaries Available (new binaries above)

So I’ve spent even more time playing around with my MAME compile and my Raspberry Pi.  I have a new set of downloads, once is a set of binaries so you don’t even need to do a make install.

  1. Unzip MAME directory.
  2. chmod 777 /dev/fb0
  3. Put your roms into mame/share/advance/roms/
  4. run mame/bin/advmame
    1. The first time it’s run it will generate a set of folders and files into ~/.advance
  5. edit your ~/.advance/advmame.rc to include the proper display configuration
    1. For HDMI try:
      1. device_video_clock 5 – 50 / 15.62 / 50 ; 5 – 50 / 15.73 / 60
    2. For NTSC TVs try:
      1. device_video_clock 5 – 50 / 15.73 / 60
  6. run mame/bin/advmame <gamename>
    1. cd into mame/bin/ then ./advmame gamename
  7. ENJOY!!!

Download AdvanceMAME Raspberry Pi Binaries

As an aside, I overclocked my Pi to 900Mhz, and Street Fighter 2 is slow, but playable 😀

edit: fixed an error in the path.  Also added a different way to run advmame (the way I run it).  Just cd into the bin directory then ./advmame gamename.

 

Jun 06

raspberryPI and MAME

UPDATE: Edited to fix some issues.

SECOND UPDATE: New Post with new binaries!

 

So for the past few days I’ve been struggling to get MAME running on the raspberryPi.  It was compiling, it would install, but I would always get a video_fault error.  It ended up being that I had to modify the .rc config to have the correct display settings.  I’m using a TV with the RCA plug so YMMV.

Edit: I’m also logged in as root.  I know this is bad but I haven’t been able to get it working without being root.  There is no password set for root, so you have to make one before you login as root or “su” to root.

sudo passwd root

http://advancemame.sourceforge.net/doc-install.html#4.5  – This link will help you find the correct display settings.

http://sheasilverman.com/rpi/advancemame-0.106.1.zip – This is the compiled AdvanceMame for raspberryPi.  Extract it to a folder, then type:

make install

You can then run mame by typing advmame at the command prompt.  The first time it runs it makes a config file, then quits.  You should find the folders and configs in ~/.advance/ /root/.advance/. ROMs go in ~/.advance/roms /root/.advance/roms/ .   The config file ends in “.rc”  Edit that file to include your display information.

For HDMI try:

device_video_clock 5 – 50 / 15.62 / 50 ; 5 – 50 / 15.73 / 60

For NTSC TVs try:

device_video_clock 5 - 50 / 15.73 / 60

I don’t know how long I can keep the compiled source on my host as I have limited bandwidth, but for now, it will be here.  I’ll try and find a mirror as well.

 

Jun 03

Raspberry Pi tip 2

The debian squeeze distro for Raspberry Pi will not allow you to “su” only “sudo”.  The reason for this is because no password has been set for the “root” account.  To fix this, type into the command line:

sudo passwd root

Enter in the password you could like for the root account and you should be good to go.

Jun 03

Raspberry Pi!

So, I recently got my Raspberry Pi and have been having a lot of fun with it.

Programming in Python on it, running Quake 3 Arena, trying to compile different apps with various states of success.  Using Google Chromium on it.

The experience has been amazing.  This $35 machine has allowed me to play games, browse the modern internet, program, all using hardware I have laying around.

The Raspberry Pi outputs to both HDMI and RCA, so I’ve been using an old studio monitor at work as a display and it runs great.  At home I connect it via HDMI and it looks beautiful.

I am in the middle of uploading an iso/image file of my SD card so if anyone wants to try out these features without having to go through the setup, they can.

I plan on also updating with some tips and tricks.

I want to thank the blog http://myraspberrypiexperience.blogspot.co.uk/ – They have provided some wonderful guides so far.

One of my goals is to get the LOVE2D framework compiled.  At the moment, it won’t work because of the non existant OpenGL drivers, but nLove is available, and was made for ARM based platforms.  I am having difficulty getting it compiled, but I’m going to keep trying.

First tip to remind myself:

sudo mv /boot/boot_enable_ssh.rc /boot/boot.rc

This will enable ssh on the device at bootup.  If you just want to enable ssh once, then at the command prompt enter:

sudo /etc/init.d/ssh start

This assumes you are running the Debian Squeeze Raspberry Pi image.

Apr 03

Arduino and EL Escudo

Another fixit type post.  Every so often I repurpose my Arduino and EL Wire for a new project, and each time I always forget how to properly get the EL_Escudo library resetup.  I should probably just fork the code on GitHub with the fixes that have been posted, but who remembers to do that.

So, the EL Escudo is a cool shield for the Arduino.  SparkFun sells it.  I highly recommend them.  There is a small bug in the library code that is fixed by bobmct’s post (http://www.sparkfun.com/products/9259#comment-4eaad859757b7fd35100ba5d):

“I realize this is a rehash of what others above have said, but I got mine to work by doing the following.

Getting the El Escudo to work
Two problems:
1. Must fix a mistake in the library code: Needed to make in EL_Escudo.cpp (thanks BMK):
void EL_EscudoClass::on(char channel)
{
pinMode(channel, OUTPUT);
digitalWrite(channel, HIGH);
}
void EL_EscudoClass::off(char channel)
{
pinMode(channel, OUTPUT);
digitalWrite(channel, LOW);
}
2. They also recommend GND and HVGND are tied together. Look at photo (thanks miku) http://dl.dropbox.com/u/3551240/el-escudo.JPG . With the code change made above I also tried to see if the El Scudo would work without this jumber (between GND and HVGND), and it did work and it did work without it. I was using the EL_Blink.pde example when testing this.
The above got things to work with a handheld 3V inverter (two AA battery powered) with the button pressed 3 times (a steady AC supply, no blinking) with the output of this inverter connected to the El Escudo shield’s “EL Driver Inverter Ouput” JST jack.
The Arduino was powered from a 5VDC wall transformer (1A capacity) with the barrel jack plug connected either on the Arduino’s barrel jack connector or connected to the El Scudo’s “EL Driver Raw Voltage” JST connector.
You will need to fabricate the strange El Wire plugs to JST plugs to make all the connections. In my experience above, the polarity was not a factor because the output from the inverter is AC and so is the input to the el wire.
Hope this helps.”

My only issue was with number 1.  Fixing that caused the main library to work again.

With the upgrade to Arduino 1.0, WConstants.h will throw an error since that isn’t being used anymore.  You should be able to safely change all WConstants.h to Arduino.h

 

Mar 27

PhoneGap 1.5.0 and iOS 5.1

Hey All,

Just posting here so I remember some fixes I had to do with the new release of PhoneGap 1.5 (also known as Cordova).

When you initially run your new xCode product, you will get a ton of “semantic” issues.  The fix is to go to Build Settings -> Objective-C  Automatic Reference Counting -> “NO”

I found this clarification from a comment posted by Alejandro Orduz at http://phonegap.com/2012/03/06/phonegap-1-5-released/ 

“ok, i manage to make it work, Cordova, under Xcode 4.3.1…. regarding the www stuff…

First of all, getting into this painful process(more of all because of my lack of knowledge of Xcode), i wen to the process to upgrade my iPhone to the latest iOS 5.1, then had to upgrade Xcode to 4.3.1 to support testing in this device, but also did an upgrade to the latest lion 10.7.3…. so it was a boring weekend of upgrading….

The first time you run a new phone gap project under Cordova, is not like old days, now when you run you get a scary 9 errors warnings about a Semantic Issue in some, NSAutoreleasePool well, for some of us, that is like speaking chinease… but it can be solved very easy… the new Xcode has some Automatic Reference Counting ON by default, so you just go to the project Build Settings, find Objective-C  Automatic Reference Counting and change it to “NO”, after that everything goes to normal…. then it can build, add the www, you get the normal iPhone simulator error, and then, like before, had to drag and drop the www folder into the project root….

Changes like this are very scary for people like me, that found phonegap an amazing tool to build mobile apps with our web development knowledge…. :-{  ”

Also! I finally got the camera example working.  I was receiving a weird “wait_fences: failed to receive reply: 10004003” when I used the Camera example code verbatim.  It would work, but I would only recieve a small blue box on my iPhone.

The issue is that the code on line 40:

smallImage.src = “data:image/jpeg;base64,” + imageData;

is wrong.  PhoneGap 1.5 / iOS 5 stores the taken photo in a temporary directory, so you dont get the base64 data anymore, you have the actual URI for the photo in imageData.  All you need to do is change line 40 to be:

smallImage.src =  imageData;

and it will work.

 

I hope this helps out some people.  It’s working for me, YMMV.

-Shea

Mar 15

PyCon 2012

I’m going to start this blog with an account of my recent trip to PyCon 2012.

My University sent me there to learn, network, and be a representative.  I had a blast.  I have learned an immense amount and met an amazing group of people.

There were 2500 incredibly bright and talented individuals at this event.

To those who could not make it, PyCon has made available recordings of all the sessions at: Pyvideo.org

One of my favorite session talks: Building A Kinect Game With Python

I also have exported my bookmark list.  During the event, whenever someone mentioned any neat tool, company, or site, I went there and bookmarked it.  There are some python sites, some music sties, some random sites, and some fun sites.

You can find my bookmarks here: PyCon 2012 Bookmarks

Enjoy!

-Shea