RFM12Pi V2

From OpenEnergyMonitor Wiki
Revision as of 19:17, 12 April 2013 by Glyn.hudson (Talk | contribs)

Jump to: navigation, search

RFM12Pi V2

The RFM12Pi allows the Raspberry Pi to receive wireless data from RFM12B wireless module.

Technical Overview

  • ATmega328 based, has more memory and hardware serial support
  • Runs on the internal 8Mhz oscillator (to save unnecessary components)
  • SMT used, board layout is optimized for pick-and-place assembly
  • Lower profile to fit inside most Raspberry Pi enclosures
  • The new RFM2Pi with ATmega328 allows programming directly from Raspberry Pi using avrdude (..and OptiBoot)

Operational Overview

The RFM12Pi V2 consists of an RFM12B wireless module and an ATmega328 microprocessor running OptiBoot serial bootloader which is Arduino compatible.

The ATmega328 runs a slightly modified version of JeeLabs's RF12Demo raw wireless packets are passed to the Pi via serial using the Pi's internal UART serial port. The raw packets are processed by emoncms Raspberry Pi module, specifically the raspberrypi_run.php script. See emoncms documentation on emoncms.org for detailed documentation regarding setting up and running emoncms on a Raspberry Pi with an RFM12Pi.


RFM12Pi V2 Setup

The RFM12Pi V2 can be purchased pre-assembled and from the OpenEnergyMonitor shop [LINK] there sudo avrdude -v -p atmega328p -c avrispmkII -P usb -e -Ulock:w:0x3F:m -Uefuse:w:0x05:m -Uhfuse:w:0xDE:m -Ulfuse:w:0xE2:m -U flash:w:Optiboot328_8mhz_RF12_Demo.hex

Upgrading

Upload to 328 with ISP:

Sketch upload on Pi: cd /RFM2Pi/firmware/RF12_Demo_atmega328 avrdude -v -c arduino -p ATMEGA328P -P /dev/ttyAMA0 -b 38400 -U flash:w:RF12_Demo_atmega328.cpp.hex


Design Files

The board schematic, layout and firmware are available on github