Index ¦ Archives  ¦ Atom  ¦ RSS

Cara ready for internal use!

Sat 06 December 2014

After about a month of work, cara (Cap'n proto Alternative RPC API) is finally ready for internal use for Chain Reaction Mfg's main project.

The features required are finally working (and tested): 1. Send raw data and structs over the wire (like everybody else). 2. Send interfaces over the wire in both directions. 3. Support a reasonable io event loop.

The second one is the most important (and unique) feature for me. It means I can call a function on a server that returns another function (or rather, a set of functions) as well as some data.

Continue reading →

Cara generation finished

Tue 02 December 2014

Generation of python from schema files is finished!

Continue reading →

Cara generation method changed; delayed

Mon 01 December 2014

Up until this week, cara had been outputting its schema files something like this:

import cara
ann = cara.Annotation(name='ann', type=cara.Text)
class MyStruct(cara.Struct):
    field1 = cara.Field(name='field1', type=cara.Int32)

However, this causes various problems due to capnp allowing use of types declared later …

Continue reading →

Cap'n proto alternative RPC API in the works

Wed 26 November 2014

Having started a new project that requires RPC, but without the benefits (and restrictions) imposed by my previous employer, I've gone on a detour towards building another RPC layer. However, knowing that building the entire layer from scratch is both a waste of time for me and would just add noise to any community I sent this to, I decided to only create the missing parts and rely on existing technologies wherever I could.

Continue reading →

Switchblade Protocol Reverse Engineering

Fri 20 June 2014

Ever since I was looking at the G13, I was really looking for an extra screen to put on/near the keyboard. I wanted a way to show updates from various things running the background, especially around my workflow at the time, which consisted of multiple (Linux desktop) workspaces each in charge of a single task. Based on which workspace I was in, I would be working on a different problem, but would want to know about updates from other workspaces, for when builds or tests finished, or the workspace was otherwise ready or needed my attention. In pursuit of that, I was looking at the fancier options like the Optimus line, but wasn't impressed enough to shell out thousands of dollars. Around that time though, I ran into the Razer line of products, which at the time included a keyboard and a laptop that had an LCD screen to the right of the keyboard with 10 buttons and a touchpad laid on top. It was much cheaper, only a couple hundred dollars, but it was out of production. I signed up for their email list and went about my day. Recently, they sent out an email advertising their keyboards, including the Deathstalker Ultimate, which has the "Synapse 2.0" UI, sometimes referred to as the Switchblade UI, that I was looking for. I ordered it and contacted them for the USB protocol, promising to build something for Linux users to take advantage of, but they have still not responded. In that email, I also offered to sign any NDAs they sent my way, but they haven't responded so I haven't signed any NDAs, and I'm now revoking that offer. In fact, I've reverse-engineered much of the protocol (it's very simple), so here it is: This is based on the Deathstalker Ultimate keyboard, but it should apply to the Blade laptop and anything else marked with "Synapse 2.0" or "Switchblade".

Continue reading →

Better Pebble Javascript

Wed 26 February 2014

In one of my apps, I was including a few libraries, and the resulting code was getting rather large and hard to manage. I also couldn't get it to work when the files were separate, so I was working with them all in the same file. Having some experience with webapps, I knew exactly what to do: uglify my code.

Continue reading →

Pebble Development with C++ on the mind - Part 2

Mon 24 February 2014

Do you want to use C++ on the Pebble but sad that you can't? Well you're in luck! It's now possible! Continued from Pebble Development with C++ on the mind (Part 1).

All you have to do is alter the wscript file to enable proper compilation, actually. But if you want a proper API wrapper to the built-in Pebble one, you'll also want to add my pebble.cpp and pebble.h files to your src/ directory (and malloc.cpp unless you want to write your own allocator and deallocator).

Continue reading →

Pebble Development with C++ on the mind

Sat 08 February 2014

I've recently been working on Pebble smartwatch development, but I've spent the past 7 years in a C++ and Python based world, whether it was web development with Django, a C++ webserver, or a myriad of Python-based tools and frameworks. With C++ and Python, ignoring class hierarchies and many of the niceties of a higher-level language, a programmer at least has a few luxuries. While I can live without many, I'd prefer not to when they don't cost me anything, and there are a few useful ones and in this article I'll show how you can get them in C with minimal overhead.

Continue reading →

Mint Plus (Braava) Hacking

Sun 26 January 2014

I'm sure many Mint Plus owners have noticed the USB port, and quite a few have even hooked it up to their computer to find out what it does. Sadly, by default, it does nothing. Now before you go pressing all the buttons, here's what you should not do:

Do not press two buttons together.

(I tried again later on in the year. That time I didn't burn my unit.)

Continue reading →

PiCloud cloudpickle

Fri 10 January 2014

There are quite a few implementations for this problem, but none of them worked quite as well. picloud's cloudpickle is great!

The problem: You have a python function on one computer that you want to execute on the other. The naive way is rather simple, but you quickly run into problems.

Continue reading →

© Fahrzin Hemmati. Built using Pelican. Theme by Giulio Fidente on github.