Join Now

BluSPAN project starts

Carbider | 20 August, 2007 16:41

Hi, my name is Konstantine!

As you see I'm going to initiate the development and coordinate the BluSPAN (Blu_etooth S_ymbian PAN) project.
BluSPAN will be a client/server suite to allow bluetooth PAN in Symbian OS.

One of the more interesting parts and what makes this effort different is we will use Radius for accounting access and authorization. So that you can use what we will develop we will distribute a class for much of the functions.

But before all of that, I'll tell couple words about me.

I'm novice at cell phone and wireless programming. I'm 22 years old. I got my degree Information systems and technology expert from the Sevastopol National Technical University in Sevastopol, Ukraine. During education I had taken part in several projects, some RTS games, some math applications, AI and some web. Most of them were developed with C++.

Fishnest ltd, is my first full time job. Here I have done some work with wireless using OPENWRT. My Boss got the idea of developing bluetooth PAN with Radius over Symbyan OS and at the same time to find out how novice engineer can process a task that he never touched before. Nokia also found the idea of a newbie writing for the first time interesting to give us one of the first Start to Finish Blogs.

There is no doubt that this project would be useful and exciting. If you want to provide some help and comments, you are welcome and I will be grateful. All this project will be open source so you will help everyone!

Yours sincerely, Konstantine Voytenko



Good morning, Mr. Konstantine. Your mission, should you choose to accept it, involves the development of a Nokia Bluetooth Personal Area Network / Radius Client - Server suite. You may select any team members, but it is essential that one member of your team be Kevin Sharp of Nokia. He is a civilian, and a highly capable professional Nokia Forum Technical Editor. You have forty-eight hours to recruit Mr. Sharp and begin posting on the Start 2 Finish Blog regarding your assignment. As always, should any member of your team be caught or killed, the Fishnest will disavow all knowledge of your actions.

Your client should fit in the "other protocols" section of the Symbian OS Bluetooth networking implementation. You will be required to develop a class for encapsulating serial communications from the TCP/IP stack of the device in the Ethernet and BNEP frames for further transport by L2CAP / Bluetooth

More information regarding the encapsulation mission can be found here: Symbian_OS_Overview_To_Networking

and here: Core_System_Architecture

and here: 802.3

and here: BNEP

In the Blue Envelope, you will find Several SDKs and the Carbide C++ IDE. In the envelope, you will also find Nokia's Launchpad Program ( https://pro.forum.nokia.com/ ) a plethora of resources enabling you to complete your mission with the least amount of collateral damage.

Upon completion of the Encapsulation class, you will be charged with the task of creating a PAN client for the S60 / S80 operating system

and here: PAN_SPEC_V10

To prevent rogue acquisition of network resources that client must contain support for Radius Authentication, Accounting and Access. Generation of the authorization packet on the device is desired see http://www.ietf.org/rfc/rfc2865.txt and http://www.microsoft.com/ inbc_ias_wfwi.mspx

Our informants suggest you handle authentication with extreme caution and advise the use of SSL for all user/password pairs http://www.pcworld.com/article/id,121180-c,cellphones/article.html

The roadmap provided to you will lead you into undocumented and perhaps unfriendly territory as you attempt to debug your application to work with the Windows XP PAND. Whilst pleasing millions of already satisfied Nokia users and undoubtedly achieving great fame by allowing them to use their favorite applications over Bluetooth on their XP machine - your mission will not be complete.

The implementation of a Network Access Server will be required to handle network Access and provide concurrent information to a Radius Server. Again, unchartered territory. Slight modification to Chillispot http://www.chillispot.org/ may be possible allowing it to handle pseudo Ethernet devices (bnep0, etc) You should attempt this ONLY under a 2.6 Kernel with BlueZ and Affix as your Bluetooth stacks. The stock FreeRadius will be ideal.

A windows implementation of a network access server should also be developed. Codename WIN-PAND-RADIUS You must ensure it's downloadable, foolproof and just like the rest of your mission OPEN SOURCE - We suggest GPL. The free world as we know it depends on you.

