zico 3 Posted May 5, 2016 Share Posted May 5, 2016 Hello, I am Using Energia 17 on TI MSP432 (Windows 7 PC): analogRead works for all the Analog pins except for A9. Initially, I thought that I must have just damaged the Analog port, but I have since tried this on numerous boards and they are all the same. Basically A9 is tied to A8, so whatever A8 is reading can also be read through A9. When I check the pins.h file, both A8 & A9 are mapped to "27", but I don't know what this "27" refers to or what the correct number should be for A9. If anyone knows how to find out the correct pin to use and how to modify it, please let me know. Thanks very much, Z. tripwire 1 Quote Link to post Share on other sites
Fmilburn 445 Posted May 5, 2016 Share Posted May 5, 2016 Hi @@zico The following is from the MSP432 quick start guide pin map... A8 is P4.5 and located on pin 27 of the LaunchPad A9 is P4.4 and located on pin 26 of the LaunchPad I think I got that right but haven't tried it yet but will do so when I get a moment. You can either change pins_energia.h to the above or refer to pin 26 in Energia to get A9. Pins are numbered like this on the LaunchPad (the starting and ending numbers are shown at the top and bottom of the headers): 1 21 40 20 2 22 39 19 .... 8 28 33 13 9 29 32 12 10 30 31 11 I will file a github request if I can confirm the error and fix. Edit: Confirmed that specifying pin 26 works. But has pins_energia.h been moved (or removed) in V17? Filed on github as issue #879 Edit: pins_energia.h is located in \hardware\emt\ti\runtime\wiring\msp432\variants\MSP_EXP432P401R. Confirmed that pins_energia.h is wrong. Change static const uint8_t A9 = 27 to static const uint8_t A9 = 26 tripwire and abecedarian 2 Quote Link to post Share on other sites
zico 3 Posted May 6, 2016 Author Share Posted May 6, 2016 Hi @@Fmilburn, Thanks, I changed the pins_energia.h file and everything is working perfectly now. Thanks also for the link to the Launchpad pin map guide ... all makes sense now! Thanks again, Regards, Z. Quote Link to post Share on other sites
Rei Vilo 695 Posted May 6, 2016 Share Posted May 6, 2016 The pull-request with the fix is ready and awaiting approval. I can't pull the fix because this specific file comes form emt @ a350116 and I don't have access to it. Only @@energia has the authorisation. See Fix for A9 on MSP432 #1 and pull-request Fix for A9 on MSP432 #2. Thank you for reporting the bugs and providing all the details! Fmilburn 1 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.