Skip to content

Instantly share code, notes, and snippets.

@guumaster
Last active August 29, 2015 14:08
Show Gist options
  • Save guumaster/fd3b8014e5cad69686b7 to your computer and use it in GitHub Desktop.
Save guumaster/fd3b8014e5cad69686b7 to your computer and use it in GitHub Desktop.
How to check your Raspberry Pi revision
import RPi.GPIO as GPIO
if GPIO.RPI_REVISION == 1:
ports = [0, 1, 21]
else:
ports = [2, 3, 27]
print "Your Pi is a Revision %s, so your ports are: %s" % (GPIO.RPI_REVISION, ports)

cat /proc/cpuinfo

  Hardware	: BCM2708
  Revision	: 000f

These are the known revision up to Q4 2014.

-Revision Release Date Model PCB Revision Memory Notes -Beta Q1 2012 B (Beta) ? 256MB Beta Board -0002 Q1 2012 B 1.0 256MB -0003 Q3 2012 B (ECN0001) 1.0 256MB Fuses mod and D14 removed -0004 Q3 2012 B 2.0 256MB (Mfg by Sony) -0005 Q4 2012 B 2.0 256MB (Mfg by Qisda) -0006 Q4 2012 B 2.0 256MB (Mfg by Egoman) -0007 Q1 2013 A 2.0 256MB (Mfg by Egoman) -0008 Q1 2013 A 2.0 256MB (Mfg by Sony) -0009 Q1 2013 A 2.0 256MB (Mfg by Qisda) -000d Q4 2012 B 2.0 512MB (Mfg by Egoman) -000e Q4 2012 B 2.0 512MB (Mfg by Sony) -000f Q4 2012 B 2.0 512MB (Mfg by Qisda) -0010 Q3 2014 B+ 1.0 512MB (Mfg by Sony) -0011 Q2 2014 Compute Module 1.0 512MB (Mfg by Sony)

or execute: sudo python ports.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment