This programme is to control DC motor in a certain speed using PWM.
The target speed is "r", it is the speed in 1s.
The sample rate is 0.1s, so the actual speed target is "rc"=r/10.
The "r" and "rc" are integer, and the range of "r" is from 50 to 100.
Keep rc=r/10!!!
The array "speed1" and "speed2" are the control result, in 0.1s and 1s.
The length of "speed1" is 2400, and "speed2" is 240.
The "pw" and "nw" are the parameters of PWM.
The test will last 4 min.
s3c2410 ads下的測(cè)試程序移植到 iar ewarm v5.2;包括
Please select function :
0 : Please input 1-14 to select test
1 : Real time clock display
2 : 4 key array test
3 : Buzzer test
4 : ADC test
5 : IIC EEPROM test
6 : Touchpanel test
7 : 3.5# TFT LCD 240*320 test
8 : UDA1341 play audio test
9 : UDA1341 record audio test
10 : IRDA test
11 : SD Card write and read test
12 : COM port ( UART2 ) test
The ADC0803 family is a series of three CMOS 8-bit successive
approximation A/D converters using a resistive ladder and
capacitive array together with an auto-zero comparator. These
converters are designed to operate with microprocessor-controlled
buses using a minimum of external circuitry. The 3-State output data
lines can be connected directly to the data bus.
Methods
void close()
int read()
reads and returns a chracter.
int read(char[] characterArray)
populates an array of characters with data.
boolean ready()
- returns “true” if there is data available.
……
Imperfect C++ Practical Solutions for Real-Life Programming
C++, although a marvelous language, isn t perfect. Matthew Wilson has been working with it for over a decade, and during that time he has found inherent limitations that require skillful workarounds. In this book, he doesn t just tell you what s wrong with C++, but offers practical techniques and tools for writing code that s more robust, flexible, efficient, and maintainable. He shows you how to tame C++ s complexity, cut through its vast array of paradigms, take back control over your code--and get far better results.
Description The MUSIC algorithm, proposed by Schmidt, first estimates a basis for the noise subspace and then determines the peaks the associated angles provide the DOA estimates.
The MATLAB code for the MUSIC algorithm is sampled by creating an array of steering vectors corresponding to the angles in the vector angles.
本文檔介紹了如何使用各種內(nèi)嵌工具,函數(shù)和其他一些小技巧來(lái)加強(qiáng)使用matlab的速度和效率,是廣大愛好者必讀的文檔。具體內(nèi)容請(qǐng)參閱文檔。
Learn how to use the Profiler tool, vectorized functions, and other tricks to writing efficient MATLAB code. This article includes how to convert any array into a column vector, bounding a value without if statements, and repeating/tiling a vector without repmat.
Contents:
* The Profiler
* Array Preallocation
* JIT Acceleration
* Vectorization
* Inlining Simple Functions
* Referencing Operations
* Numerical Integration
* Signal Processing
* Miscellaneous Tricks