6. S3C2440 is an improved version of S3C2410. Their operations are basically similar, except for some minor differences in the settings of the system clock and the operation of the NAND Flash controller. . What I have to do next is to make a U-Boot binary code run on both S3C2410 and S3C2440.
Although my board is also S3C2410, adding U-Boot exercises for S3C2440 can improve our abilities and lay the foundation for subsequent learning.
The value of the GSTATUS1 register: 0x32410000 represents S3C2410, 0x32410002 represents S3C2440.
S3C2410:FCLK=200MHZ;S3C2440:FCLK=400MHZ,UCLK=48MHZ;
After figuring it out, we can get started.
First, define the following values in front of board/100ask24x0/100ask24x0.c:
The input clock of my development board is 12MHZ. If your development board clock is different from mine, you can calculate it according to the formula in the previous code, and then modify the system clock. This is in the macro CONFIG_SYS_CLK_FREQ in include/configs/100ask24x0.h definition.
Next, use different macros to set the system clock, including S3C2410 and S3C2440.
7. When setting the serial port baud rate later, you need to obtain the system clock. This is in the second stage of U-Boot, that is, when the start_armboot function in lib_arm/board.c calls the serial_init function to initialize the serial port, it will call get_PCLK, get_HCLK, and get_PLLCLK. etc. function, which requires us to make corresponding modifications.
First, you must add the following line to the switch of the board_init function to use the variable gd, because S3C2410 and S3C2440 are recognized and the machine type ID is set: gd->bd->bi_arch_number.
Then add the following in the get_PLLCLK function:
Since the frequency division coefficient setting methods are also different, get_HCLK and get_PCLK also need to be modified. Modify as follows:
。。。。。。。。。。。
The above 3:6 should be changed to 6:3. I made a mistake here.
。。。。。。。。
3:6 changed to 6:3
8. The modification has been completed and can be compiled.
(1)make 100ask24x0_config
(2)make all
There were a lot of errors later, and I needed to be patient to search and correct them.
Previous article:U-Boot transplantation (4) adds support for S3C2440 (modifies compilation errors)
Next article:U-Boot transplantation (2) Modify SDRAM configuration
Recommended ReadingLatest update time:2024-11-22 13:45
- Naxin Micro and Xinxian jointly launched the NS800RT series of real-time control MCUs
- How to learn embedded systems based on ARM platform
- Summary of jffs2_scan_eraseblock issues
- Application of SPCOMM Control in Serial Communication of Delphi7.0
- Using TComm component to realize serial communication in Delphi environment
- Bar chart code for embedded development practices
- Embedded Development Learning (10)
- Embedded Development Learning (8)
- Embedded Development Learning (6)
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- Intel promotes AI with multi-dimensional efforts in technology, application, and ecology
- ChinaJoy Qualcomm Snapdragon Theme Pavilion takes you to experience the new changes in digital entertainment in the 5G era
- Infineon's latest generation IGBT technology platform enables precise control of speed and position
- Two test methods for LED lighting life
- Don't Let Lightning Induced Surges Scare You
- Application of brushless motor controller ML4425/4426
- Easy identification of LED power supply quality
- World's first integrated photovoltaic solar system completed in Israel
- Sliding window mean filter for avr microcontroller AD conversion
- What does call mean in the detailed explanation of ABB robot programming instructions?
- RAQ #223: How to measure and determine soft-start timing without a soft-start equation?
- RAQ #223: How to measure and determine soft-start timing without a soft-start equation?
- GigaDevice's full range of automotive-grade SPI NOR Flash GD25/55 wins ISO 26262 ASIL D functional safety certification
- GigaDevice's full range of automotive-grade SPI NOR Flash GD25/55 wins ISO 26262 ASIL D functional safety certification
- New IsoVu™ Isolated Current Probes: Bringing a New Dimension to Current Measurements
- New IsoVu™ Isolated Current Probes: Bringing a New Dimension to Current Measurements
- Infineon Technologies Launches ModusToolbox™ Motor Kit to Simplify Motor Control Development
- Infineon Technologies Launches ModusToolbox™ Motor Kit to Simplify Motor Control Development
- STMicroelectronics IO-Link Actuator Board Brings Turnkey Reference Design to Industrial Monitoring and Equipment Manufacturers
- Melexis uses coreless technology to reduce the size of current sensing devices
- 【GD32L233C-START Review】10. ADC reads the internal temperature of the chip
- A Simple Introduction to LPC9401 Flash MCU
- Operating Systems: The Essence and Design Principles (8th Edition)
- python zen song
- What is the relationship between the switching current and the maximum output current of a switching power supply?
- This is the best neural network I have ever seen.
- Wireless temperature transmitter based on ZigBee
- PCB design considerations
- [NXP Rapid IoT Review] Finally received it, routine unboxing
- [Live broadcast tomorrow] Keysight metrology experts will give a lecture: Electronic instrument metrology calibration knowledge and calibration cycle