One of the main reasons why wiring buttons and logic to GND is favoured (and then copied all over the internet) is because of power optimization.
Pulling a pin LOW with resistor to GND costs 0 watts.
Pulling a pin HIGH with resistor to +Vcc costs power.
On complex circuits or circuits that rely on batteries this power is very precious.
Other reasons ...
Projects to add shutdown and startup functionality to Pi:
There is also a solution to switch Pi on/off but it does not cut the power so it is not suited for a ...
There are complex historical reasons why electrical engineers typically pulled inputs high with resistors, and used switches to ground them.
However these reasons are not particularly relevant to the hobby use of the Raspberry Pi. Use whatever makes sense to you.
If you are making a commercial product, or want your design to be slightly better, you'll ...
There's not quite enough information in your question to give a definitive answer, but let's go through the design steps so that not only can you figure out this one, but you might be better equipped to solve the next transistor question that occurs to you.
Ohm's law expresses the relationship among resistance (R), current (I) and voltage (V): V ...
A Faraday cage will provide shielding from electromagnetic radiation, but this is unlikely to be the cause of your problem. I assume you are connecting the Pi to external circuitry (you don't give us much to work on) and this is almost certainly the problem. There are many established methods for protecting these, ranging from ferrite rings for common mode ...
Have a look here:
How to have a Raspi trigger a Remote Control physically
Needs some ideas to trigger silicone rubber buttons
A solenoid with a moveable pushrod can be driven fairly quickly and develop the force to push a button. They are usually cheap and easy to energize, e.g. using a simple transistor to drive the current (see here).
I believe the most appropriate device would be a solenoid. They are quite common. For a simple button pressing solenoid, something like this might work well. I would recommend that you put a soft tip on the front so that repeated presses do not damage the button.
As shown this circuit cannot drive two LEDs the way you want it.
GPIO-pin high: L2 lights up, L1 does not.
GPIO-pin low: no LED lights up as there is no (significant) potential difference (aka voltage) between GND and the GPIO-pin, thus no current flows, no light.
There are however ways to do what you want. This tutorial (source of the figures ...
As far as I know no-one is providing a purpose built Raspberry Pi faraday cage.
However, making one yourself is fairly simple as the core component is usually a simple aluminium mesh.
Here's a decent tutorial that you can follow.
Relays are pretty safe to use without any special isolation like optocouplers. The reason people recommend optocouplers in DIY projects... well because its DIY and an optocoupler is safer in case of something going wrong.
The input pins power a coil and push or pull a lever using some kind of snap hinge to eliminate bounce and sparks. So you are already ...
Logic levels are detected by input pins. The difference between an input pin and an output pin is that an output pin has a specific voltage applied to it. An input pin does not, and when not connected to anything, it is in a high impedance, aka. a "floating", state which essentially means the voltage fluctuates randomly. This is the third state in 3-state ...
You'll need just two things:
Make use of the GPIO pins
Using the GPIO port of the Pi is possible with numerous libraries for all significant languages. Finding one that interfaces well with Python or C is no trouble at all. Just have your pick, e.g.
Libraries for interfacing with the GPIO
Use a relay to control the 12V power line
It's easy enough to find solenoids, servos etc with the power to push a button.
The tricky bit is the mounting. Humans are really very good at pressing buttons on arbitary things, compensating for slight changes in the position of the thing, compensating for the reaction force exerted on their own body. Where nessacery providing support for the thing the ...
The manual on the Trancend Website (see pjc50's answer) suggests that the unit will be recognised by a PC if a USB lead is connected to the mini-USB connector (C) on the SIDE of the case (not the full size one on the back). It says that a Linux kernel 2.4 or greater is required then any memory card inserted in the unit will appear for the PC to access (and ...
There is no risk in connecting the GND of the power supply and the RPi together - actually, to create useful circuits most of the time this is required so that the +9V from the power supply and the +5V/+3V3 coming from the Raspberry Pi are relative to each other on the GND.
Regarding the +9V power though, you need to make sure that this does NOT come into ...
The best solution on my opinion is to use the UPS Pico , a specially designed for Raspberry Pi UPS, that offer a plenty of other features.
It is low cost, includes battery, no need for any extra cable, just put it on top of RPi.
Running on a car, and automatic shutdown, also running on XBMC.
Your config is good but i think is easier to make a ring!
RasPi USB --> Hub-USB --> RasPi MicroUsb power
Both solutions have the problem of groundloop
You can avoid it by stripping the ground in the last connection:
Hub-USB --> RasPi MicroUsb power
or in your connection schema:
RasPi USB --> Hub-USB
2A power adapter is enough: i tested it ...
I have no clue about model trains, but a quick Google search reveals that there are multiple projects for Linux which allow you to control model trains. It seems that Rocrail is one of them, and they even have a Raspberry Pi page in their wiki.
You need to fetch one of their pre built packages, and install it:
sudo dpkg -i rocrail-xxxx-wheezy-armhf.deb
ESCs (Electronic Speed Controllers) are typically controlled just like you would control a hobby servo -- with a PWM signal. There are many guides to controlling a servo that should be applicable to the ESC.
Since the Raspberry Pi is a 3.3V device you might need a level shifter if your ESC needs a 5V signal.
Here is a tutorial for Raspberry Pi: https://...
It will be best to power the Raspberry Pi using a good 2Amp power supply.
You will still need a transistor to drive the relay.
But really relays are for high power, 24volts up to 220volts and heavy loads that use dedicated power supplies not connected to Micro controllers.
You can get rid of the relay and just use a 2N2222 / TIP127 transistor to drive the ...
The B+ has 26 usable gpios. In that context 8 doesn't seem a lot.
In effect you are trying to trade off the number of gpios used against complicating the circuit.
Have you considered a port expander, such as the popular MCP23017? That connects to the I2C bus (two gpios, SDA and SCL) and provides an additional 16 gpios per chip. Up to 8 MCP23017 may be ...
I had exactly the same problem with these interrupt events under Python. I believe this is a sofware bug in the lib. I do not use these Interrupts anymore, but now I am polling the GPIO. This works perfect. The pulses has to be longer then 15 ms, as the Python sketch is scheduled by Linux. If you are interested, I can send the sketch. The Pi is used as a ...
Yes. In fact this is normal engineering practice, although for the Pi it probably makes no difference as the outputs are symmetrical. Having said that the amount of current you can supply from 3.3V is limited.
The AM7338 is a dedicated Digital Picture Frame System on Chip (DFP SOC). It is a all in one single chip solution for DFPs, handling typical functions of buttons, IR remote, memory card and flash reading, USB host and slave, and most important, direct LVDS display interfacing.
It is in the same family as other AM733x chips, and they all use the same general ...
The first thing I would do is plug it into your multimeter and see what readings you get.
Note that current clamps (with very few exceptions) have to be clamped round the live wire only. Clamping round the whole cable will not work.
You may be able to get a larger (and thus easier to work with) reading by looping the live wire through the clamp more than ...
Apparently, the Pi's 3.3V rail can't (or shouldn't) source more than 50mA of current
I'm shamelessly taking this from a recent Piversify post, "Exploring the 3.3V Power Rail", by one of our other members. The focus there is on the B+ but as Milliways points out should apply equally well to the Pi 2, since it would be a little bizarre to have moved backward ...
The 2N2222 is rated for a continous collector current of 600 mA only (that could be issue 1). To drive this current however a higher base current is required than is possible in this setup with the 1k base resistor - and the limitation of the Pi's GPIO pins (issue 2). For switching applications the goal is to drive the transistor into the saturation region (...
My approach to this would be to do everything I possibly could to avoid interfacing the Pi directly with the phone line. It's definitely achievable, but it sounds a lot harder than I like my spare time.
Some Googling suggests that it shouldn't be too difficult or expensive to get hold of something that looks like this £16 adapter from Maplin. It accepts (I'...