Jump to content
hikayihan

MSP430G2230 + SPI EEPROM(25C320) + ACCELEROMETER(ADXL362)

Recommended Posts

Hi everyone. First of all, i am new with msp430 microcontrollers and i have a project that i think it is hard for beginners but i must do it :)

 

I will take the data from accelerometer and write it to the eeprom. I will use msp430g2230. eeprom and accelerometer both are communicating with SPI. I must sample the data at least 1Hz. 

 

I just learned about registers and SPI and worked on msp430ware codes about SPI communication a little bit. Where can i start this project? What are your suggestions and do you know any source related to my project?

Share this post


Link to post
Share on other sites

First few things I would do would get the data sheets for the devices you are working with. This will make your life much easier when you need to write the driver code for the eeprom and the accelerometer. The data sheet can be found here for the ADXL362:

 

 http://www.analog.com/en/mems-sensors/mems-accelerometers/adxl362/products/product.html

 

The eeprom:

 

http://ww1.microchip.com/downloads/en/DeviceDoc/21227E.pdf

 

If you want some pre-made code already made for the ADXL362, you can port the Arduino code to your MSP430 using the stuff off sparkfun.

 

https://www.sparkfun.com/products/11446

 

This code works. I've ported it over to the LPC1769 before to test out the ADXL362 I was using in a project. 

Share this post


Link to post
Share on other sites

Not sure how useful it would be, but here is an example of a data logger for an accelerometer that somebody did using the Fraunchpad

(MSP430 with onboard analog accelerometer and FRAM for non-volatile storage).  

Obvsiously device access routines will be different using SPI http://forum.43oh.com/topic/1309-fraunchpad-accelerometer-datalogger/

 

I would probably start with getting each piece going

* read the accelerometer and just echo the result to console port

* write to eeprom

* get something to happen at 1 KHz (e.g. set up timer interrupt and have it do something like print a character of flash the LED at 10 Hz, then scale up).

 

Figure out how you are going to read back the eeprom data (i.e. do you need a program, etc. for that, or will you connect to another device to read back the data).

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×