[MCU] 【MSP432评测】迟来的开箱测试

[复制链接]
1886|14
 楼主| yinwuqing110 发表于 2020-4-18 16:44 | 显示全部楼层 |阅读模式
本帖最后由 yinwuqing110 于 2020-4-18 16:47 编辑

       昨晚发帖没有保存到草稿箱,过了晚上十一点,平台不接受任何的发帖存储,哎,悲哀,我服了这个规定了!今天周六来补补昨晚的帖子吧。其实收到MSP‑EXP432P401R LaunchPad开发套件是在周一晚上,至于有关MSP432P401R的开发资料,早已经准备好了,由于公司正在进行新项目的开发,所以最近没来得及发帖评测MSP432P401R。其实TI的在各大网站论坛举办的活动层出不穷,收到的礼品都是有TI的**。但TI举办的开发板试用评测的活动还是比较少的,所以能够通过此次MSP432P401R开发板试用的申请,也属幸运了。
      收到快递包裹后,拆开包装袋,有一个标识好MSP‑EXP432P401R LaunchPad开发套件的盒子,盒子底部一如既往地采用TI的**。

         然后拆开盒子,里面有此次评测的开发核心板,使用防静电袋封装着。还有Micro USB数据线,用来连接PC端,可当串口下载线,提供了快速操作手册,小喇叭的发帖提醒语,来一张全家福如下:

      阅读快速操作手册,可以得知关于此开发板的大概资源,下载资源及软件开发包的链接网址。这里着重介绍如何去使用官方提供的“outofbox_msp432p401r”工程。

       接下来打开防静电袋,取出MSP432P401R核心板,来一张正面特写

        MSP432P401R是MSP432系列器件中首款具有ARM Cortex-M4F内核的低功耗高性能产品。板卡上面集成了按键、LED等外设。开发板是黑色的,官方提供的资料都是针对红色的,那么它们到底存在哪些差异呢?其实两者区别不大,只是存在几处不同,开发起来两者并无其他区别。

     MSP-EXP432P401R的模块框图如下:

     核心MCU采用100PIN的QFP封装,MSP432P401RIPZ的pin脚定义如下:

     然后来看看板卡的底面,底面没有采用一个电子元器件,有的只是两个双排10pin的2.54mm母座插针孔,图案很有个性。

      了解了板卡上的硬件资源,接下来搭建软件开发平台。MSP432P401R支持GCC、CCS、Keil以及IAR集成开发工具,由于本人使用的Keil比较多,习惯先搭建一下基于Keil的开发环境。首先根据快速操作手册指引,进入SDK下载网址,如下图所示:

       下载SDK后,双击安装即可。然后下载使用Keil的支持pack包,地址在pack包下载网址中查找,然后下载

      下载完“TexasInstruments.MSP432P4xx_DFP.3.2.6.zip”的pack包后,然后解压,进入到“TexasInstruments.MSP432P4xx_DFP.3.2.6\Examples\BlinkLED\ARM”目录下,双击打开“BlinkLED”工程,Keil会自动获取拷贝,完成pack包的安装,如下图所示:

     完成了pack包的安装,然后进入“D:\ti\simplelink_msp432p4_sdk_3_40_01_02\examples\nortos\MSP_EXP432P401R\demos\outofbox_msp432p401r\keil”(当然我的SDK是安装在D盘根目录下)目录下,打开快速操作手册所推荐的工程“outOfBox_msp432p401r”,然后进行全编译,没有错误,没有警告,说明工程已经导入成功。main.c的程序如下:
  1. #include <ti/devices/msp432p4xx/driverlib/driverlib.h>
  2. #include <time.h>
  3. #include <stdlib.h>

  4. #define MCLK_FREQUENCY 3000000
  5. #define PWM_PERIOD (MCLK_FREQUENCY/5000)

  6. unsigned int S1buttonDebounce = 0; // Deboounce state for button S1
  7. unsigned int S2buttonDebounce = 0; // Deboounce state for button S1

  8. int32_t interval = 0;       // Elapsed interval between taps
  9. int32_t periods[4];         // LED blink periods for each color state
  10. int oldTick = 0;            // SysTick value of previous tap
  11. int newTick = 0;            // SysTick value of current tap

  12. int counting = 0;           // Whether currently counting taps and interval between taps
  13. int count = 0;              // Counts # of seconds elapsed since last tap
  14. int sysTickCount = 0;       // Counts # of SysTick interrupts since last tap
  15. int taps = 0;               // Counts # of taps from last reset

  16. /* Current color of the blinking RGB LED
  17. * 4 possible states: R, G, B, random color */
  18. unsigned int currentColor = 0;

  19. #define RED     255
  20. #define GREEN   255
  21. #define BLUE    255

  22. int bytesReceived = 7;      // Keeps track of # UART bytes received
  23. int32_t receiveFreq = 0;    // Receives LED blink frequency from GUI
  24. char start[5];              // Receives 'START' keyword
  25. int ack = 0;                // Track acknowledgement sent to GUI

  26. /* TimerA UpMode Configuration Parameter */
  27. const Timer_A_UpModeConfig upConfig =
  28. {
  29.         TIMER_A_CLOCKSOURCE_SMCLK,              // SMCLK Clock Source
  30.         TIMER_A_CLOCKSOURCE_DIVIDER_1,          // SMCLK/1 = 3MHz
  31.         45000,                                  // 15ms debounce period
  32.         TIMER_A_TAIE_INTERRUPT_DISABLE,         // Disable Timer interrupt
  33.         TIMER_A_CCIE_CCR0_INTERRUPT_ENABLE ,    // Enable CCR0 interrupt
  34.         TIMER_A_DO_CLEAR                        // Clear value
  35. };

  36. const Timer_A_UpModeConfig TA2upConfig =
  37. {
  38.         TIMER_A_CLOCKSOURCE_SMCLK,              // SMCLK Clock Source
  39.         TIMER_A_CLOCKSOURCE_DIVIDER_64,         // SMCLK/64 ~ 46.9 kMHz
  40.         46875,                                  // 1s timer period
  41.         TIMER_A_TAIE_INTERRUPT_DISABLE,         // Disable Timer interrupt
  42.         TIMER_A_CCIE_CCR0_INTERRUPT_ENABLE ,    // Enable CCR0 interrupt
  43.         TIMER_A_DO_CLEAR                        // Clear value
  44. };

  45. /* Port mapper configuration register */
  46. const uint8_t port_mapping[] =
  47. {
  48.     //Port P2:
  49.     PM_TA0CCR1A, PM_TA0CCR2A, PM_TA0CCR3A, PM_NONE, PM_TA1CCR1A, PM_NONE, PM_NONE, PM_NONE
  50. };

  51. /* UART Configuration Parameter. These are the configuration parameters to
  52. * make the eUSCI A UART module to operate with a 115200 baud rate. These
  53. * values were calculated using the online calculator that TI provides
  54. * at:
  55. *http://processors.wiki.ti.com/index.php/USCI_UART_Baud_Rate_Gen_Mode_Selection
  56. */
  57. const eUSCI_UART_ConfigV1 uartConfig =
  58. {
  59.         EUSCI_A_UART_CLOCKSOURCE_SMCLK,          // SMCLK Clock Source
  60.         26,                                      // BRDIV = 26
  61.         0,                                       // UCxBRF = 0
  62.         0,                                       // UCxBRS = 0
  63.         EUSCI_A_UART_NO_PARITY,                  // No Parity
  64.         EUSCI_A_UART_LSB_FIRST,                  // MSB First
  65.         EUSCI_A_UART_ONE_STOP_BIT,               // One stop bit
  66.         EUSCI_A_UART_MODE,                       // UART mode
  67.         EUSCI_A_UART_LOW_FREQUENCY_BAUDRATE_GENERATION,  // Low Frequency Mode
  68.         EUSCI_A_UART_8_BIT_LEN                  // 8 bit data length
  69. };

  70. /*
  71. * Main function
  72. */
  73. int main(void)
  74. {
  75.     /* Halting WDT and disabling master interrupts */
  76.     MAP_WDT_A_holdTimer();
  77.     MAP_Interrupt_disableMaster();

  78.     /* Seed the pseudo random num generator */
  79.     srand(TLV->RANDOM_NUM_1);

  80.     /* Set the core voltage level to VCORE1 */
  81.     MAP_PCM_setCoreVoltageLevel(PCM_VCORE1);

  82.     /* Set 2 flash wait states for Flash bank 0 and 1*/
  83.     MAP_FlashCtl_setWaitState(FLASH_BANK0, 2);
  84.     MAP_FlashCtl_setWaitState(FLASH_BANK1, 2);

  85.     /* Default SysTick period for all 4 color states = 0.5s */
  86.     periods[0] = 1500000;
  87.     periods[1] = 1500000;
  88.     periods[2] = 1500000;
  89.     periods[3] = 1500000;

  90.     /* Initialize main clock to 3MHz */
  91.     MAP_CS_setDCOCenteredFrequency(CS_DCO_FREQUENCY_3);
  92.     MAP_CS_initClockSignal(CS_MCLK, CS_DCOCLK_SELECT, CS_CLOCK_DIVIDER_1 );
  93.     MAP_CS_initClockSignal(CS_HSMCLK, CS_DCOCLK_SELECT, CS_CLOCK_DIVIDER_1 );
  94.     MAP_CS_initClockSignal(CS_SMCLK, CS_DCOCLK_SELECT, CS_CLOCK_DIVIDER_1 );

  95.     /* Selecting P1.2 and P1.3 in UART mode and P1.0 as output (LED) */
  96.     MAP_GPIO_setAsPeripheralModuleFunctionInputPin(GPIO_PORT_P1,
  97.         GPIO_PIN2 | GPIO_PIN3, GPIO_PRIMARY_MODULE_FUNCTION);

  98.     /* GPIO Setup for Pins 2.0-2.2 */
  99.     MAP_PMAP_configurePorts((const uint8_t *) port_mapping, PMAP_P2MAP, 1,
  100.         PMAP_DISABLE_RECONFIGURATION);

  101.     MAP_GPIO_setAsPeripheralModuleFunctionOutputPin(GPIO_PORT_P2,
  102.         GPIO_PIN0 | GPIO_PIN1 | GPIO_PIN2, GPIO_PRIMARY_MODULE_FUNCTION);

  103.     /* Confinguring P1.1 & P1.4 as an input and enabling interrupts */
  104.     MAP_GPIO_setAsInputPinWithPullUpResistor(GPIO_PORT_P1, GPIO_PIN1 | GPIO_PIN4);
  105.     MAP_GPIO_clearInterruptFlag(GPIO_PORT_P1, GPIO_PIN1 | GPIO_PIN4);
  106.     MAP_GPIO_enableInterrupt(GPIO_PORT_P1, GPIO_PIN1 | GPIO_PIN4);
  107.     MAP_GPIO_interruptEdgeSelect(GPIO_PORT_P1, GPIO_PIN1 | GPIO_PIN4, GPIO_HIGH_TO_LOW_TRANSITION);

  108.     /* Configuring UART Module */
  109.     MAP_UART_initModule(EUSCI_A0_BASE, &uartConfig);

  110.     /* Enable UART module */
  111.     MAP_UART_enableModule(EUSCI_A0_BASE);

  112.     /* Configure TimerA0 without Driverlib (CMSIS style register access) */
  113.     TIMER_A0->CCR[0] = PWM_PERIOD;
  114.     TIMER_A0->CCTL[1] = TIMER_A_CCTLN_OUTMOD_7;                      // CCR1 reset/set
  115.     TIMER_A0->CCR[1] = PWM_PERIOD * (RED/255);         // CCR1 PWM duty cycle
  116.     TIMER_A0->CCTL[2] = TIMER_A_CCTLN_OUTMOD_7;                      // CCR2 reset/set
  117.     TIMER_A0->CCR[2] = PWM_PERIOD * (0/255);           // CCR2 PWM duty cycle
  118.     TIMER_A0->CCTL[3] = TIMER_A_CCTLN_OUTMOD_7;                      // CCR3 reset/set
  119.     TIMER_A0->CCR[3] = PWM_PERIOD * (0/255);           // CCR3 PWM duty cycle
  120.     TIMER_A0->CTL = TIMER_A_CTL_SSEL__SMCLK | TIMER_A_CTL_MC__UP | TIMER_A_CTL_CLR;  // SMCLK, up mode, clear TAR

  121.     /* Configuring TimerA1 and TimerA2 for Up Mode  using Driverlib*/
  122.     MAP_Timer_A_configureUpMode(TIMER_A1_BASE, &upConfig);
  123.     MAP_Timer_A_configureUpMode(TIMER_A2_BASE, &TA2upConfig);

  124.     MAP_GPIO_setOutputLowOnPin(GPIO_PORT_P1, GPIO_PIN0);
  125.     MAP_GPIO_setAsOutputPin(GPIO_PORT_P1, GPIO_PIN0);

  126.     /* Configure and enable SysTick */
  127.     MAP_SysTick_setPeriod(1500000);
  128.     MAP_SysTick_enableModule();
  129.     MAP_SysTick_enableInterrupt();

  130.     /* Main while loop */
  131.     while(1)
  132.     {
  133.         MAP_GPIO_clearInterruptFlag(GPIO_PORT_P1, GPIO_PIN1 | GPIO_PIN4);
  134.         MAP_UART_enableInterrupt(EUSCI_A0_BASE, EUSCI_A_UART_RECEIVE_INTERRUPT);
  135.         MAP_Interrupt_enableInterrupt(INT_EUSCIA0);
  136.         MAP_Interrupt_enableInterrupt(INT_PORT1);
  137.         MAP_Interrupt_enableInterrupt(INT_TA1_0);
  138.         MAP_Interrupt_enableInterrupt(INT_TA2_0);
  139.         MAP_Interrupt_enableMaster();
  140.         MAP_PCM_gotoLPM0();
  141.     }
  142. }

  143. /*
  144. * Port 1 interrupt handler. This handler is called whenever switches attached
  145. * to P1.1 (S1) and P1.4 (S2) are pressed.
  146. */
  147. void PORT1_IRQHandler(void)
  148. {
  149.     newTick = MAP_SysTick_getValue();
  150.     uint32_t status = MAP_GPIO_getEnabledInterruptStatus(GPIO_PORT_P1);
  151.     MAP_GPIO_clearInterruptFlag(GPIO_PORT_P1, status);

  152.     /* Handles S1 button press */
  153.     if (status & GPIO_PIN1)
  154.     {
  155.         if (S1buttonDebounce == 0)
  156.         {
  157.             S1buttonDebounce = 1;

  158.             MAP_Interrupt_disableInterrupt(INT_PORT1);

  159.             MAP_GPIO_setOutputHighOnPin(GPIO_PORT_P1, GPIO_PIN0);

  160.             MAP_Timer_A_stopTimer(TIMER_A2_BASE);
  161.             MAP_Timer_A_configureUpMode(TIMER_A2_BASE, &TA2upConfig);
  162.             MAP_Timer_A_startCounter(TIMER_A2_BASE, TIMER_A_UP_MODE);

  163.             count = 0;
  164.             taps++;

  165.             if (counting == 0)
  166.             {
  167.                 oldTick = newTick;
  168.                 counting = 1;
  169.             }
  170.             else
  171.             {
  172.                 if (sysTickCount == 0)
  173.                 {
  174.                     interval = oldTick - newTick;
  175.                     periods[currentColor] = interval/2;
  176.                     oldTick = newTick;
  177.                 }
  178.                 else
  179.                 {
  180.                     interval = (MAP_SysTick_getPeriod() - newTick) + ((sysTickCount-1) * MAP_SysTick_getPeriod()) + oldTick;
  181.                     oldTick = newTick;
  182.                     sysTickCount = 0;
  183.                 }
  184.                 periods[currentColor] = ((periods[currentColor] * (taps-2)) + interval/2) / (taps-1);
  185.                 MAP_SysTick_setPeriod(periods[currentColor]);
  186.             }

  187.             /* Start button debounce timer */
  188.             MAP_Timer_A_startCounter(TIMER_A1_BASE, TIMER_A_UP_MODE);
  189.         }
  190.     }
  191.     /* Handles S2 button press */
  192.     if (status & GPIO_PIN4)
  193.     {
  194.         if (S2buttonDebounce == 0)
  195.         {
  196.             S2buttonDebounce = 1;

  197.             MAP_Interrupt_disableInterrupt(INT_PORT1);

  198.             /* Cycle through R, G, B, random color */
  199.             if (currentColor < 3)
  200.                 currentColor++;
  201.             else
  202.                 currentColor = 0;

  203.             switch(currentColor)
  204.             {
  205.                 case 0:  // Red
  206.                     TIMER_A0->CCR[1] = PWM_PERIOD * (RED/255);              // CCR1 PWM duty cycle
  207.                     TIMER_A0->CCR[2] = PWM_PERIOD * (0/255);                // CCR2 PWM duty cycle
  208.                     TIMER_A0->CCR[3] = PWM_PERIOD * (0/255);                // CCR3 PWM duty cycle
  209.                     break;
  210.                 case 1:  // Green
  211.                     TIMER_A0->CCR[1] = PWM_PERIOD * (0/255);                // CCR1 PWM duty cycle
  212.                     TIMER_A0->CCR[2] = PWM_PERIOD * (GREEN/255);            // CCR2 PWM duty cycle
  213.                     TIMER_A0->CCR[3] = PWM_PERIOD * (0/255);                // CCR3 PWM duty cycle
  214.                     break;
  215.                 case 2:  // Blue
  216.                     TIMER_A0->CCR[1] = PWM_PERIOD * (0/255);                // CCR1 PWM duty cycle
  217.                     TIMER_A0->CCR[2] = PWM_PERIOD * (0/255);                // CCR2 PWM duty cycle
  218.                     TIMER_A0->CCR[3] = PWM_PERIOD * (BLUE/255);             // CCR3 PWM duty cycle
  219.                     break;
  220.                 case 3:  // Random Color
  221.                     TIMER_A0->CCR[1] = (int)((rand() % 255) / 255.0f * PWM_PERIOD);      // CCR1 PWM duty cycle
  222.                     TIMER_A0->CCR[2] = (int)((rand() % 255) / 255.0f * PWM_PERIOD);      // CCR2 PWM duty cycle
  223.                     TIMER_A0->CCR[3] = (int)((rand() % 255) / 255.0f * PWM_PERIOD);      // CCR3 PWM duty cycle
  224.                     break;
  225.                 default:
  226.                     break;
  227.             }

  228.             /* Set current color's LED blink period */
  229.             MAP_SysTick_setPeriod(periods[currentColor]);

  230.             /* Start button debounce timer */
  231.             MAP_Timer_A_startCounter(TIMER_A1_BASE, TIMER_A_UP_MODE);
  232.         }
  233.     }
  234. }

  235. /*
  236. * Timer A1 interrupt handler. This handler determines whether to reset button
  237. * debounce after debounce timer expires.
  238. */
  239. void TA1_0_IRQHandler(void)
  240. {
  241.     MAP_GPIO_setOutputLowOnPin(GPIO_PORT_P1, GPIO_PIN0);
  242.     if (P1IN & GPIO_PIN1)
  243.     {
  244.         S1buttonDebounce = 0;
  245.     }
  246.     if (P1IN & GPIO_PIN4)
  247.     {
  248.         S2buttonDebounce = 0;
  249.     }

  250.     if ((P1IN & GPIO_PIN1) && (P1IN & GPIO_PIN4))
  251.     {
  252.         MAP_Timer_A_stopTimer(TIMER_A1_BASE);
  253.     }
  254.     MAP_Timer_A_clearCaptureCompareInterrupt(TIMER_A1_BASE,
  255.                 TIMER_A_CAPTURECOMPARE_REGISTER_0);
  256. }

  257. /*
  258. * Timer A2 interrupt handler. This handler resets tapping state variables if button S1 is
  259. * not pressed for more than 4 seconds.
  260. */
  261. void TA2_0_IRQHandler(void)
  262. {
  263.     if (counting == 1)
  264.     {
  265.         if (count < 4)
  266.             count++;
  267.         else
  268.         {
  269.             counting = 0;
  270.             count = 0;
  271.             sysTickCount = 0;
  272.             taps = 0;
  273.             MAP_Timer_A_stopTimer(TIMER_A2_BASE);
  274.         }
  275.     }
  276.     MAP_Timer_A_clearCaptureCompareInterrupt(TIMER_A2_BASE,
  277.                 TIMER_A_CAPTURECOMPARE_REGISTER_0);
  278. }

  279. /*
  280. * SysTick interrupt handler. This handler toggles RGB LED on/off.
  281. */
  282. void SysTick_Handler(void)
  283. {
  284.     if (counting == 1)
  285.         sysTickCount++;

  286.     /* Toggle RGB LED OFF */
  287.     if (TIMER_A0->CCTL[1] & TIMER_A_CCTLN_OUTMOD_7){
  288.         TIMER_A0->CCTL[1] = TIMER_A_CCTLN_OUTMOD_0;
  289.         TIMER_A0->CCTL[2] = TIMER_A_CCTLN_OUTMOD_0;
  290.         TIMER_A0->CCTL[3] = TIMER_A_CCTLN_OUTMOD_0;
  291.     }
  292.     /* Toggle RGB LED ON */
  293.     else if (!(TIMER_A0->CCTL[1] & TIMER_A_CCTLN_OUTMOD_0)){
  294.         if (currentColor == 3)
  295.         {
  296.             TIMER_A0->CCR[1] = (int)((rand() % 255) / 255.0f * PWM_PERIOD);                 // CCR1 PWM duty cycle
  297.             TIMER_A0->CCR[2] = (int)((rand() % 255) / 255.0f * PWM_PERIOD);                // CCR2 PWM duty cycle
  298.             TIMER_A0->CCR[3] = (int)((rand() % 255) / 255.0f * PWM_PERIOD);                  // CCR3 PWM duty cycle
  299.         }
  300.         TIMER_A0->CCTL[1] = TIMER_A_CCTLN_OUTMOD_7;
  301.         TIMER_A0->CCTL[2] = TIMER_A_CCTLN_OUTMOD_7;
  302.         TIMER_A0->CCTL[3] = TIMER_A_CCTLN_OUTMOD_7;
  303.     }
  304. }

  305. /*
  306. * EUSCI A0 UART interrupt handler. Receives data from GUI and sets LED color/blink frequency
  307. */
  308. void EUSCIA0_IRQHandler(void)
  309. {
  310.     int receiveByte = UCA0RXBUF;

  311.     /* Send acknowledgement to the GUI */
  312.     if (ack == 0) {
  313.         MAP_UART_transmitData(EUSCI_A0_BASE, 'A');
  314.         ack = 1;
  315.     }

  316.     /* Wait for 'START' keyword to be received before changing color */
  317.     if (bytesReceived > 6) {
  318.         start[0] = start[1];
  319.         start[1] = start[2];
  320.         start[2] = start[3];
  321.         start[3] = start[4];
  322.         start[4] = receiveByte;

  323.         if (start[0] == 'S' && start[1] == 'T' && start[2] == 'A' && start[3] == 'R' && start[4] == 'T')
  324.             bytesReceived = -1;
  325.     }

  326.     /* Receive/Set color and frequency of LED */
  327.     else {
  328.         if (bytesReceived == 0)
  329.             TIMER_A0->CCR[1] = (int)(PWM_PERIOD * (receiveByte/255.0f));                  // CCR3 PWM duty cycle
  330.         else if (bytesReceived == 1)
  331.             TIMER_A0->CCR[2] = (int)(PWM_PERIOD * (receiveByte/255.0f));                  // CCR3 PWM duty cycle
  332.         else if (bytesReceived == 2)
  333.             TIMER_A0->CCR[3] = (int)(PWM_PERIOD * (receiveByte/255.0f));                  // CCR3 PWM duty cycle
  334.         else if (bytesReceived == 3)
  335.         {
  336.             receiveFreq = 0;
  337.             receiveFreq |= receiveByte;
  338.         }
  339.         else if (bytesReceived == 4)
  340.             receiveFreq |= (receiveByte << 8);
  341.         else if (bytesReceived == 5)
  342.             receiveFreq |= (receiveByte << 16);
  343.         else if (bytesReceived == 6)
  344.         {
  345.             receiveFreq |= (receiveByte << 24);
  346.             MAP_SysTick_setPeriod(receiveFreq);
  347.             ack = 0;
  348.         }
  349.     }

  350.     if (bytesReceived < 7)
  351.         bytesReceived++;
  352. }


     由此可见,基本上都是采用按键中断的形式来触发改变LED点亮的状态。接下来需要将编译好的二进制文件烧写到开发板中,我这里采用的是JLink调试下载器,使用DAP方式也是可以下载,但速度有点慢,因此不推荐。将JLink调试下载器与开发板的下载接口相连接,打开Keil中的魔法棒,在Debug选项中勾选JLink方式,能够识别到JLink设备说明安装的JLink驱动也没问题了。

     然后在Keil的菜单栏中直接点击load图标,即可完成程序的烧写。

     然后将板卡重新上电,与原来出厂的程序一样,也是通过按键S1来切换灯光变化的频率,通过按键S2来切换灯光的颜色变化。具体的操作演示视频如下:
     https://v.youku.com/v_show/id_XNDYzNjg3NDg5Mg==.html

    https://v.youku.com/v_show/id_XNDYzNTQxNDEyOA==.html


    接下来体验一下使用TI主推的CCS集成开发工具,通过TI的官网很容易获得CCS的下载地址,工具完全免费,选择最新版的下载安装。下载的网址如下截图:

     解压“CCS10.0.0.00010_win64.zip”文件,双击“ccs_setup_10.0.0.00010.exe”,然后进入安装界面:

    一路默认,今日选择组件界面,我们使用的是MSP-EXP432P401R 版本1.0(黑色)LaunchPad 开发套件,因此勾选如下图所示即可

     根据需求,勾选是否需要安装调试JLink驱动,安装过程中建议将杀毒软件关闭,此次将CCS安装在C盘,安装进度信息如下:


      安装完成后重启计算机,打开安装好的CCS软件,初次使用建议先更新Code Composer Studio IDE,然后创建基本的SimpleLink MSP432项目,与其它的软件设置一样,选择器件型号,设置项目名称,获取模板工程示例选择从“TI资源浏览器导入SimpleLink”示例,然后进行调试器的设置,调试应用程序。具体操作可参照《zhcu166f.pdf》文档,附件奉上:
      以上就是基于MSP-EXP432P401R开发板的开发demo体验,总体感觉TI的资源整理的很规范,文档资料相当齐全。TI的SimpleLink MCU SDK兼容性比较好,SimpleLink MCU SDK包括支持CC13xx/CC26xx、CC32xx 和MSP432器件的整体框架,此三个MCU系列均可使用相同的顶层API。

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?注册

