I am an engineering student majoring in optics, and I have not been exposed to circuit development except for analog and digital electronics, a little electronic technology experiment and C language, which I learned in undergraduate classes. Therefore, I am completely a novice in SCM, and I can be a mouse for my friends who are interested in SCM development but don't know how to start.
~The above is the background~
Unpacking:
First of all, open the box. The packaging of the board is very simple. It is a drawer style carton, but it looks very textured and thick. The outer package of the product is shown in Figure 1:
Figure 1 Product Outer Packaging
After the box is pulled out, it is the development board (as shown in Figure 2 and Figure 3) And an interface layout diagram (Figure 4) 。
Figure 2 FRDM-K64F Development Board
Figure 3 Back of Development Board
The illustration briefly introduces the names and functions of each interface and button, as shown in Figure 4.
Figure 4 Function Layout of Development Board
As you can see, FRDM-K64F The development board is a development platform for Freescale ARM Cortex-M series microcontrollers. The on-board resources are very rich. It is based on the Kinetics series MCU, equipped with OpenSDAv2 debugging interface, compatible with Arduino R3 expansion interface, equipped with Freescale sensors (6-axis digital accelerometer and magnetometer with electronic compass function), three color LED lights for interactive feedback, two user buttons The microSD card slot, network cable port, connectors for Bluetooth and 2.4 GHz radio add ins, and other features are a miniaturized, low-power, cost-effective microcontroller evaluation and development platform.
After unpacking, it is a test. For novices, as long as you search FRDM-K64F on Baidu, some developer forums will appear, or you can search on the freescale official website. It should be said that the information is still very rich. You can search a lot of information casually, but most of them are in English. Figure 5 shows some useful information. If you need it, you can contact me.
Figure 5 Common Data of F64K Development Board
I built the development environment according to an experience post in the official community of freescale, and tested the color changing function of LED lights. This part is clearly written in the quick introduction of K64F product introduction on freescale official website and the experience post of Baidu, so it is not difficult to draw a gourd like a gourd. Here's a brief introduction.
Development board detection:
How can I detect whether the development board is damaged when I just get it? K64F board is delivered with a small program to respond to external acceleration and magnetic field changes through the accelerometer and magnetometer of the board.
Just connect the micro USB interface at the upper right corner of the board and the computer with a data cable (the general Android mobile phone data cable can be used) to power the board, and then press the SW3 button twice to turn on the accelerometer mode. When the board is turned over, the LED light will change its color and brightness accordingly; Press the SW3 button six more times to turn on the magnetometer. At this time, take a small piece of iron and place it above the board, and you will see that the color of the LED light changes with the distance between the iron and the board. In the process, you can press the reset key to reset the program at any time.
The effect of turning on the light is shown in Figure 6.
Figure 6 Flip light effect
(In the product introduction on the P.S. official website, you can directly connect to the computer and turn over the board to see the light changes with the accelerometer, but I received the old version, which needs to be turned on by pressing the key)
Firmware update:
After the test, the firmware was updated according to the information prompts. The firmware can be downloaded to the official website: k20dx128_k64f_if_mbed.bin, The update procedure is simple: First, disconnect the board from the computer; Then press and hold the reset key to connect the board to the computer, and wait until the computer displays a BOOTLOADER 's hard disk, size 144K Later, release the reset key; Then copy the downloaded firmware file into the hard disk and disconnect it from the computer; Finally, connect the board to the computer, and the hard disk name changes to MBED , update completed.
Construction of development environment:
First, go to the official website to download Kinetics Design Studio (KDS) 3.0 and KSDK1.3. KDS is the official free development tool of Freescale, and can also be developed on the platform of Keil. However, I feel that the official platform will be easier to use, so I chose this one to practice; KSDK1.3 is the official free case base, including the complete source code of hardware abstraction and peripheral driver software.
Install KDS as prompted, and then import KSDK1.3 into KDS Processor Expert (PE) according to the quick start of K64F product introduction on the official website or Baidu's community experience. I haven't quite figured out what PE is for a while. My understanding is that with this module, you can simply configure the I/O port to generate a program framework, making programming more convenient. The interface after software installation is completed is shown in Figure 7. Some simple statements, such as turning on the LED, can be directly downloaded from the loaded KSDK1.3
Figure 7 KDS Operation Interface
Then we can develop happily~
Figure 8 Debugging process of LED flowing light
Figure 9 Main program of flow light
Figure 9 shows the main program of the pipeline lamp. The main framework is provided by PE. Only the parts in the red box are added by themselves. The statements used are also packaged in the KSDK1.3 library, which is very convenient to use.
However, I still encountered a problem when debugging. I checked countless materials, so that I once thought that this board had too few materials for beginners... The problem is that the newly released KDS3.0 has a bug. You must download the two files shown in Figure 10 and replace the two files in the installation directory.
Figure 10 Two files to be replaced
After replacement, you can debug. The whole process is very simple.
Summary:
As a novice, I can eliminate the bugs in the new version of software. I think it is not difficult to start with the K64F board, and the information is also easy to find. Freescale has a relatively complete development environment and an active developer forum, so it is more convenient to find solutions to problems encountered in the development process. Therefore, the difficulty of development board should be the mastery of circuit logic and the skillful use of programming language.
In general, this board is rich in on-board resources and easy to program, but rich resources also means that programming may be more complex. Independent development requires their own experience, so it is easy to understand and difficult to master.
The article on the trial of iGo is completed by netizens, which does not represent the views of this website.