And Mr. Konstantine, the next time you go on holiday, please be good enough to let us know where you're going. This message will self-destruct in five seconds.


Mission Commander David
Fishnest Ukraine

Start of development on Carbide

Carbider | 23 August, 2007 13:09

To develop programs for nokia phones running S60v3 I chose Carbide C++ IDE.
Carbide C++ is a tool to create applications for Symbian OS.

My machine is running Windows XP SP2.

There are several variants of Carbide C++. I've chosen Professional Edition.

So i downloaded Carbide c++ v1.2 using this link:

http://www.forum.nokia.com/info/sw.......

To use IDE you first need to install:

»ActivePerl 5.6.1.x

I've downloaded ActivePerl 5.6.1.638

Direct link is:

http://www.activestate.com/store/.....

Download page is: http://www.activestate.com/store/dow.....


»Java Run-Time Environment

My choice was JRE v 1.4.2 by link:
http://javashoplm.sun.com/ECom/......


»Platform SDK

First of all we want to create application for S60v3 platform.

So we need download S60 Platform SDK by this link:

http://www.forum.nokia.com/info/sw......


How to handle all of that.

I recommend to install all of we've downloaded in this order:

1. Install ActivePerl

2. Install JRE

3. Install Carbide c++

4. Install S60 Platform SDK (install it to folder path which is out of white spaces)

 

My experience was successful and Carbide started correctly.

To make my first steps I've read Carbide.c++ Introduction 
http://www.forum.nokia.com/info/sw..... 
and found it as an excelent document.

My first impression was: "Hey! The environment seems to be like Eclipse Platform!".

But after reading introduction PDF I knew that Carbide IDE is based on Eclipse open source development platform.

I started my first project, just using one of given wizards. After building and running project, the phone emulator appeared. And my program was available there in "Installed" folder. During development and emulating I discovered that my Pentium 4 2.6 GHz, 256 Ram notebook works slowly but stable. Now I'm looking for some hardware here, in my office to satisfy the needs of recently installed platforms. I'll tell you if I find optimum.

I was told to use CVS at SourceForge.net for collaboration,

the account is registered. I made a home page, there isn't much to see yet,

but I will post the URL here and if you want to help on the project you can join!

S.F. link: http://bluspan.sourceforge.net/

The Battle for BlueZ

Carbider | 18 September, 2007 13:14

 Last week I asked Kostya to install Fedora 7 and BlueZ. We have a big pile of parts so when ever
we need some cheesy unix box (no xwindows etc) we just make one from the parts lying around.

Kostya is fresh out of college and hadn't really worked on UNIX that much, if at all, so, I figured
I'd go ahead and work on the same task and play with it a bit.

The last thing I wanted to do is get into a big argument with the programmers in the office
as to which *nix is better, besides, the whole idea was a simple machine that might work like
an out of the box bluetooth NAP, with the addition of radius. 

My project was a $200-300 machine, booting from USB flash, no monitor, running BlueZ and SLAX http://www.slax.org.

If you haven't checked out SLAX, check it out. I have a couple machines in the office that run it, burn an ISO,
pop it in the CDrom and wala you are rolling.

If you unpack that ISO onto a USB MSD, then write the boot sector using a utility called syslinux, you can
do without the cdrom and boot right from USB with a motherboard that supports it.

pretty cool eh?


In one of my emails to Kevin, I wrote that I started working on the NAP side to which he replied
"Hey post about it" mentioning that the road there is often as interesting as the destination and
part of the S2F blogs nature is the public display of trials and tribulations in the process of development.

More likely this will be a post on how not to develop. 


So, down to the store for some parts, I'd need a motherboard (FOXCONN WINFAST), memory (256), a CPU(AMD SEMPERON),
and some cheesy case w/ PSU.  Grand total $150 or so in the local currrency.

I took the base installation of SLAX as my starting point, I figured what i'd wind up with in the end of it
all was a machine that would only be accessed via telnet and never rebooted. With Bluetooth, figure you can
connect any 7 devices so I was hoping that the machine I built would be enough.


