Try to set define OSC 8. The OSC needs to be in caps.
Try to set define OSC 8. The OSC needs to be in caps.
It was communicating with the terminal program at 9600 baud without a problem... wouldn't it have spouted gibberish if it didn't use 8Mhz? I'll use uppercase to be safe.
But I think I figured out the problem... I was communicating with the clock pin idling low... it should have been idling high. Therefore the pic was not shifting the right data or the right register address to the ADXL375, and so it never got into measurement mode. After I changed it to idle high, I started getting values that looked meaningful (but very noisy!), although I think that's just because I don't have any filtering on the power supply or at the IC pins (just wanted to get it working). I'll try that next.
Dave
Are you using internal oscillator?
It's using an external crystal with the "HS" oscillator setting.
After adding some caps, the output is much better and it's clearly exporting acceleration data correctly. Flipping it around on all axes show the expected +/-1g change. The offsets are rather large (+3g in some axis), but that can be adjusted/calibrated.
Bookmarks