Today I was writing a shell script when I came across this issue. In one part of the shell script I needed to count the number of lines I read from an input file, this is where I used 'let'.
Script to indent your C and kernel files
Steps to create a script/command for indentation:
1. Create a file named "indent_cmd" without any extension. (Do not name it "indent" as there is already a command of that name in linux, which we will use too).
# vi indent_cmd
Installing my custom kernel on my Ubuntu Desktop
Today I had to customize my Ubuntu Precise kernel. I was required to change the number of maximum pages which can be allocated contiguously so that I could dma_alloc_coherent more memory.
How to change your kernel space memory in Ubuntu and embedded
While writing a driver for Ubuntu or porting linux to a new embedded board one may need to either limit or increase the RAM (Random Access Memory) used by kernel. This can be achieved by tweaking the kernel command line arguments sent from the second stage bootloader to the kernel.
How to make my C code have multi-level logs
How to make my C code have multi-level logs
Sarah, an embedded engineer in the software IP development team, writes tons of C code daily. All the company employees including her colleagues and boss are the users of her code. She has to make sure that her code is flexible for all the users. For example, her co-workers need all the details at all the levels of the program execution while her boss is only interested in the results. For this Sarah uses multi-level logs in her code.
What are multi-level logs?
Categorizing the logs thus forming a level for each and printing the logs on screen only when that level is required
Flashing uboot image from existing uboot prompt
Many a times, while playing around with u-boot, you will face a need to change its source code, compile it and reflash it on your board. For raw board (means when there is nothing on the board and your doing it for the first time) you may deploy different methods like JTAG, Serial Flasher, etc. But suppose you already have and existing u-boot image in your flash or RAM than bringing in a new image to your RAM and falshing it to the derisred flahs, NAND or NOR, is easy enough, thanks to the various commands provided by u-boot.
Getting help on u-boot command usage
To many, U-BOOT is just a secondary bootloader, a means of loading kernel and handing over the execution to it.
Executing a new u-boot image from existing u-boot prompt
Hi friends,
Sorry blogging after long time.
I recently got a question on how to bring an u-boot image to RAM temporarily for testing and debugging purpose instead of burning it every time to flash or eeprom after making small changes. I couldn't respond to that one on time, my apologies. So here's how we could do it.
Sorry blogging after long time.
I recently got a question on how to bring an u-boot image to RAM temporarily for testing and debugging purpose instead of burning it every time to flash or eeprom after making small changes. I couldn't respond to that one on time, my apologies. So here's how we could do it.
Understanding UBoot Environment Variables
The following is the snapshot of standard U-Boot Environment Variables.
Expanding Guest OS VmWare Disk Size
The following steps are for VmWare Player and guest OS as Ubuntu 10.04 (Lucid Lynx).
Autologin in Linux
Autologin on boot up will be useful when you want to execute some application or program on boot up and you call some scripts or terminal commands from within that program.
killing a process dynamically
Many a times there arises a need to kill a processes without actually being able to type ps on the terminal and look for the process id to give it to kill.
make: warning: Clock skew detected. Your build may be incomplete.
You may get warning of this type when:
1) You try to build after moving your data from one machine to another.
2) You try to build after restarting any old machine.
1) You try to build after moving your data from one machine to another.
2) You try to build after restarting any old machine.
Configuring Network Interface-Ubuntu VmWare
Many users using a Virtual Player might often (rather most of the times) require to configure a network interface in the VmWare. The most common requirements for such an interface are
/bin/sh: Illegal option -h
Many a times, while running some scripts one cat get errors like "/bin/sh: Illegal option -h".
One of the reasons for this can be
One of the reasons for this can be
ENABLING LOW LEVEL KERNEL DEBUGGING AND USING EARLY PRINTKs
In this post I am going to show how to enable low level kernel debugging option and how to enable 'printks' to get prints during boot up also.
Lossless Resizing Algorithm in C : VGA to QVA
At some point of time in an embedded engineer's life a need may arise to 'resize' an image. Resizing an image means changing its resolution.
Subscribe to:
Posts (Atom)