This topic describes how to connect a microcontroller (MCU) to a demo board that includes a communication module. It also describes how to build a development environment, create a project, import a device SDK, and configure the project.

Background information

The following figure shows the demo boards.


    The following figure shows pins for the demo board.

  • SIM800C mini v2.0SIM800C

    The following figure shows pins for the demo board.

    Pin Description
    PWR Power switch. Automatic power-on is enabled by default.
    STA Status.
    GND Ground.
    RXD Receive data.
    TXD Transmit data.
    EN Enable.
    VIN 5 V to 18 V input.

Connect demo boards

Connect the RXD pin of each demo board to the TXD pin of each demo board. This allows you to establish a connection and run AT commands. The following figure shows how to connect the demo boards.


Build a development environment

This topic uses the STM32CubeMX tool as an example. For more information, see STM32Cube Ecosystem.

  1. Open the STM32CubeMX tool and click New Project.
    New Project
  2. On the Board Seletor tab, search for NUCLEO-F103RB and click STM32F103RBTx.
    Board Seletor
  3. In the upper-right corner, click Start Project.
  4. In the left-side navigation pane, click Connectivity, and select USART1 as the port for communication between an MCU and a communication module. Proceed as follows.
    • Set Mode to Asynchronous.
    • In the Configuration section, set the following parameters.
      • On the GPIO Settings tab, select PA9 and PA10 in the Pin field.
      • On the NVIC Settings tab, set USART1 global interrupt to Enabled.
  5. In the left-side navigation pane, click Middleware, select FREERTOS, set USE_COUNTING_SEMAPHORES to Enabled, and set TOTAL_HEAP_SIZE. Each thread can share the heap.
  6. On the Project Manager tab, complete the settings in the Project section.
    Project Manager
  7. In the upper-right corner of the page, click GENERATE CODE to generate code for the project.