ARM FAQ

1. Q: Why use embedded Linux?
Answer: Linux's capabilities, stability, flexibility and scalability, combined with the architecture, hardware equipment, graphics support and communication protocols of many microprocessors it supports, has established that Linux has gradually become a popular software platform and is widely used In various products. The use of Linux can be extended to a series of products for computer applications, from IBM's tiny Linux watches to handheld devices (including PDAs and mobile phones) and consumer entertainment systems to information appliances, telephone network equipment, etc. Because Linux is open And the form of free source code exists, and its many differences and structures and supporting software have made Linux develop gradually to meet the changing needs of the market and various applications. There is a small program core version and a version that enhances real-time processing, and although the original Linux was a PC-based operating system, today ’s Linux can already be built on various non-x86 CPUs, and whether or not it has a memory management unit , Which includes PowerPC, ARM, MIPS, 68K and even microcontrollers.

2. Q: How does Linux compare with uClinux? What file systems do they support?
Answer: 1). Because uClinux supports a microprocessor without a storage management unit, the ability to multitask becomes very delicate. The vast majority of applications executed on uClinux do not require multitasking capabilities. In addition, most of the binary execution code and the original code will be rewritten in order to more compact and reduce the program code, which means that the core of uClinux and Linux2.0 will be very very small compared to. 2), NFS , Ext2, ext3, MS-DOS and FAT16 / 32 are several file systems that Linux can support. The biggest difference between him and uClinux is that uClinux has no MMU management unit.

3. Q: What are the specific debugging methods for developing embedded Linux?
Answer: When developing the corresponding embedded LINUX system for a new hardware, the sequence and steps of a typical debugging tool to be used are: 1), modify the code so that it can read and write the serial port, and use gdb to run the program. This will allow it to communicate with another Linux host running the gdb program; gdb communicates with the gdb object code on the test computer through the serial port and gives all C source-level debugging information; 2) execute the rest with gdb, Until the LINUX kernel starts to take over the initialization code of all hardware and software before; 3) Once the LINUX kernel starts, the above serial port becomes the LINUX console port, you can use its convenience to carry out the subsequent development process, and you can use gdb Kernel debug version kgdb.

4. Q: Under what circumstances should I use the evaluation board?
Answer: For JTAG emulation, hardware debugging is required only when a board is available. If you do not have a board on hand and want to perform simulation and debugging before your board is ready, you need to purchase an evaluation board. When making the board, you can also learn from the circuit of the evaluation board.

5. Q: Why does *** Data Abort *** appear when connected to the debugger?
Answer: The reasons are as follows: 1) When the debugger is started, the processor will stop at the location pointed to by the current PC value, and at the same time read the memory value of a part of the address around the PC value. If these addresses happen to be unused or point to empty, Data Abort will appear, which is normal. 2) If you are using memory (RAM or ROM), such a problem indicates that there may be data errors in the memory access, please check your memory. 3) When the user downloads the program to the target board, the downloaded target address is specified in the compiler. If the target address set in the compiler does not correspond to the physical address of the writeable accessor on the target board, it will also report Data Abort, an error occurred because the debugger tried to write the user program to the wrong physical address. At this time, you need to check and reset the compiler options. 4) The clock rate of the JTAG port is too fast.

6. Q: I often stop during the debugging process, sometimes I can't even enter the debugging program?
Answer: After eliminating the problem of the debugger itself, this kind of problem with randomness can be considered to be caused by hardware timing or logic problems. The main possibility is that the nTRST and the system reset signal are unreliable. The unreliability of the Reset signal includes two aspects: the normal operation requires a stable high level; the reset state requires a low level for sufficient time. The reset circuit is usually ignored because of its simplicity, but the facts show that many seemingly strange problems are finally concluded here. Whether from the perspective of debugging or the final requirement for stable operation, we recommend that you use a good reset circuit (or IC ) To replace the simple RC circuit.

7. Q: Can I use only C language instead of assembly for ARM development?
Answer: No. Generally, the startup code and interrupt initialization require assembly.

