Once again riding the wave…

There’s a few things leading up to this post, and they’re not necessarily related, but are all sort of dependencies to getting to my current state of mind.

You may remember my huge puffs of smoke about a project I started last year called TidalWave that was supposed to be a native C++ BitTorrent client for BeOS. Unfortunately I went about parsing the bencoding the wrong way, and when it came time to do the actual network I/O, I was pretty well screwed. Top that off with horrendous memory leaks (due to lame attempts to use BMessage as a container for bencoded data) and it just kept getting worse. The best thing the program had going for it was it’s sweet icon (an isometric wave) and the about dialog with a button labeled “Cowabunga!”.

What a shame.

Fast forward to WalterCon 05, where somewhere in the discussion I got this strange conviction that we really, really, really badly need an easy-to-use dependency free (How many R5 installs come with python? When was the last time Bethon was updated?) fast, and native BitTorrent client. I don’t think I’m the only one.

Normally, I’d have picked back up where I left off with TidalWave, ripped it’s guts out and then started over with some new data types. Unfortunately, the TidalWave source isn’t in my cvs server, and my BeOS box that it lives on is still in Mississippi. Drat. Luckily, my cousin has an old Packard Bell Multimedia S606 laying around they weren’t using. The old box has 32MB of RAM and a Pentium 233. I was worried about the graphics card, but it turns out it’s one of the S3’s that actually work with the old drivers on BeBits. After hacking the bootscript, installing the dev tools on R5PE, and a few other choice updates (latest GCC, bdb, etc.) I’ve got a box that starts up, runs R5, and gives me a whopping 7 to 8 MB of unused RAM when it’s ready to get abused. Oddly enough, this seems to be plenty for BeIDE, a Terminal window, some Tracker windows, and even bdb to coexist and run happily with.

The only problem is that right now, I don’t have any online access with this box. It has no network card, and I’m not sure the winmodem would work. I don’t think I have a telephone jack in this room anyhow, so it’s not like that’ll help anyhow.

So I’m developing on what we now consider an ancient box that’s very similar to the box I originally built in highschool for myself so I could run BeOS. The difference is, I had a K-6 64MB of RAM, and an ATI card that worked way better than this S3 does.

I’ve got bencoding done. It passes all my bencoding tests, converts bencoded data to in-memory objects and converts in-memory objects back to bencoded data. It even properly handles the sorting required for the Dictionary type. Data-wise I’m a few steps ahead of where I was before. Oh, and there’s no memory leaks — yet.

You may wonder what’s so hard about bencoding, well for starters I haven’t found a bencoding library that’s released under anything other than GPL. Poo. I want this app to be under MIT / BSD — because I believe not just in freedom but also in liberty, and I don’t like imposing restrictions on software that I give away.

