Jump to content


  • Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by NatureTM

  1. You're right. Maybe doing that will get things working as well.
  2. No, val should contain a representation of the voltage read. You can just leave that val assignment by itself in the for loop. On the line #define PHOTOCELL INCH_0, INCH_0 means input 0. The sensor(a photocell) is connected to P1.0. If it said INCH_1, that would mean it was connected to P1.1.
  3. That code that I linked you to will read voltage using the ADC10.
  4. Well here's something from the code section of the forum for the ADC. http://www.43oh.com/forum/viewtopic.php?f=10&t=95 First learn to read a voltage with the ADC. Once you can do that, you should be able to make it work with your sensor. What are you building?
  5. What microcontroller? got a datasheet for that sensor? can I see ur code?
  6. Oh here's the code that I used for adding the calibrations if anyone else wants to try. #include "msp430x20x1.h" #include "DCO_Library.h" unsigned char CAL_DATA[8]; // Temp. storage for constants volatile unsigned int i; int j; char *Flash_ptrA; // Segment A pointer void Set_DCO(unsigned int setting); void main(void) { WDTCTL = WDTPW + WDTHOLD; // Stop WDT for (i = 0; i < 0xfffe; i++); // Delay for XTAL stabilization P1OUT = 0x01; // Red LED on P1SEL = 0x10;
  7. Well I think I got that flashcal program working and managed to write the calibrations. I was hoping to not have to use a crystal with my TV output prog. I used my setDCO lib instead of their function and it wrote values to flash that looked correct. I then edited the msp430g2231.h and msp430g2231.cmd files to include the definitions for the calibrations, but when I tried to compile, i still got "error: identifier "CALDCO_16MHZ" is undefined." I'm not sure what else to edit.
  8. I prefer hole on hole. Now that sounds way too dirty.
  9. Here's the writeup: http://naturetm.com/?p=47 I've attached two versions of the code, one for use with an external 16MHz oscillator, and one for if you have your 16MHz DCO constant calibrated. Launchpad_TV_Out.rar Launchpad_TV_Out_for_calibrated.rar
  10. I got my Launchpad to output B/W composite video. It only displays one image without re-flashing though, so it's not extremely useful. The only external components are two resistors and a crystal oscillator. I plan on writing it up on my blog and releasing the source sometime this week, unless I get too busy with school. I wasn't sure if I'd be able to ever get this working, so I'm feelin' pretty good right now! Proof ;-) Code for use with an external oscillator: Launchpad_TV_Out.rar Code for if you have your DCO configuration constants calibrated: Launchpad_TV_Out_for_calibra
  11. Awesome! I've actually been sitting on this for awhile. I just got my hands on a cheap oscilloscope so I could directly verify the clock speed, even though it was working with some timing-dependant stuff. Just wanted to be sure!
  12. Here's an existing TI lib I modified to work with the Value Line series and CCS. Since the G series doesn't come with factory-calibrated DCO settings, I wanted an easy way to set the MCLK to 16MHz or some other arbitrary frequency. A TI library existed for setting the DCO using an external watch crystal as a reference, however it didn't work with the G series. It just took some minor editing. I think this should be nice for Launchpad owners especially, since the kit comes with an external crystal and a 16MHz rated chip. DCO Library: http://naturetm.com/files/Launchpad%20setDCO%20lib
  13. FFT is pretty RAM intensive. I know there are some very simple software lowpass and I think highpass filters that are out there, but I've never tried them so I don't know how well they work.
  14. I've never used IAR. Give it a shot I guess.
  15. Just create a project and drag the files to the project folder on the left. I think the library was meant to compile on IAR but not CCS so I tried to make it work with CCS.
  16. I got the example to compile and upload, but I don't know whether it will work or not. I had to change the assembly function to work with CCS instead of IAR. I commented out some stuff in the assembly that I don't think is necessary, but I'm really not sure, so don't assume it works. Hopefully. Anyway, if you want to try it: http://naturetm.com/files/I2C_Slave.rar
  17. NatureTM


    Hey. I've googled around for msp430 stuff for awhile now and come across this site a few times. I guess it's about time I join the forum! I'm in my second semester for my bachelor's degree in CE. I had a business degree that wasn't working out as great as I expected, so I decided to go back to school for something more challenging and hopefully more "rewarding." I got into microcontrollers and programming in general when I bought an Arduino about two years ago. When Launchpad came out, it seemed like a cheap way to expose myself to something new, and I haven't used the Arduino much since
  • Create New...