Blockset described on this wiki is deprecated since 2012.
For Model Based Design (MBD), use the free MPLAB Device Blocks for Simulink, tool from Microchip.
Updated Rapid Control Prototyping (RCP) custom projects are published at: https://lubin.kerhuel.eu.
Difference between revisions of "DsPIC Block/Master"
LubinKerhuel (talk | contribs) |
LubinKerhuel (talk | contribs) |
||
Line 3: | Line 3: | ||
=Dialog Box Parameters= | =Dialog Box Parameters= | ||
− | + | [[Image:Block_Master_DialogBox.png|thumb|center|Master Block Dialog]] | |
Illustration not up to date ! | Illustration not up to date ! | ||
Revision as of 20:10, 12 June 2008
The Master block set important dsPIC options like PLL, Quartz used, and share theses parameters with others blocks from the blockset.
Contents
Dialog Box Parameters
Illustration not up to date !
Step Based on
- Tmer1 : The model time step is set using the Timer1 automatically configured (Prescaler and PR1).
- ADC : The ADC conversion time can be used only when the ADC block is set to produce two or more sample per channel. The conversion time is 'augmented' so as to have reach the model time step at the end of all conversion needed in 1 time step.
- Free Run : The model execute at its maximum speed. The Time step is not constant since the calculation time may changed slightly between time step. The simulink model time step is not taken into acount.
PIC
Specify the Microchip microcontroller target.
59 Supported devices :
See Release Notes and known bug for details
|
Instruction Cycle Frequency
Specify the Instruction Per Secondes (MIPS) executed not gven in million here. Configuratoin of UART baud, timers prescaler and the time step rely on this frequency information. When using a quartz, the instruction frequency is calculated using : IPS = (FreqQuartz / 4) * PLL factor (1 if no PLL used).
Config Timer
Set the prescaler for the timer 2,3 and 4,5 when available in the microcontrôller. Theses times are used by certain periphery like Output Compare, Input Capture. Set -1 for the timer prescaler to be set by matlab using optimal criterion.
Busy Flag Port
Set the port specified to 1 during the time step calculation and 0 during idle time. This allow to check that all calculation are finished in less that one time step.
Busy Flag Port
Set the port specified to 1 during one time step if the previous time step was not finished when starting the execution of current time step.
config Oscillator mode
Sepecify PIC Oscillator configuration.
config Born Out Reset
Specify Voltage under which the microcontrôller Reset.
config Power Time
Specify time for the pic to start onced powered. (Lets time for alimentation tension to settle properly before starting instructions execution).
config MCLR
If disable, MCLR pin has not the hardware reset function on programme execution. When enable, Pic stop execution and reset when MCLR pin is in its low state.