Main Site Documentation



Hi, I have your accelerometer extension and I am having trouble getting it working. I’ve added the provided “driver” code. When I call FEZ_Extensions.Accelerometer.Initialize() it throws an error. The error seems to be thrown on the ReadRegister(0x14) call near the end of FEZ_Extensions.Accelerometer.Initialize(). Any help would be appreciated.

Also I thought I might mention that the circuitry on the accelerometer looks quite a bit different then in the picture on the website. It has MOD-24LR printed on it. I thought I’d mention this just in case I wasn’t sent an accelerometer.



First of all, since you did not provide info, do you have the latest firmware/sdk?

Might save a lot of thinking, so would be nice if you could provide us with some info… :smiley:


It looks like we shipepd you an RF board by mistake. You can keep it, we will be sending you an accelaramotor board soon


@ Supa, Awesome thanks!

@ Foekie, I didn’t think it was necessary to provide those things since the problem was so specific. Sorta like telling people what engine you having in your car when you need help with your breaks :wink: Seems like it could confuse the issue more then help but since I’m new here and you’re not I’ll go ahead and take your advice and provide them from now on. It’s V :slight_smile:


the main reason that question gets asked, particularly when it’s someone’s first post, is because it’s the #1 reason for “unexplained” exceptions. You’ve now progressed past that point, so you’re probably ok not to bother telling us that from now on :slight_smile: :stuck_out_tongue:

Another great outcome and a great sign of how the GHI folks put so much emphasis on making us all happy !


Haha ok, the old “Is it plugged in?” I can appreciate the wisdom in starting there with a new user :slight_smile:


@ mmadink



LOL, too funny.

Have you all seen this one?


Oh man, thats funny!
Each episode keeps getting funnier!

Episode 1 reminds me of the conversations with our web guy :wink:


I have a Fez Mini with the SMB380 accelerometer, but when i lunch the program with the genuine driver the result is :
‘System.InvalidOperationException’ in Microsoft.SPOT.Hardware.dll

the error occurs in this source code :
static private void WriteRegister(byte address, byte value)
write[0] = address;
write[1] = value;
_spi.WriteRead(write, read); <===ERROR

mine parameters are :
HalSystemInfo.oemCode: 0
HalSystemInfo.modelCode: 0
HalSystemInfo.skuCode: 0
ClrInfo.clrVersion: 4.0.1681.0
ClrInfo.clrVendorInfo: Microsoft Copyright © Microsoft Corporation. All rig
ClrInfo.targetFrameworkVersion: 4.0.1681.0
SolutionReleaseInfo.solutionVendorInfo: GHI Electronics, LLC
SoftwareVersion.BuildDate: May 21 2010
SoftwareVersion.CompilerVersion: 310739
FloatingPoint: True
SourceLevelDebugging: True
ThreadCreateEx: True
LCD.Width: 0
LCD.Height: 0
LCD.BitsPerPixel: 0
AppDomains: True
ExceptionFilters: True
IncrementalDeployment: True
SoftReboot: True
Profiling: False
ProfilingAllocations: False
ProfilingCalls: False
IsUnknown: False

do you have an idea ?


It is better if you start a new topic instead of using older ones…just so everyone can keep track and not get confused.

The line you pointed to is fine so the problem is in the passed buffers. Did you use our code with no modifications? It should just work.
Also, did you try to start simpler, like blink LED then try th accelerometer?


i start a new topic, you’re right