Hello there everyone,
I am a new C programmer, I read couple of tutorials , I can say that I`m familiar with the basics of the language and the idea behind it.
I`m working with linux as my main OS for couple of years now ,and I want to write programs , drivers , what ever will make the community happier.
Still ,after the tutorials ,I can`t write a decent program or driver.
I have some USB gadgets ,video cards,etc.. and would like to write drivers to operate them as I like.
Let`s say I have a RGB LED lamp and I would like to control it - how is it possible ? can someone please direct me to the necessary tutorial or book ?
Plus , I`d like to write my own driver to ATI 3870x2 video card,as it is not supported by ATI drivers,how is it possible ?
If the post is not in the correct sub-forum ,please move it where it belongs.
Thank you very much ,
Danny.
15 replies to this topic
#1
Posted 23 April 2010 - 01:15 AM
|
|
|
#2
Posted 23 April 2010 - 07:16 AM
A couple of tutorials on C aren't going to help you much in the way of writing drivers.
#3
Posted 23 April 2010 - 07:45 AM
I've been programming off and on for over 19 years, and don't know how to write a driver. Learning C will NOT, by itself, teach you how to write drivers. You need to read tutorials on that specific topic, in the context of the specific OS you are writing them for.
Writing a video card driver, in particular, is going to be highly non-trivial, and would not be my first driver project. Start by writing a keyboard or mouse driver!
Writing a video card driver, in particular, is going to be highly non-trivial, and would not be my first driver project. Start by writing a keyboard or mouse driver!
#4
Posted 23 April 2010 - 04:03 PM
I do want to point out, though, that WingedPanther is kinda on the far end as far as length of experience goes. I wrote my first after programming for six years, so it'll take you a while, but it's not impossible. Who knows, maybe you're a faster learner than I am. :)
sudo rm -rf /
#5
Posted 23 April 2010 - 05:49 PM
linux drivers....linux drivers..... WAIT THERE'S A BOOK ON THAT
http://oreilly.com/c.../book/index.csp
it's in pdf format so Idk why they continue to sell it. It just teaches you the functions ect that are available on linux to write drivers. I haven't read it yet(no time, finals in a month) so I can't vouch for it but it's an oreilly book, how bad can it be?
http://oreilly.com/c.../book/index.csp
it's in pdf format so Idk why they continue to sell it. It just teaches you the functions ect that are available on linux to write drivers. I haven't read it yet(no time, finals in a month) so I can't vouch for it but it's an oreilly book, how bad can it be?
https://wiki.ubuntu....t=getubuntu.pngubuntu.com“Never trust a computer you can’t throw out a window.” -Steve Wozniak
#6
Posted 23 April 2010 - 09:11 PM
Writing drivers for anything is always a highly challenging project. But maybe setting your goals high will help you to achieve this fairly quickly. I recommend familiarising yourself with how drivers actually work and then as it has been pointed out by someone else on here, try something a little easier than graphics driver. Keyboard or mouse are probably the easiest. This is actually something i have been starting to do a little more research in of late. It's not easy!!!
#7
Posted 23 April 2010 - 09:23 PM
Also an intricate understanding of your computers CPU, and how it works will help. C programming will make this possible, but a good understanding of inturupts and calls for you CPU is also necessary. I'm sure there are others here who know a lot more than me about this, and they will all tell you that doing a few tutorials will not make you a good programmer, you need to practice on goals which streatch you but are not beyond your understanding.
#8
Posted 24 April 2010 - 01:27 PM
Port I/O is another thing you should take a look at for the keyboard and mouse drivers. My first driver was a speaker driver, which was relatively easy. I can show you how to do that if you like. Do you know assembly language?
sudo rm -rf /
#9
Posted 26 April 2010 - 10:35 PM
Thank you all so much, it is a privilege to read and learn from your comments.
I understood that there`s a line between programming in C and writing drivers, as they are not the same task,
still, I would like to know the basics of interaction with the hardware.
I see each and every day news about projects that port phones, embedded computers to a linux-enviroment (ie. android),
and I would like to do this too, writing a driver for the system for a specific hardware.
MeTh0Dz - I`m aware, though the mission isn`t impossible, I`ll take that project as a goal,challenge.
WingedPanther - Thank you very much for the clarification, my current project will be writing a simple driver as you suggested, kbd/mouse/sound card.
instantcake - I`ll surely take a look at the book, thank you.
ToMegaTherion - most grateful for the tips.
dargueta - I am familiar with assembly, I would be grateful if you could show me the basics of the process.
I understood that there`s a line between programming in C and writing drivers, as they are not the same task,
still, I would like to know the basics of interaction with the hardware.
I see each and every day news about projects that port phones, embedded computers to a linux-enviroment (ie. android),
and I would like to do this too, writing a driver for the system for a specific hardware.
MeTh0Dz - I`m aware, though the mission isn`t impossible, I`ll take that project as a goal,challenge.
WingedPanther - Thank you very much for the clarification, my current project will be writing a simple driver as you suggested, kbd/mouse/sound card.
instantcake - I`ll surely take a look at the book, thank you.
ToMegaTherion - most grateful for the tips.
dargueta - I am familiar with assembly, I would be grateful if you could show me the basics of the process.
#10
Posted 26 April 2010 - 10:38 PM
Alright. I'll try to write an ASM tutorial on writing a motherboard speaker driver this weekend. Depends on when my next exam is. By the way, what assembly language do you know? If it's anything but Intel then I can't help you, unless MIPS has some port I/O instructions I'm not aware of.
sudo rm -rf /
#11
Posted 27 April 2010 - 06:38 AM
x86 assembly.
#12
Posted 27 April 2010 - 11:34 AM
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users


Sign In
Create Account

Back to top