8. Q: When connecting the target board with an ARM emulator, it prompts that the target board is not found, what should I do?
Answer: Please check according to the following tips: 1), whether the connection between the emulator, computer and target board is correct; 2), whether the target board is powered on; 3), if the above settings are correct and the parallel port of the computer is good, please Check whether the debugging device is correct by checking whether the Debugger device is selected correctly on the General page of the project settings dialog box, and this selection must correspond to the target board.

9. Q: What is the debugging method developed by ARM?
Answer: When users choose ARM processors to develop embedded systems, choosing appropriate development tools can speed up the development process and save development costs. Therefore, the integrated development environment (IDE) is generally indispensable, and other development tools such as embedded real-time operating systems and evaluation boards can be selected according to the application software scale and development plan. Use the integrated development environment to develop ARM-based application software, including editing, compiling, assembling, linking, etc., all of which can be completed on the PC. The debugging work needs to be completed with other modules or products. The current common debugging methods are as follows Several: (1) Part of the integrated development environment provides an instruction set simulator, which can facilitate the simulation and debugging work, but because the instruction set simulator is very different from the real hardware environment, the user must finally complete the development of the entire application on the hardware platform . (2) Resident monitoring software: Resident monitoring software is a program that runs on the target board. The debugging software in the integrated development environment interacts with the resident monitoring software through communication ports such as Ethernet ports, parallel ports, and serial ports. To debug. The resident monitoring software has relatively high requirements on hardware equipment. Generally, the application software can be developed after the hardware is stable. At the same time, it occupies a part of the resources on the target board, and it cannot fully simulate the full-speed operation of the program, so it is strict with some requirements. The situation is not very suitable (3) JTAG emulator: JTAG emulator, also known as JTAG debugger, is a device for debugging through the JTAG boundary scan port of the ARM chip. The JTAG emulator is cheaper and more convenient to connect. It communicates with the ARM CPU core through the existing JTAG boundary scan port. It does not require target memory and does not occupy any port of the target system. These are necessary for resident monitoring software. In addition, because the target program for JTAG debugging is executed on the target board, the simulation is closer to the target hardware, so many interface problems are minimized. Using the integrated development environment and JTAG emulator for development is currently the most widely used debugging method. (4) Online emulator: The online emulator completely replaces the CPU on the target board with the emulation head, which can completely emulate the behavior of the ARM chip, providing more In-depth debugging function. But its high price makes it difficult to popularize.

10. Q: What are the general principles of ARM chip selection?
Answer: 1) ARM chip core: If you want to use WinCE or Linux and other operating systems to reduce software development time, you need to choose an ARM chip with MMU function above ARM720T, but there are a few Linux such as uCLinux that do not require MMU support; 2) System clock controller; 3) Internal memory capacity; 4) USB interface; 5) Number of GPIO; 6) Interrupt controller; 7) IIS interface: namely integrated audio interface; 8) nWAIT signal: external bus speed control signal; 9) RTC; 10) LCD controller: Some ARM chips have built-in LCD controller, and some even have built-in 64K color TFT LCD controller. When designing PDAs and handheld display recording devices, it is more appropriate to use an ARM chip with built-in LCD controller such as S3C2410; 11) PWM output; 12) ADC and DAC: Some ARM chips have built-in 2 to 8 channels of 8 to 12 general-purpose ADCs Can be used for battery detection, touch screen and temperature monitoring, etc .; 13) Expansion bus; 14) UART and IrDA: Almost all ARM chips have 1 to 2 UART interfaces, which can be used for communication with PC or debugging with Angel; 15) DSP coprocessor: ARM chip with ARM + DSP structure; 16) Built-in FPGA: some ARM chips have built-in FPGA, suitable for communication and other fields; 17) counter and watchdog; 18) power management function; 19) DMA Controller. The last thing to note is the packaging issue.

Disposable Mask

Jieyang Huiyi Hardware Products Co., Ltd. , https://www.chinagdhuiyi.com