×
 楼主| yinwuqing110 发表于 2020-4-18 22:34 | 显示全部楼层

【MSP432评测】迟来的开箱体验

       说也奇怪,今天下班回来发帖,昨晚的发帖文本又可以恢复了,由于白天在公司已经重新提交了帖子,附件没有提示恢复了。今天发帖忘记将接线示意图附上了,今晚补上,如下照片所示:

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有账号?注册

×
full_stack 发表于 2020-4-19 20:21 | 显示全部楼层
yinwuqing110 发表于 2020-4-18 22:34
说也奇怪,今天下班回来发帖,昨晚的发帖文本又可以恢复了,由于白天在公司已经重新提交了帖子,附 ...

你下面这个板子叫什么
zhangmangui 发表于 2020-4-19 21:27 | 显示全部楼层
full_stack 发表于 2020-4-19 20:21
你下面这个板子叫什么

是不是FT232啥的做的仿真器
zhangmangui 发表于 2020-4-19 21:37 | 显示全部楼层
建议下载MSP432WARE
full_stack 发表于 2020-4-19 22:39 | 显示全部楼层
zhangmangui 发表于 2020-4-19 21:27
是不是FT232啥的做的仿真器

一转多 调试下载器
 楼主| yinwuqing110 发表于 2020-4-20 09:14 | 显示全部楼层
