Linux - Embedded & Single-board computerThis forum is for the discussion of Linux on both embedded devices and single-board computers (such as the Raspberry Pi, BeagleBoard and PandaBoard). Discussions involving Arduino, plug computers and other micro-controller like devices are also welcome.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I am new to linux drivers and want see if my approach is correct
here. I need to write a little bit banging device driver to a custom
CPLD 3-Wire serial interface. This is a one way communication meaning
we are only writing to the device over the serial interface.
So, I think what i need to do is write a character driver will
implement an open, release, and write methods and of course the init
and exit to setup the character driver. Is the correct approach?
In my write method in the driver, when i receive the 3 bytes of data
that I need to bit-bang over 3 gpios I will enable the chip select
gpio and start the clocking gpio and transmitting the the bits on the
Anyone have a sample driver of something similar? I just basically
want to see how the correct way to implement the timer for the clock
in the kernel. I am sure I can figure it out and will, but would like
to see an example from someone who is not as new to linux as I am.
i know the pseudo code is something like the following, but maybe a
timer (i assume there are timers in the kernel) is the better approach
which is the whole reason I am asking about this.
enable the chip select gpio (set low)
while (bits to write)
set clk gpio low
wait 1/2 bit time
set data gpio
wait 1/2 bit time
set clk gpio high
disable the chip select gpio (set high)