Recent content by Maniac_XOX
-
M
How to program a buzzer to a PIC18F452 with PROTEUS and MPLAB IDE?
Nevermind haha I have managed to make it through with some work, i had to also switch to a DC operated buzzer Here is the code I have used: #define _XTAL_FREQ 4000000 #define switch3 PORTBbits.RB4 // SWITCH INTERFACED #define buzzer PORTCbits.RC0 // BUZZER INTERFACED void BuzzerFunc(void)...- Maniac_XOX
- Post #3
- Forum: Electrical Engineering
-
M
How to program a buzzer to a PIC18F452 with PROTEUS and MPLAB IDE?
crystal frequency is 4MHz The code i have tried is: #include <p18cxxx.h> #include <xc.h> void main(void) { TRISC = 0; // making TRISC pins output ADCON1 = 0x07; // making them digital pins while(1) { RC0 = 1; __delay_ms(5000); RC0 = 0...- Maniac_XOX
- Thread
- Electronics Electronics engineering Engineering Mechatronics Microcontroller Program
- Replies: 3
- Forum: Electrical Engineering
-
M
Comp Sci Interrupts on pic18f452 not shooting in mplab X, help? C language
I have actually managed to get the seconds right with the right calculations and settings finally! Would you mind taking a look at the merged thread that is on reply #4? I have a couple questions on there regarding my proteus design and things i need to change in it, here it is below: #define...- Maniac_XOX
- Post #9
- Forum: Engineering and Comp Sci Homework Help
-
M
Comp Sci Interrupts on pic18f452 not shooting in mplab X, help? C language
4MHz is the the frequency of the oscillator (Fosc), to find the the frequency of the internal instructions (set in the timer0 control register, TMR0CON) you divide Fosc by 4. So the time for one instuction takes 1/frequency = 1/(4/4) So far i have used TMR0L = any integer to preload the timer...- Maniac_XOX
- Post #6
- Forum: Engineering and Comp Sci Homework Help
-
M
Comp Sci Interrupts on pic18f452 not shooting in mplab X, help? C language
PLease help, I am fairly new to proteus and mplabx so I am trying to udnerstand how it all works. I am using PIC18F452 microcontroller. I have this circuit in proteus shown at the bottom of the text. The code: #define _XTAL_FREQ 4000000 //Set the config bits #pragma config WDT = OFF, BOR =...- Maniac_XOX
- Post #4
- Forum: Engineering and Comp Sci Homework Help
-
M
Comp Sci Interrupts on pic18f452 not shooting in mplab X, help? C language
lol sorry that was a typo in the code i actually write it as 4000000 so it would be 4MHz, but the problem persists- Maniac_XOX
- Post #3
- Forum: Engineering and Comp Sci Homework Help
-
M
Comp Sci Interrupts on pic18f452 not shooting in mplab X, help? C language
I am using MPLAB X, everything is working great when I work on examples that require smaller or no preload at all, I do not understand why that is the case, is there a limit to the TMR0L? Hello please help asap, my specific case I have: 4MHz crystal -----> 1 / (4MHz / 4) = 1MHz timer I...- Maniac_XOX
- Thread
- C language Coding Computational Engineering Language Mechatronics Microcontroller Physics
- Replies: 8
- Forum: Engineering and Comp Sci Homework Help
-
M
State space controllers - find equations from differentials
I never asked to solve problems for me in fact i have been happy to do all the tedious mathematical work, even with the 'general' information you give me, which I still appreciate. I have viewed the pdf multiple times and have even gone through the example on there before attempting it on my...- Maniac_XOX
- Post #12
- Forum: Advanced Physics Homework Help
-
M
State space controllers - find equations from differentials
I believe my state variables to be H and T? I have also read this so does that mean i could make a pair of output equations and state vectors for each differential individually and model it in parallel on simulink?- Maniac_XOX
- Post #10
- Forum: Advanced Physics Homework Help
-
M
State space controllers - find equations from differentials
Yes i am trying to find the state vector equation. How do I get the A and B matrices? does the output vector look okay?- Maniac_XOX
- Post #8
- Forum: Advanced Physics Homework Help
-
M
State space controllers - find equations from differentials
sorry Lol everytime i work on the notebook i keep converting them to the variables in my problem, I'll change them now, problem is i have set T as y so there can be confusion. I will set y in SS equation as output from now- Maniac_XOX
- Post #6
- Forum: Advanced Physics Homework Help
-
M
State space controllers - find equations from differentials
So i am aware that the outputs must be H' and T' therefore I believe the output equation in SS form to be $$ output, y = \begin{bmatrix} Z' \\Y' \end{bmatrix} = \begin{bmatrix} -0.061 & 0\\ 0.10874 & -\frac{80}{11} \end{bmatrix}\begin{bmatrix} Z \\ Y\end{bmatrix} + \begin{bmatrix} 0.3636\\ 0...- Maniac_XOX
- Post #4
- Forum: Advanced Physics Homework Help
-
M
State space controllers - find equations from differentials
Summary:: This is similar to the examples of electrical circuit state space analysis, I have been trying to find the state space equations from the following non linear first order differentials but I keep getting stuck. Any help? A) Started off from non linear equations: $$y' =...- Maniac_XOX
- Thread
- Differentials Engineering Physics Space State State space Taylor approximation
- Replies: 12
- Forum: Advanced Physics Homework Help
-
M
Engineering First order non linear to state space equations
I have taken a look at example 2 of what you sent as it most relates, and I have tried working that example myself which i did successfully without much effort. but when I do it on my case, it becomes a much complex task.. In the example for first-order differentials, i had to reverse the...- Maniac_XOX
- Post #3
- Forum: Engineering and Comp Sci Homework Help
-
M
Engineering First order non linear to state space equations
How to represent this system in state space form? where: $$ x' = Ax + Bu \text{ and }y = Cx + Du$$ I am trying to create a state space model based on these equations on simulink, need to find A, B, C and D but like I mentioned, i cannot find the solution when the differentials are not of...- Maniac_XOX
- Thread
- Calculus Engineering First order Linear Physics Space State State space
- Replies: 2
- Forum: Engineering and Comp Sci Homework Help