LucD
Posts: 2
Joined: Sun Dec 23, 2012 1:33 pm

Gpio intermediate tutorials

Sun Dec 23, 2012 1:46 pm

Hi,

I have plans for own projects using Raspberry's gpio but I lack the knowledge about wiring and electronics. I found a lot of introductions but these usually end after having connected some LEDs and a switch - so right before it gets interesting. The more complicated plans I found usually just show you how to implement some special case but do not explain e.g. why they used a resistance with exactly this value or why they put a capacitor there and not somewhere else.

Do you know any tutorials (or books or whatever) that give a more detailed introduction into electronics with the Raspberry Pi or - if this does not exists - a good introduction on how to create the wiring for my projects in general that I can combine with some of the beginner Raspberry tutorials? It does not need to be in English. German, Spanish or French are also OK. I do not need any help for the software part, I just have very little idea about the hardware but I'm really curious about it.

Thanks for your help and Merry Christmas!
Luc

User avatar
gordon@drogon.net
Posts: 2020
Joined: Tue Feb 07, 2012 2:14 pm
Location: Devon, UK
Contact: Website

Re: Gpio intermediate tutorials

Sun Dec 23, 2012 2:10 pm

LucD wrote:Hi,

I have plans for own projects using Raspberry's gpio but I lack the knowledge about wiring and electronics. I found a lot of introductions but these usually end after having connected some LEDs and a switch - so right before it gets interesting. The more complicated plans I found usually just show you how to implement some special case but do not explain e.g. why they used a resistance with exactly this value or why they put a capacitor there and not somewhere else.

Do you know any tutorials (or books or whatever) that give a more detailed introduction into electronics with the Raspberry Pi or - if this does not exists - a good introduction on how to create the wiring for my projects in general that I can combine with some of the beginner Raspberry tutorials? It does not need to be in English. German, Spanish or French are also OK. I do not need any help for the software part, I just have very little idea about the hardware but I'm really curious about it.

Thanks for your help and Merry Christmas!
Luc
What sort of things are you looking for? (other than switches and lights!)

I'm looking to expand and re-do all my stuff in the new year, so pointers to what people actually want might be handy...

-Gordon
--
Gordons projects: https://projects.drogon.net/

LucD
Posts: 2
Joined: Sun Dec 23, 2012 1:33 pm

Re: Gpio intermediate tutorials

Sun Dec 23, 2012 6:08 pm

Thanks for your reply!
What sort of things are you looking for? (other than switches and lights!)
I had of course already read through your GPIO Examples and they are a really nice and easy to understand introduction. So questions that were still left are:

- Why do you use (e.g.) exactly a 1.8KΩ resistor? At the beginning it might be OK just to know what electronic elements to connect. But if I want to connect (again e.g.) two LEDs in a row (without using another pin) I already have to experiment. From reading other tutorials I know that there are formulas for calculating this. So an introduction to these physical backgrounds might be interesting because it offers you a lot of new possibilities to create your own stuff.

- I have read a lot about the possibility of burning the chip because you wire something wrong (and you also mention it in your tutorial). This tutorial http://www.thebox.myzen.co.uk/Raspberry/Breakout.html shows a protection that seems to be quite simple and it also explains how it works, but I would not know how to implement it. Maybe it is just an illusion but I think it would give a beginner some confidence if he knew that he can experiment a bit without breaking his whole raspberry.

- Some other elements that I think are important are transistors, capacitors and motors. But you are right that you can already build a lot only having lights and switches. It is probably just the "theoretical" background that I'm missing for creating own, a little bit more complicated schemes. So if I know that I want to connect x LEDs with y switches and z IO pins what transistors and capacitors do I have to add and how do I have to wire them.

User avatar
gordon@drogon.net
Posts: 2020
Joined: Tue Feb 07, 2012 2:14 pm
Location: Devon, UK
Contact: Website

Re: Gpio intermediate tutorials

Sun Dec 23, 2012 6:33 pm

