During this time, I finally finished the wireless receiving module for short-distance communication. It could have been completed in a week or two, but due to trying to use the eclipse development environment in the first two weeks, I encountered many problems, especially the implementation of the 6410 interrupt. This resulted in the late work being rushed, and it took several all-nighters to get it done, which made me exhausted.
Looking back, this project is worth summarizing and learning lessons from in many aspects. Avoid similar situations from happening again in future projects. The follow-up article will introduce the bare metal program development environment and methods of Samsung 6410.
development environment
For the bare metal program development environment of Samsung 6410, it is natural to use eclipse. If it is done as research and exploration, this is not a bad idea and is actually feasible. But the problem is that this is a development project and there is a time limit. Therefore, you should choose the most correct development environment-RVDS.
One of the biggest problems encountered in eclipse is the implementation of the keyword __irq that modifies the interrupt handling function.
* In C language, the function of the keyword "__irq": When ISR is defined with this keyword, the CPU automatically restores
the LR in the * mode before the interrupt from the stack after the ISR ends, and assigns it to the PC to complete the ISR Return normally. If there is no such keyword, the CPU can only return to
the interrupt state before the secondary ISR , and it is still in the IRQ working mode. Of course, the user program can continue to be executed, but the working mode is incorrect. In this mode,
other IRQ interrupts cannot be responded to *.
__irq is not defined in eclipse, so it must be implemented by referring to the definition in ADS1.2 or RVDS (output assembly instructions). This has encountered a lot of trouble. So far, __irq is still not fully implemented in eclipse.
collect message
Before starting the project, I did not have a deep understanding of the bare metal program development of 6410. Bare metal program routines are provided for Friendly Arms on which to build. Relying too much on Friendly Arms routines resulted in not understanding other companies' bare metal routines.
In fact, the best 6410 bare metal program routine is the 6410_Test project provided by Samsung. This project provides the function implementation and API interface of all modules. Developing on this basis can greatly reduce the workload. Unfortunately, I discovered the 6410_Test project when I was debugging the 6410 SPI driver.
Personally, I think the 6410 bare metal program routines provided by Friendly Arm are not very good, and some routines are problematic, such as the UART routine. The interrupt routine provided is still based on the 51 jump method, not the VIC mode.
In addition, the information on the CD of the Friendly Arm development board, such as schematic diagrams, is very confusing. Putting the various versions together, it is impossible to know which version of the schematic diagram should be used for the development board you purchased.
wireless module
Before this, I had never been exposed to short-range wireless communication modules. The customer required the use of 433MHz short-range wireless communication module CC1101 and assigned us a Taobao seller. After reading the description of the wireless module, the communication distance can reach the customer's requirement of at least 200 meters. So I bought a pair of modules without any research.
During the actual test, it could only transmit more than 20 meters. I asked the Taobao seller again, and he said that their actual measured distance was more than 50 meters. The transmission rate was reduced to a minimum of 1200bps and could reach more than 100 meters in an open area. If you want to reach 200 meters, CC1101 must add PA.
I feel like I was deceived, but we can only blame ourselves for not being careful, not cross-examining or investigating carefully.
Later, I gave up CC1101 and changed to nRF2401, and purchased the nRF2401 wireless communication module with PA+LNA to ensure the communication distance and meet customer requirements. As for how far CC1101 can transmit without adding PA, I won’t go into details.
One of Fan's mistakes here is that the customer specified the wireless communication module for us, but he did not understand it in depth, thinking that the communication distance specified by the customer should be able to meet the requirements.
basic tools
This development involves driver debugging. However, we didn't even prepare basic tools like soldering iron and multimeter. Therefore, when debugging the driver, the efficiency is very low. As the saying goes, if a worker wants to do his job well, he must first sharpen his tools.
Part time confusion
A big obstacle to part-time development projects is that it is inconvenient for project developers to communicate and communicate in a timely manner, and it is also inconvenient to cooperate with debugging. This problem cannot be changed for the time being. We can only continue to strengthen cooperation with each other and explore the best way to cooperate.
improvement measures
The general problems discussed above are ultimately as follows: development projects are carried out independently without planning, planning and coordination. Specific to myself, my mentality in the early stage of the project was not correct and I was too optimistic! Improvement measures are as follows:
Before taking on a project, analyze customer needs and investigate the feasibility of the project.
Develop project plans, select project managers, and conduct overall planning.
When doing a project, you must start from the goal of ensuring the completion of the project, select the correct tools, development environment, hardware platform, etc., and never start the project with a learning mentality.
Previous article:Samsung 6410 bare metal program development 2: establishing eclipse bare metal program project
Next article:Samsung 6410 bare metal program development 5: Use Samsung’s official 6410_Test project to develop bare metal programs
- Popular Resources
- Popular amplifiers
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- LED chemical incompatibility test to see which chemicals LEDs can be used with
- Application of ARM9 hardware coprocessor on WinCE embedded motherboard
- What are the key points for selecting rotor flowmeter?
- LM317 high power charger circuit
- A brief analysis of Embest's application and development of embedded medical devices
- Single-phase RC protection circuit
- stm32 PVD programmable voltage monitor
- Introduction and measurement of edge trigger and level trigger of 51 single chip microcomputer
- Improved design of Linux system software shell protection technology
- What to do if the ABB robot protection device stops
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- What are the techniques for designing transistor amplifier circuits?
- Zero compensation problem of Wheatstone bridge
- Can anyone provide a clear diagram of the whip antenna schematic in the attached picture? Thank you
- 【AT-START-F425 Review】SPI driven LCD screen
- TI CC1310 series chip question and answer sharing
- What is the difference between NFC and RFID?
- Some technical documents share candence and power semiconductors
- What is a smart home? What are the smart home design principles?
- The way out for electronic companies during the epidemic
- 【Project source code】Two-person buzzer based on FPGA