Going low level, very low level…

So, I started with qemu to simulate an ARM board, connect to qemu with GNU Debugger, load some code into the qemu v-board…

So far, so good, I used to run this

qemu-system-arm -M versatilepb -m 256 -kernel /dev/null -s -nographic

This allowed me to skip qemu complaint about no kernel exists, and redirect to the output to the console, and the –s is to allow GDB to connect to it via port 1234…

The problem with this, when I leave it too long, the CPU automatically keeps incrementing the program counter (PC) and keeps looking through out the entire memory space looking for some code to execute, until it runs out of valid addresses, and an exception is raised, and qemu terminates with this error:

qemu: fatal: Trying to execute code outside RAM or ROM at 0x10000000 R00=00000000 R01=00000183 R02=00000100 R03=00000000
R04=00000000 R05=00000000 R06=00000000 R07=00000000
R08=00000000 R09=00000000 R10=00000000 R11=00000000
R12=00000000 R13=00000000 R14=00000000 R15=10000000
PSR=400001d3 -Z– A svc32
Aborted

If I’m fast enough to connect GDB to qemu, then I’m OK, if not, qemu will terminate before I’m able to connect to it…

So I had that crazy thought while having a shower…

Continue reading

Another step ahead… RTOS…

Yesterday I finished a training course that was about RTOS, the instructor was Amr Ali, and Wasiem Hashim, the course covered some topics about RTOS, concepts, scheduling, threading, synchronization, and best of all, concepts of porting…

It turned out that I know much already to get me started, and already have the foundations I need to do good work, Cross-Compiling, solid C/C++ programming skills (threading, synchronization, TCP/IP), good OOP knowledge (thanks to Mostafa Hashem), what I really need now is build my skills in device driver development, that shouldn’t be too hard, right??

Yesterday night, I had a sleepless night, dreaming about RTOS, uC-OS II, Velos, and the best of all; ARM assembly code 😀 …

As I used to collect and try all kind of UNIX OSs, (Linux “all the flavors I could get my hands on”, FreeBSD, Solaris, HP-UX, Mac OSX), I’ believe I’ll start collecting RTOSs to my library of software, and try them out -mainly- on QEMU, and any hardware I could put my hands on, like the Linksys WRT-160N, and La-Fonera 2200, or even boot it with grub on a VM (why not?!); that would be my next step…

Wish me luck…

A quick glance about filesystems…

Cluster vs. Distributed Filesystems

Cluster filesystems and distributed filesystems are two different things, but sometimes they’re mixed together, so it’s time to shed some light on that…

Continue reading

Anaconda boot time options…

In a previous post, a friend replied that I didn’t really need to modify initrd.img to embed ks.cfg just because I can’t use eth0 …

He was totally right, I’ve gone through much without looking for the easiest and obvious…

http://fedoraproject.org/wiki/Anaconda/Options, this page has all the options that anaconda (the installer for CentOS/RHEL/rPath and more) supports…

One of the options I could have used and avoid the hassle of the choosing which interface to be used for the installation is ksdevice .

It also happens to have several interesting switches; (according the page linked above) takes one of 4 types of argument which tells install what network device to use for kickstart from network:

  • An argument like ‘eth0’ naming a specific interface
  • An argument like 00:12:34:56:78:9a indicating the MAC address of a specific interface
  • The keyword ‘link’ indicating that the first interface with link up
  • The keyword ‘bootif’ indicating that the MAC address indicated by the BOOTIF command line option will be used to locate the boot interface.

See, sometimes the easy way is just staring us in the face, but yet we can’t see it, or too lazy to look for it …

DreamBox 7025+ as internet router, with 3G USB stick !!!!

Well, it’s a bit late, but hey, late better than never…

As soon as I moved from Duabi-UAE to Cairo-Egypt, I had absolotly no internet access except via a 3G USB stick that I borrowed from my friend, that 3G USB Stick model was Huawei E1550…

So i had that wacky idea, why not stick this stick to the back of my DM7025 and make it share the internet access, I’ve always used that set top box as a NAS server (via Samba), torrent download station (using Transmission), and it did pretty well, so let’s add “Internet router” to the pile, this shouldn’t be hard right??

Well, think again…

We need to

  • Build kernel modules for PPP, IPTables, usb-serial dongles
  • Flip the USB stick to the serial interface mode (Huh!!!!!!)
  • Load the proper modules and create needed /dev files
  • Get a tool to run pppd, to dial, and connect
  • Enable IPTables and IP-Forwarding
  • Continue reading