【Silicon Labs Development Kit Review】+DEMO Program Download
[Copy link]
This post was last edited by cjjh2014 on 2021-7-27 07:20
Yesterday, after installing the simplicity studio 5 software of Silicon Labs , an error occurred when entering the official website to download the routine. Today, I will share the basic usage of the solution. Because the routine could not be downloaded after the initial installation, and the software prompted that the registration was abnormal. So I directly deleted the original software and then downloaded the software again. Before installing, all the information previously installed needs to be deleted to avoid future troubles. There is a hidden SS5 file in the document location of the C drive, which also needs to be found and deleted. Then reinstall the software. The installation process is the same as the steps in the previous report, with no difference.
After installation, you need to test whether SS5 is installed successfully without any problems. The simplest test is to download a regular program from the official website, compile it and download it to the DEMO . As long as the DEMO displays the correct functions, it can basically be determined that the software and hardware functions are normal. A relatively simple routine in the official website routine is to achieve the breathing light effect by controlling the MCU to generate PWM waves.
First open the software, the display is as follows.
After opening the software , connect the DEMO to the computer via USB . The model information of the DEMO will be automatically recognized and displayed in the W elcom to simplicity studio selection page in the software , and then select Start.
Then select CREATE to create a project, as shown below, and place the sample program where you need it.
In the software composition menu, you can find the routine program.
The next step is to compile the routine, as shown by the arrow in the figure below.
After successfully compiling the DEMO program, the following information will be displayed: Mainly look at the error and warning information of the result.
Finally, download it to DEMO to see if the display effect of the LED light is what we need.
The following shows the actual effect:
Here is the program content:
#include "sl_component_catalog.h"
#include "sl_system_init.h"
#include "app.h"
#if defined(SL_CATALOG_POWER_MANAGER_PRESENT)
#include "sl_power_manager.h"
#endif
#if defined(SL_CATALOG_KERNEL_PRESENT)
#include "sl_system_kernel.h"
#else // SL_CATALOG_KERNEL_PRESENT
#include "sl_system_process_action.h"
#endif // SL_CATALOG_KERNEL_PRESENT
int main(void)
{
// Initialize Silicon Labs device, system, service(s) and protocol stack(s).
// Note that if the kernel is present, processing task(s) will be created by
// this call.
sl_system_init();
// Initialize the application. For example, create periodic timer(s) or
// task(s) if the kernel is present.
app_init();
#if defined(SL_CATALOG_KERNEL_PRESENT)
// Start the kernel. Task(s) created in app_init() will start running.
sl_system_kernel_start();
#else // SL_CATALOG_KERNEL_PRESENT
while (1) {
// Do not remove this call: Silicon Labs components process action routine
// must be called from the super loop.
sl_system_process_action();
// Application process.
app_process_action();
#if defined(SL_CATALOG_POWER_MANAGER_PRESENT)
// Let the CPU go to sleep if the system allows it.
sl_power_manager_sleep();
#endif
}
#endif // SL_CATALOG_KERNEL_PRESENT
}
|