LucD wrote:Thanks for your reply!
What sort of things are you looking for? (other than switches and lights!)
I had of course already read through your GPIO Examples and they are a really nice and easy to understand introduction. So questions that were still left are:

- Why do you use (e.g.) exactly a 1.8KΩ resistor? At the beginning it might be OK just to know what electronic elements to connect. But if I want to connect (again e.g.) two LEDs in a row (without using another pin) I already have to experiment. From reading other tutorials I know that there are formulas for calculating this. So an introduction to these physical backgrounds might be interesting because it offers you a lot of new possibilities to create your own stuff.
Basic ohms law: V = IR

Not sure where I use a 1.8KΩ resistor, but if I did, I may have calculated it using ohms law.

There are a few other simple electronics calculations - e.g. working out the voltage drop over series resistors, or the effective resistance of resistors in series/parallel. Similarly for capacitors...
LucD wrote: - I have read a lot about the possibility of burning the chip because you wire something wrong (and you also mention it in your tutorial). This tutorial http://www.thebox.myzen.co.uk/Raspberry/Breakout.html shows a protection that seems to be quite simple and it also explains how it works, but I would not know how to implement it. Maybe it is just an illusion but I think it would give a beginner some confidence if he knew that he can experiment a bit without breaking his whole raspberry.
then again, it might make you more careful and appreciate it more... I often have a bit of a "quick fix" approach to things I'm experimenting with, but it's easy to accidentally wire something up incorrectly - 5V to a GPIO pin is supposed to kill a Pi, and while I know I've done it by accident, and gotten away with it, it's not something I'd recommend!

quote="LucD"]
- Some other elements that I think are important are transistors, capacitors and motors. But you are right that you can already build a lot only having lights and switches. It is probably just the "theoretical" background that I'm missing for creating own, a little bit more complicated schemes. So if I know that I want to connect x LEDs with y switches and z IO pins what transistors and capacitors do I have to add and how do I have to wire them.[/quote]

Introducing active componets like transistors does introduce additional complexity but at the hobby level, the calculations are relatively simple and once you've done it a few times you sort of get a feel for it - which is fine for hobby work, but no substitute for doing it properly when doing something for "production".

My hobby as a teenager was electronics and it was my first degree choice too, but I ended up doing computing - things were slightly more interesting in the late 1970's in the area of these new fangled microprocessor.... (Jus a shame the uny I went to had thundering teletypes and a Top of the range (for it's time) mini computer that was barely more powerfull than my Apple II )-:

However, moving on from switches and LEDs to write about is something on my to-do list - which right now just seems to be getting longer and longer ...

-Gordon
--
Gordons projects: https://projects.drogon.net/

User avatar
malakai
Posts: 1382
Joined: Sat Sep 15, 2012 10:35 am
Contact: Website

Re: Gpio intermediate tutorials

Sun Dec 23, 2012 6:51 pm

I started by getting Make: Electronics book I am not necessarily endorsing it for you but I have found it very useful so far as it covers quite a bit on the theory and application of electronics and always seemed to get great reviews.

http://www.amazon.com/gp/product/059615 ... e=&seller=

I would love to see a break down of the GPIO. Like these pins are I2C and this correlates into xxxxxxxxx. It interfaces with many devices like xxxxxxxxx. Which typically operate on X voltages so you may need to....

Stuff like that. I have learned that many things out there are built for the 5v Arduino a tutorial on how to interface these shields into the Pi I think for beginners to advanced could benefit from information like this. Even a comparison of the UNO pinouts compared to the Pi would be fantastic a lot of info is out there for the UNO but understanding how that same info can be replicated to the Pi would help people make big leaps in their understanding. Since the two products can work together it makes for great sales on both sides.

Gordon has made the coding so simple to understand the hard part is explaining how to tie it into the electronic components. This is something I have on my to do list which like everyone is bigger than it should be :)
http://www.raspians.com - always looking for content feel free to ask to have it posted. Or sign up and message me to become a contributor to the site. Raspians is not affiliated with the Raspberry Pi Foundation. (RPi's + You = Raspians)

Return to “Automation, sensing and robotics”