You start by reading the datasheet, writing small test programs, then you pull it all together. That is how we did it. It is the only way, and there are not many shortcuts.I am starter to Microcontrollers . In general Most of people Start with Microcontrollers AT89C51, But i choose to learn Sillabs. I want learn interrupts ,timers, adc,dac and other peripherals like spi i2c perfectly.
Yes, the datasheet is your friend here. Take a look at page 309 in the datasheet https://www.silabs.com/Support Documents/TechnicalDocs/C8051F12x-13x.pdf
What you want is autoreload. (You can reload the timers manually for every overflow too). Look at the first table, Timer2,3,4 can be set to 16 counter/timers with auto-reload. Then you need to figure out how fast your timer is ticking. After you have figured out what your sysclk is, what clk source and/or clkprescaler you know the tick time. There are Frequency equations too in the datasheet. From the Auto-Reload section: "When counting up, the counter/timer will set its overflow/underflow flag (TFn) and cause an interrupt (if enabled) upon overflow/underflow, and the values in the Reload/Capture Registers (RCAPnH and RCAPnL) are loaded into the timer and the timer is restarted.". If you search the document for "reload", you'll find tables with reload values for different baud-rates for UARTs. I've never looked at this chip and never into silicon labs datasheets before and I must say I like it.
|Thread starter||Similar threads||Forum||Replies||Date|
|C||Does anyone recognise these crimped sockets?||Datasheets, Manuals & Parts Identification||4|
|D||What does "inductive loads must be diode suppressed" mean and what diode should I try?||General Electronics Chat||5|
|Diesel generator does not want to play ball at high loads - resistance is futile||Power Electronics||5|
|Does this circuit work if so explain how ...starting on when there pwm signal is high and when low||Homework Help||3|
|M||How much power does an op amp dissipate?||General Electronics Chat||22|
|Does anyone recognise these crimped sockets?|
|What does "inductive loads must be diode suppressed" mean and what diode should I try?|
|Diesel generator does not want to play ball at high loads - resistance is futile|
|Does this circuit work if so explain how ...starting on when there pwm signal is high and when low|
|How much power does an op amp dissipate?|
by Robert Keim