Downloaded SLAX, unpacked it, installed it, sys'ed it and set the bios up for booting from USB.  This should have given
me a nice little UNIX environment that would let me configure a little OS that I could later pack back into an
ISO and distribute as a bootable CD or use in a virtual machine (like virtual box).

SLAX uses a UNION file System, located in ramdisk. All the changed you make are saved to a second file system
and before you shut the system down, you can issue the command 'configsave' which takes all your changes and
puts them in a special module file. Next time you boot, SLAX looks for this file in the root directory of all
your mounted drives and if it fonds it, loads it. Alternatively, you can save the file to the /modules directory
and have it loaded during boot.

http://pendrivelinux.com is a good site for reference.

everything up to this point was as advertised.

You can make a module by installing software, then saving the changes. BlueZ, the Official Linux Bluetooth stack
has a module, so I used it, there were a few dependancies and some functionality added by these modules:

blueproxy_1_13.mo
Bluetooth_1_1.mo
bluez_mo_1_0.mo
dbus_0_61.mo
gtk_2_10_6_i386.mo
PyGTK_2_6_2.mo
Python_2_4_3.mo


All of which you can get on the get on the SLAX repository.


The PIN helper application complained a bit about not finding a library, got around that with

'ln /usr/lib/libbluetooth.so.1.0.25 /usr/liblibbluetooth.so.2'

BNEP is loaded in the kernel at runtime with

' modprobe bnep '

which I stuck in /etc/rc.local along with


' hciconfig hci0 up '

which turns on the USB Bluetooth DOngle and the service discovery protocol deamon


 ' sdpd '

and last but not least

' pand --listen --role NAP '

http://bluez.sourceforge.net/contrib/HOWTO-PAN is a good link for explaining the actual workings.

so far so good, I could see the SLAX machines from a windows notebook, SDP returned the existence of a NAP but when I tried to pair, nothing,.. a long timeout.

Tried switching the PIN helper but that didn't seem to do much and further investigation revealed it was looking for x windows and couldn't open a window so it died.

There is another version SLAX with X windows, but by the time I tried to connect with the new SLAX it seems my windows had been poisened with ad information or something, Couldn't ever get a connect from my notbook although from other machines, it connected but failed to give an IP address. I hadn't actually  considered the system fully configured, DHCP hadn't been turned on for BNEP0 nor had I set up any hotplug scripts yet.

Prior to this, I had been booting the machine pretty regularly, changing the config, saving a module and rebooting to ensure the changes I made where being included in the regular boot. With the advent of a connection and the knowledge that's need to script hotplug for the devices, I went to lunch. Upon return - the machine had hung. Completely dead, no signs of life, and since everything is going on it a ramdisk, nothing to read later after a hard boot to give clues as to what had actually happened.

Futher testing showed that the machine would hang regularly, often within an hour. Not very interesting for our purposes since a big part of the idea to set up the whole thing from boot to operation on a "diskless" system was to make it somewhat "foolproof" and reliable. Download, make a flash, or boot the ISO in a virtual machine.

My first though was maybe the whole boot from a flash idea wasn't the best way.. Second thought was maybe SLAX wasn't the best solution, I grabbed the machine, grabbed a copy of Fedora-7-i386-DVD.ISO and went home figured I'd have a project for the weekend, back in the office Monday to show my tricks to the boys.

