CevatBostancioglu 0 Posted August 8, 2015 Share Posted August 8, 2015 Hello , my problem is , energia msp432 pin mapping allows 2 serial ports. Serial and Serial1. and msp432 have a 4 hardware serial ports. so i want to add one more serial port to the msp432 energia firmware. i open a topic e2e.ti.com but they didn't answer yet. so maybe somebody help me here. https://e2e.ti.com/support/microcontrollers/msp430/f/166/t/444248 in energia ide , msp432 hardware serial pins are p1_2,p1_3 and p3_2,p3_3. but msp432p401r also have a two more hardware serial ports. p2_2,p2_3 and p9_6,p9_7. if we look at the hardwareSerial.cpp file , last 2 lines HardwareSerial Serial(0);HardwareSerial Serial1(1); and if we look hardware\msp432\variants\MSP_EXP432P401R\board_init.c file there is just 2 uart implemented with ti driverlib. but if we write Board_init.c: Board_initUART function like /* Set P1.2 & P1.3 in UART mode */MAP_GPIO_setAsPeripheralModuleFunctionInputPin(GPIO_PORT_P1,GPIO_PIN2 | GPIO_PIN3,GPIO_PRIMARY_MODULE_FUNCTION); /* Set P3.2 & P3.3 in UART mode */MAP_GPIO_setAsPeripheralModuleFunctionInputPin(GPIO_PORT_P3,GPIO_PIN2 | GPIO_PIN3,GPIO_PRIMARY_MODULE_FUNCTION); /* Set P2.2 & P2.3 in UART mode */MAP_GPIO_setAsPeripheralModuleFunctionInputPin(GPIO_PORT_P2,GPIO_PIN2 | GPIO_PIN3,GPIO_PRIMARY_MODULE_FUNCTION); and i also add other uart definations to above the Board_initUART function. but thats not working. so i discovery something. if we just delete something in board_init.c file , purpose of syntax error. like i am deleting ";' charecter one line of code , energia still compile the sketch. so energia doesn't compile board_init.c file. and i don't know how to compile it. there is makefile file but its not working for me. and i am bad compiling things. so how i can edit energia msp432 hardware/firmware ? do you have a any idea ? thanks cevat Cevat Bostancioglu Quote Link to post Share on other sites
SouperMan 0 Posted January 24, 2016 Share Posted January 24, 2016 You are not alone on this. Here is my post: Posted 29 April 2015 - 08:34 AM Does anyone know how to implement additional hardware based UART pins for the msp432p401r? I have looked in HardwareSerial.h where the Serial object is instantiated. There are clues here and also in driverlib's uart.h. In uart.h (and uart.cpp) there is a notation for all methods that indicate that they may be called with a parameter (moduleInstance) selecting which hardware serial module to use ie. EUSCI_A0_MODULE, EUSCI_A1_MODULE, EUSCI_A2_MODULE or EUSCI_A3_MODULE. There is also a cryptic notatation in the HardwareSerial.cpp file for methods setModule & setPins which states: "/* Change which pins UART is on */ /* need to implement */." Will this feature be implemented in the next version of Energia? I know that I can use SoftwareSerial to implement additional UART connections but why waste perfectly good silicon. Quote Link to post Share on other sites
Rei Vilo 695 Posted January 24, 2016 Share Posted January 24, 2016 Feel free to open a ticket at the Energia GitHub repository. 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.