full_stack 发表于 2020-4-19 20:21
你下面这个板子叫什么

这个就是传说中的JLink烧录器呀,兄弟。
full_stack 发表于 2020-4-20 09:33 | 显示全部楼层
yinwuqing110 发表于 2020-4-20 09:14
这个就是传说中的JLink烧录器呀,兄弟。

自制的吗
 楼主| yinwuqing110 发表于 2020-4-20 09:58 | 显示全部楼层

淘宝上淘的呀
gaoyang9992006 发表于 2020-4-20 20:16 | 显示全部楼层
MSP432WARE里面例子多
zhangmangui 发表于 2020-4-21 21:38 | 显示全部楼层

羔羊没申请一块吗
gaoyang9992006 发表于 2020-4-21 22:54 | 显示全部楼层
zhangmangui 发表于 2020-4-21 21:38
羔羊没申请一块吗

几年前我就用过这个版本的了,TI库存卖不掉的,总是拿出来搞活动。
zhangmangui 发表于 2020-4-23 22:14 | 显示全部楼层
gaoyang9992006 发表于 2020-4-21 22:54
几年前我就用过这个版本的了,TI库存卖不掉的,总是拿出来搞活动。

好吧   这处理器主要突出射频是吧
gaoyang9992006 发表于 2020-4-24 09:01 | 显示全部楼层
zhangmangui 发表于 2020-4-23 22:14
好吧   这处理器主要突出射频是吧

432跟射频没有一毛钱关系啊
zhangmangui 发表于 2020-4-25 19:20 | 显示全部楼层
gaoyang9992006 发表于 2020-4-24 09:01
432跟射频没有一毛钱关系啊

被误导了

SimpleLink MSP432P401x 微控制器 (MCU) 是具有集成 16 位精密 ADC 的优化型无线主机 MCU,可借助 FPU 和 DSP 扩展提供超低功耗性能,其中包括 80µA/MHz 的工作功率和 660nA 的待机功耗。作为优化的无线主机 MCU,MSP432P401x 可让开发人员向 基于 SimpleLink 无线连接解决方案的应用中添加高精度模拟和存储器扩展。

MSP432P401x 器件是 SimpleLink 微控制器 (MCU) 平台的一部分,其中包括 Wi-Fi®、低功耗 低功耗 Bluetooth®、低于 1GHz 器件和主机 MCU。
您需要登录后才可以回帖 登录 | 注册

本版积分规则

107

主题

1102

帖子

7

粉丝
快速回复 在线客服 返回列表 返回顶部