Back to the computer store, to pick up a hard drive to install Fedora on. Once you get a Linux installation you want, you can use the Linux Live scripts to make a ISO and that was my plan. ( http://www.linux-live.org/ )


I burned a DVD with the ISO I had, installed the hardrive and a DVD in my "diskless" machine" and set off to install.

" INSERT BOOT DISK and PRESS ENTER "

Hmm, read the forums - "Me too! and me, and me too" I wasn't the only one not booting from the Fedora ISO, yet most of the suggestions where along the lines "probably a bad disk try to burn another one" or "you should stop smoking crack and try again"

After 3 attempts on 2 different burners I finally figured out the software I was using was not writing the  El Torito boot system in sector 17 of the last session of the ISO.

4th time was a charm, downloaded deepburner pro, it worked fine.

Fedora wants some memory for it's GUI setup, with 256 MBs it whined and gave me text mode - fine with me, I didn't grab a mouse anyways. Obviously not your father's UNIX.

A quick run through the standard options, pick a keyboard, pick a language, config your NIC, give a name and slice your disk into partitions. I didn't really expect to use 500 GB, I just wanted a big disk for my music collection later. I broke the disk up, gave myself 100 mb and mounted /boot there, and another 5 GB on / and 300 MB for swap.

The system complained I didn't have enough ram and asked if it was alright if it turned on swap right away. I was suprised actually, gee, I didn't want X windows and didn't realy expect the text based installation to be memory intensive.  I clicked YES, and the set up went on execute the changes to the partition and format the disk.

46% through the format, I got a red screen with a bunch of garbage and the hard drive was making terrible noises. 

Hmm, ok, reboot, do it all again, this time, let it take the defaults for the partitions. No luck, same red screen,  same 46%.

A friend of mine who had stopped watched the machine booting said, Gee, "how can you read that fast" I chuckled and answered "That's why we make the big money. When he saw the red screen with all the garbage he asked, "how can anyone understand what that means?"

By now the Seagate Barracuda 500GB SATA hard drive was making chirping and cracking sounds as if it was about to explode. I answered my friend, "it means the drive is dead"

I figured i'd found a bad sector and the OS wasn't dealing with it. Google noisy seagate and saw quite a bit about it, a few people had suggested adjusting some of the SMART settings, others just sent the drives back.

Figured try that on a fresh head (err) and a another hard drive. "Vodka - Connecting people" was the motto for the rest of the night as I left my cyber endevors for the evening. The next morning I went down the the computer store and picked a $50 samsung 80G SATA drive. Nope, same red screen at 46%.

By now, my cheesy $150 machine was already in the $500 range and things still didn't look any better. Checked the net for bios updates and when I couldn't find any I becames convinced I had been stuck with a cheap immitation chinese motherboard.

Back to the computer store. ANother motherboard (ASUS), 512 MB of RAM, and promises that the board would boot from USB. Tried the Seagate, still chirped. tried to boot from USB, nope, and settled in on the 80 GB drive.

Back to square one. I'm going to still try to do it on SLAX, get the smallest ISO I can, and go from there. I learned some lessons:

* Never trust a salesman, I don't care if the guy says the machine will boot from USB, "Prove it" will be my answer.

* If your UNIX is flaking out, you can probably get it to fit on your system, recompile the kernel, nifty boot tricks etc,..  but why mess with it. My mistake was trying to get everything under a couple hundred bucks and picking a less than friendly motherboard in the process.

* SLAX is plenty stable, if you boot it on a decent machine.

* If your weekend project lasts until Thursday you are doing something wrong.

* Even if you have been working on UNIX since 1989 you'll never know it all and sometimes the only way you'll find out is by actually doing it. UNIX is amazing, it's like you can do anything.


I wouldn't write that it was a complete loss. I know everything that needs to be done and how to do it. I don't have the biggest choice of parts here in Ukraine, so, I'm going to spend a little time shopping around for a decent motherboard and I'm going to try again when I find it.  BTW, the CHillispot.org site is down, and has been for at least 2 weeks, anyone that has any suggestions for another NAS, please let me know. with so many WiFi Hotspots using it, I'm hard pressed to believe that project is dead.

Ohh and if you have read this far, please save the internet at http://www.savetheinternet.org You really have to wonder what will happen to the open source world if you and millions like you don't do something to keep the internet free. Thanks in Advance.

Kevin thought it would be interesting to know the behind the scenes, if S2F blogs where about the HOW-to's of development - let this be a how-not-to :) 


David Stickney
Fishnest Ukraine

1 2 3 4 5 6 7  Next»
 
 
Powered by LifeType