This is the place for queries that don't fit in any of the other categories.
I'm doing a school project where I have to create a program that will power and light up three LED lights, where a different LED lights up depending on what key you press.
The problem here is that I haven't learned anything in my programming class on how to have python transfer voltages from the pc to the LED lights at will, nor have I learned to
control which light I will power up. I would appreciate any help on how to start this project and at least understand what I'll have to do. Thanks for any help you output.
Last edited by Mekire
on Wed Oct 09, 2013 12:52 am, edited 1 time in total.
Reason: First post lock
- Posts: 1
- Joined: Tue Oct 08, 2013 4:24 pm
Are you sure the assignment isn't supposed to use virtual LEDs through a GUI like Tkinter??? Python has no way to control anything in the real world unless you connect hardware of some type. In a pinch your PC's serial COM port can be pressed into service to light 1 or 2 LEDs programatically but you'll still need to expose the COM port hardware and that's not a trivial beginner task. Much easier would be a DAQ card that has Python drivers and digital I/O but they cost money. You need to ask what hardware you're expected to do this project with and get back to us...
EDIT: You're not by any chance using a Raspberry Pi are you?? Then it's easy!
- Posts: 268
- Joined: Fri May 31, 2013 8:12 pm
I've controlled LEDs in Python using the serial module and an Arduino, so it's entirely doable, but you'll have to be much more specific about what you have available to you.
Join the #python-forum IRC channel on irc.freenode.net for off-topic chat!
Please prefer not to PM members. The point of the forum is so that anyone can benefit. We don't want to help you over PMs/emails/Skype chats that others can't benefit from
- Posts: 2032
- Joined: Tue Feb 12, 2013 2:18 am
- Location: Mountain View, CA
Return to General Coding Help
Who is online
Users browsing this forum: Bing [Bot], Mekire, snippsat, Yahoo [Bot] and 4 guests