Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.
Photo

RFM12B over SPI


  • Please log in to reply
4 replies to this topic

#1 Foozinator

Foozinator

    Member

  • Members
  • PipPip
  • 16 posts

Posted 17 January 2011 - 07:00 AM

I'm struggling to get the Netduino talking with the RFM12B radio (http://www.sparkfun.com/products/9582) over SPI, and I'm running out of ideas. I based the code on the Arduino libraries (http://jeelabs.org/2...9/new-rf12demo/). Attached is my demo code. I'm getting intermittent problems with the nIRQ line. It either never goes down or it never goes up. If the interrupt handler fires (sometimes even before the radio setup is done), the data coming back is much larger than the buffer, and doesn't look right at all (something like 128, 128, 0, 0, 64, 8, 0, 4, 4, etc.) Also, if I attach the interrupt handler, I get garbage reads before the radio is even initialized. It looks like port.DisableInterrupts doesn't actually disable the interrupts. I've tried a bunch of variations on the SPI configuration, and I haven't gotten the radio to respond well at all. Does anyone have any ideas? Attached File  RF12BTest.zip   1.99KB   31 downloads

#2 Illishar

Illishar

    Advanced Member

  • Members
  • PipPipPip
  • 146 posts

Posted 17 January 2011 - 08:08 AM

I've read somewhere that the SPI (driver/hw) might be buggy on the Netduino. I can't remember the details though. The user could make it work with the FEZ Panda, but not Netduino. Maybe I can find the thread again ...

#3 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 17 January 2011 - 04:31 PM

Hi Foozinator, What firmware version are you using? v4.1.0.5 or one of the alpha/beta releases? We've been adding some functionality to SPI in the v4.1.1, so it's possible that we've introduced a glitch which may be affecting you. Have you tried using SPI with any other devices? Chris

#4 Foozinator

Foozinator

    Member

  • Members
  • PipPip
  • 16 posts

Posted 17 January 2011 - 07:14 PM

What firmware version are you using? v4.1.0.5 or one of the alpha/beta releases?


I'm using v4.1.0.5.

I haven't tried to use SPI with anything else, only I2C (which works with the 24LC256 EEPROM).

#5 mHammer

mHammer

    Member

  • Members
  • PipPip
  • 23 posts

Posted 14 June 2013 - 03:23 AM

Hi Foozinator, Did you ever further develop your code? I am trying to setup some arduino motes using the rfm12b module. I haven't got too deep, but I'm curious if anyone has had good success with this radio and netduino to arduino communication. I've seen lowpowerlabs code and its amazing. I would hope to have something similar on .net Thanks




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.