sirri 28 Posted December 3, 2012 Share Posted December 3, 2012 Basic analogRead function doesn't seem working.. I am using Energia as a compiler. I am trying the minimum configuration. I am getting a value but this value doesn't change with potentiometer. I have even tried to ground the signal (to see if it is Zero) but nothing has changed.. What might be wrong? thanks . Quote Link to post Share on other sites
Rickta59 589 Posted December 3, 2012 Share Posted December 3, 2012 You need to use A5 instead of P1_5. sirri 1 Quote Link to post Share on other sites
energia 484 Posted December 3, 2012 Share Posted December 3, 2012 The analogRead() function needs as argument the ADC channel. In your case this is A5. try replacing: int sensorPin = P1_5; with static uint8_t sensorPin = A5; You can find a pin mapping diagram here: https://github.com/energia/Energia/wiki/Hardware sirri 1 Quote Link to post Share on other sites
sirri 28 Posted December 3, 2012 Author Share Posted December 3, 2012 Thanks. I have changed it. But still isn't working. I am making a silly mistake but where :// Adding the screen caps. PS: I have checked the output of potentiometer with a multimeter. It is ok : / PS2: I am using MSP430G2211 right now (i also have MSP430G2231) Quote Link to post Share on other sites
sirri 28 Posted December 3, 2012 Author Share Posted December 3, 2012 https://github.com/energia/Energia/wiki/Hardware .....Energia supports the LaunchPad with msp430g2231, msp430g2452 and msp430g2553. These are the most popular devices.... Well msp430g2211 seems to work too except analogRead.. :/ I have replaced it with msp430g2231 and now it is working like a charm ! Thanks a lot ! yay! finally Quote Link to post Share on other sites
simpleavr 399 Posted December 3, 2012 Share Posted December 3, 2012 Well msp430g2211 seems to work too except analogRead.. :/ that's because g2211 does not have adc. it only has comparators. sirri 1 Quote Link to post Share on other sites
AbhishekBaghel 0 Posted June 25, 2015 Share Posted June 25, 2015 hi,I want to know that how can we increase the number of analog input pins on MSP 432 from 24 to 48 or more.Please tell any solution for muxing booster pack. Quote Link to post Share on other sites
roadrunner84 466 Posted June 25, 2015 Share Posted June 25, 2015 hi,I want to know that how can we increase the number of analog input pins on MSP 432 from 24 to 48 or more.Please tell any solution for muxing booster pack. Why not just use two MSP432s and let one talk to the other via UART? Quote Link to post Share on other sites
dubnet 238 Posted June 25, 2015 Share Posted June 25, 2015 Or you could use an analog multiplexer. They used to come in 8 and 16 channel versions. TI (the old Burr Brown product line) should have them. Quote Link to post Share on other sites
AbhishekBaghel 0 Posted June 26, 2015 Share Posted June 26, 2015 Thanks for yr replies... Hi, My main aim is to data log into single memory card(32GB) of around 48 analog channels at speed of 1000 samples per second per channel.Please tell me about the best solution. As I know that speed of ADC in msp432 is 1MSPS so it is optimal for my solution.So by using UART & 2 MSP432 Launchpads ,can I send data to the one memory card interfaced with first launchpad?? As i need the data of 48 channel simultanously at an instant(not even a dely of 1ms is permissible ).Than I think muxing is not the solution of problem.Please help... Or you could use an analog multiplexer. They used to come in 8 and 16 channel versions. TI (the old Burr Brown product line) should have them. Why not just use two MSP432s and let one talk to the other via UART? Quote Link to post Share on other sites
dubnet 238 Posted June 26, 2015 Share Posted June 26, 2015 If you want to sample 48 channels without any phase skew then you may need to use 48 sample and hold devices, sampling at the same time and then converting all the channels. You may still need to use an analog mux(es) to handle the number of channels. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.