Hello againYou're right, I'm not planning to do all that for a simple course, it uses I2C chips and SPI .. etc. A bit complicated for starting the course.
But my plan is for the future when I get to a level in the course where I can start the course teaching I2C, SPI and write some modules libraries. That sounds nice, but considering teaching this stuff in one semester could be too much.
But in reality, I may do a simple board with several LEDs, 4 push buttons, LCD1602, some sensors and that's it, more than enough for one semester.
Hello again
teaching I2C,SPI ,PWM, Timers and counters are all ,you need more practice "write source code by your self" by use a programming language like C++or Basic and you have to determine which language you will use it and the Compiler you will handle with .usually the compilers includes the program language .but to understand the work of I2C,SPI,PWM,Timers,counters are don't take long time as much as how to interface for example 16f877A with I2C devices or use SPI to interface with other MUC .
hope i have understood you
kamal .
Use several combinations of 100nF ceramic and 10uF electrolytics in parallel,
3. R32 in the open collector section will burn out if the pins are linked and it is set to low resistance.
4. You have no protection against an MCU pin being driven low and closing one of the push buttons to VCC. Connecting supply directly to a pin driven low will likely burn out the internal driver transistors.
5. There is absolutely no point in using an opto-coupler in that way. The idea behind them is that the input side is isolated from the output side so feeding them from the same supply lines is pointless. Either use the transistor and the relay -or- use the optocoupler but not both at the same time.
You have to consider that the PIC pins can be configured as output too. If the pin is an output and driven high then the switch is closed it shorts the internal PIC output circuit directly to ground. This will allow far too much current to flow out from the PIC and could damage it.I actually didn't investigate the circuitry of this board, I didn't care about how the buttons are wired, but I new it's a pullup approach and the buttons are pulled down with 10k resistors which I understand because not to leave the pins floating. But how this connecting is a problem ?
You have to consider that the PIC pins can be configured as output too. If the pin is an output and driven high then the switch is closed it shorts the internal PIC output circuit directly to ground.
This will allow far too much current to flow out from the PIC and could damage it.
The solution is simple, just add a resistor in series with each PIC pin that connects to a switch, a value like 470 Ohms to 1K would be suitable. That limits how much current can be drawn from the pins but has no effect on the operation of the pin when used as an input so the switches and pull-up resistors will work as before.
If the board also has facility to connect other things directly to those pins, add the resistor only in the connection to the switch/pull-up, otherwise it may limit the current from the pin when it is actually needed for some other purpose.
Brian.
I think you got the point already. The port would still be damaged but instead of being driven high and shorted to ground, you could drive it low and the switch would join it directly to the supply.what if the resistor to the ground is 10k, won't that help in this case ? at least to lower the shorted pin current to ground.
I think you got the point already. The port would still be damaged but instead of being driven high and shorted to ground, you could drive it low and the switch would join it directly to the supply.
Brian.
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?
We use cookies and similar technologies for the following purposes:
Do you accept cookies and these technologies?