[FE training-materials-updates] kernel labs: complete serial-output

Michael Opdenacker michael.opdenacker at free-electrons.com
Fri Oct 4 13:55:34 CEST 2013


Repository : git://git.free-electrons.com/training-materials.git

On branch  : master
Link       : http://git.free-electrons.com/training-materials/commit/?id=36ea2bfe2eb7636f542229ad416fa53a4ed77c6a

>---------------------------------------------------------------

commit 36ea2bfe2eb7636f542229ad416fa53a4ed77c6a
Author: Michael Opdenacker <michael.opdenacker at free-electrons.com>
Date:   Fri Oct 4 13:54:20 2013 +0200

    kernel labs: complete serial-output


>---------------------------------------------------------------

36ea2bfe2eb7636f542229ad416fa53a4ed77c6a
 Makefile                                           |    2 +-
 labs/kernel-serial-output/kernel-serial-output.tex |   21 ++++++++++++++++----
 2 files changed, 18 insertions(+), 5 deletions(-)

diff --git a/Makefile b/Makefile
index e10a8bb..886c73b 100644
--- a/Makefile
+++ b/Makefile
@@ -231,9 +231,9 @@ KERNEL_LABS   = setup \
 		kernel-i2c-communication \
 		kernel-i2c-input-interface \
 		kernel-serial-iomem \
+		kernel-serial-output \
 		kernel-debugging \
 		backup
-#		kernel-serial-output \
 #		kernel-serial-interrupt \
 #		kernel-locking \
 #		kernel-git \
diff --git a/labs/kernel-serial-output/kernel-serial-output.tex b/labs/kernel-serial-output/kernel-serial-output.tex
index b8676bb..e52e720 100644
--- a/labs/kernel-serial-output/kernel-serial-output.tex
+++ b/labs/kernel-serial-output/kernel-serial-output.tex
@@ -152,12 +152,16 @@ the \code{picocom} process connected to \code{/dev/ttyUSB1}).
 If it works, you can triumph and do a victory danse in front of the 
 whole class!
 
+Make sure that both UART devices work on the same way.
+
 You'll quickly discover than newlines do not work properly. To fix
 this, when the userspace application sends \verb+"\n"+, you must send
 \verb+"\n\r"+ to the serial port.
 
 \section{Going further: ioctl operation}
 
+Do it only if you finish ahead of the crowd!
+
 We would like to maintain a counter of the number of characters
 written through the serial port. So we need to implement two
 \code{unlocked_ioctl()} operations:
@@ -171,7 +175,16 @@ written through the serial port. So we need to implement two
 
 \end{itemize}
 
-Two already-compiled test applications are already available in the
-\code{nfsroot/root/} directory, with their source code. They assume that
-\code{SERIAL_RESET_COUNTER} is ioctl operation \code{0} and that
-\code{SERIAL_GET_COUNTER} is ioctl operation \code{1}.
+Two test applications (in source format) are already available in the
+\code{root/serial/} NFS shared directory.  
+They assume that \code{SERIAL_RESET_COUNTER} is ioctl operation \code{0}
+and that \code{SERIAL_GET_COUNTER} is ioctl operation \code{1}.
+
+Modify their source code according to the exact name of the device file
+you wish to use, and compile them on your host:
+
+\begin{verbatim}
+arm-linux-gnueabi-gcc -static -o serial-get-counter serial-get-counter.c
+\end{verbatim}
+
+The new executables are then ready to run on your target.



More information about the training-materials-updates mailing list