11 Responses to “Once again riding the wave…”

  1. PetterHJ Says:

    This is great. I thinks it’s really important that we get as much native C++ applicationss as possible rather than applications written in interpreter languages. The BT client Azureus uses JAVA, and allthough the app is OK, the JAVA engine is terrible slow. The best is native C++ (no ugly ports) apps that uses the BeOS API.

    We do need a BT client, so I hope you succeed :) Thanks

  2. Bryan Says:

    I’m well aware of Azureus, I’ve used it once before.

    It uses java, yes – but it also uses that SWT toolkit, which means it uses unstandard java components which are not part of the java platform spec. To even get Azureus running on BeOS, we’d have to not only have a complete J2SE port (in progress) but also port the SWT toolkit.

    And yes, I agree that we need good native apps that do things “the BeOS way”.

  3. eNGIMa Says:

    This is awesome news to me. Removes one of the final few applications that I need before switching to BeOS. I’ll be keeping an eye out for progress on this. Thanks for the work :)

  4. tqh Says:

    Great, I use a hacked ctorrent in BeOS for the same reasons, not needing extra libs or apps.

  5. Bryan Says:

    I looked at using ctorrent as a backend, then I saw the magical letters ‘GPL’.

    I’m guessing you’re using BONE? I should probably mention, this will be written for net_server — so hopefully it’ll work with BONE. If not, then I’m sure some intrepid person will hack it.

    Once it’s stable, I intend to release it as a community project. If Haiku had a place for auxilliary apps (they may, and I could be clueless about it) I’d be up for putting it in their tree. I can totally envision a torrent_server as part of Haiku. It could node-monitor a “shared” directory and any files dropped in would be added to the tracker, with the meta info generated and stored as bfs attributes, and it could act as it’s own seed for the torrent… meanwhile any .torrent files you open up get downloaded and you join their torrents until you tell it to stop for that individual file….

    It’s not the clearest picture of how I envision it, but the goal would be to make sharing via bittorrent a drag n’ drop operation.

    I may have to write a BeOS tracker just to test at this point — since I don’t have a network connection with the BeOS box I have just yet.

  6. zmcgrew Says:

    Screen shots?
    How about a picture of the icon? Sounds pretty cool.
    Also, a picture of the “Cowabunga!” button would be nice.

  7. DSanchez Says:

    Hi Monkey Boy:

    I can ship yer box to yez if yez wants.

    Jest let me know, and kwitcher whinin’.

  8. Bryan Says:

    Right now, everything I’m doing has no front-end. I’m doing the core in a “hypothetical” sense since I don’t have my BeOS box with an internet connection. That will be remedied by the end of next week… Hopefully.

    Anyhow, this is the only screenshot I have of the attempt that ended in failure from last year.

    http://bryan.varnernet.com/files/tidalwave_earlydev.png

  9. mikesum32 Says:

    I think we should have some sort of download kit.

    I thought it was in the works.

    Oh, I see you removed the Zeta goooogle ad that keyed in on your yellowtab is evil post.

    Keep up the good fight.

  10. Bryan Says:

    I didn’t remove it. Google places the ads automatically, based on the content of the page. If the page’s content changes, Google will change the ads.

    I have not blacklisted or removed any advertisements. Likewise, I have never edited any comments posted by others.

    But yeah, I’ll try to keep up the good fight.

    I’m not saying don’t buy from YellowTab, I just think everyone should be aware of what kind of company they do business with. If YT wants to kick developers in the sack, that’s their decision. The thing I don’t agree with is all these people saying that squabbles like this should be kept hush-hush and that these kinds of tiffs being brought into the public is unprofessional. On the contrary, I think it takes a lot of balls to do what Marcus has done, and I think it’s far more professional than hushing it all up and pretending it didn’t happen.

    HYPOTHETICALLY:
    Let’s say I’m a developer who’s never heard of BeOS or Zeta before. I strike some form of agreement with YellowTab, and then they kick me in the balls, make me pick up their soap in the showerhouse, or otherwise screw me over. I’m mad, I’m pissed, and I’m wondering if this isn’t their standard operating procedure. Then I find out from several other developers sending me private messages that I’m only one in a long line of people who’ve been ripped off, screwed, and had their hard work obscounded with. Gee, if I’d known this from the beginning, I wouldn’t have worked with YT.

    It’s like working for a mobbed up company without knowing it, and then one day they want you to drop a heavy plastic bag tied to cinder blocks in the river. It was expected of you all along, but you just didn’t know the full terms. Now you’re either going to blow the whistle and get smeared (or shot in the head) around town or you’re going to be complacent and allow the bad behavior to continue.

    I’m saying that people like Marcus being able to speak out HELPS the community by keeping us honest. You can’t build a platform on deciet. M$ dosen’t lie about windows shortcomings, they will sling mud at their competitors and pay billions to get people to think they have an outstanding product. Ask them if NTFS is suitable for the next ten years and they’ll say no. Ask them if XP is secure enough and they’ll say no. But do they make it a habit to rape, pillage, and steal from their 3rd party developers? No. They buy them out the good ole’ fashioned, and honest way.

    Does apple steal ideas from 3rd parties? Yes. Are they big enough to do it? yes. Do they get away with it? Yes. Do they do it illegally? No. Does YellowTab? I’d hope not. But what you’ll never see is Steve Jobs or Bill Gates cutting down a developer, no matter what they may have done.

    So my question is: How is Marcus exposing (what may be) harsh treatment, unprofessional behavior, and a total lack of regard for the hand that feeds them (developers are essential to yellow tabs future) unprofessional? As a professional that may someday want to make some form of investment in YT (be it time, development, or purchasing a copy of Zeta) I find his behavior of being honest, forthcoming, and sincere far more professional than anything I’ve seen from YT.

    Call me crazy, but I still believe in a thing called ethics.

  11. JonathanThompson Says:

    Marcus is living in a dangerous situation, in that regardless of the legality of what he’s doing or not doing, he could still get smeared in the court of law, if only by being dragged into court and having to fight for his right to continue to do as he has in the past: work on things beyond what some particular party had assigned to him, and talk about things that some particular party has no right to interfere with. If, indeed, Marcus were actually disclosing things that were rightfully covered under NDA, then he is acting foolishly, indeed. However, I don’t see what the logic of that would be, and publishing it for all the world to see. It would be a weird situation at best for someone to have created all that Marcus has created and not understand what he’s been dealing with in terms of what is allowable and what is not allowable to reveal, as it seems to me the understanding of what’s right/wrong to reveal is rather simple compared to implementation of what should/shouldn’t be revealed.

    As far as Bernd trying to throw a blanket of NDA over a specific email that includes things that aren’t valid for him to claim NDA coverage of and possibly throwing some small mention of something that is, well, at best, that’s playing dirty pool, and at worst, it would seem to me that would be illegal, as I can see that as a form of blackmail: saying “This is all under terms of NDA” and then throwing something dirty at the person in the email.

    Well, if there’s one thing that the big boys have learned, if you have anything you don’t feel comfortable announcing via a TV report in front of a TV audience live, you should NEVER put it in email, because it gives too much proof of what was said, when, how, etc. and is very traceable, as it leaves a path behind. If Microsoft and Sun aren’t immune to this, Bernd thinking he’d be immune to this is even crazier!

    Which points out one more thing that all developers should do, filed under the category of “CYA” and that’s keep logs/copies of all communication for reference in the future. These days, storage space is incredibly cheap when done electronically. I expect it’d be rare for correspondence that’s development-related to things you have under NDA or some other thing would fill a CD.

Leave a Reply

You must be logged in to post a comment.