Wednesday, August 20, 2014

MIUI v5.2 ROM for ZTE Blade C (v807C)

The MIUI ROM is heavy. I noticed severe slowing down in places. I did not use it for more than a few days though. So it could be that cleaning up the system a bit, might have helped.
The MIUI looks great, is pleasure to use with great looks, features and a similarity everywhere. But its far too removed from the android experience.
Sadly not my cup of tea right now!
Link on needrom:

Slim Droid ROM on ZTE Blade C (v807c)

This ROM is fastest of the few I tried out. Its really slimmed down, is fast and pleasant to use.

The two main problem I noticed were lack of 3G and broken battery charge monitor. The lack of 3G was not much hindrance for me, but the broken battery monitor meant I could not use this ROM.
Link to ROM on

Flashing TWRP recovery on zte blade c (v807)

Edit: Links to software added
VRoot (ENG)(6.9MB)
TWRP Recovery (IMG)(5.8MB)
Scatter file for ZTE Blade C (V807C) (382B)
SP Flash Tool 3.1304.0.119 (6.7MB)

MTK Droid Tools 2.5.3 (11.9MB)
ZTE Blade C Root and Recovery Folder (34.2MB)
ZTE Blade C TWRP Recovery Flashing Video (Russian) (41.9MB) 
My readme file with experience using the above russian video
STOCK Rom ZTE Blade C (V807C) - Flashable by SP Flash Tool (280.1MB)

Wanted to flash TWRP recovery on my ZTE Blade C (v807c). After looking here n there, I stumbled onto a video by a Russian guy who showed how to do it. I got the idea of it all. And so I proceeded.
Following the video, I got familiar with the process which is as follows:

1. Get the device rooted: using vroot the zte v807c was easily rooted.
2. Then install twrp recovery:
In the video the operator performs following steps:
a. Install the zte usb drivers from ZTE v807\Drivers for ZTE.
b. Install the mtk drivers from ZTE v807\Drivers for SP Flash Tool\USB_serial driver.
c. Next start SP Flash tool.
d. Load scatter file from ZTE v807\Recovery.
e. Select recovery image TWRP.img from v807.
f. Disconnect the phone and switch it off.
g.Click Download button and reconnect the phone to computer USB in switched off state. SP Flash tool should detect MTK Preloader and flash the selected recovery. After that SP Flash tool should display success.

For me, step f was failing with SP Flash tool giving error 8038. This meant that the scatter file we have must not be for my v807c (my phone being for India market). So I looked around on the net for info on how to create a scatter file from own phone.

A few places suggested MTK Droid Tools. So I went ahead and used MTK Droid Tools to create a scatter file.
After it was successfully created, I loaded it in SP Flash tool and followed point f again. And this time it was successfully done.

g. After this I unplugged phone from computer and as shown in video, removed the battery and reinserted it. Later starting the phone with power+Vol Up button shows TWRP logo. So its confirmed that TWRP is successfully installed.

Thursday, August 7, 2014

A tryst with message queues Pt. 4

So far... I have installed RabbitMQ server on my development machine and using it to test my development code. I have STOMP_SEND working fine. Using the management web console for RabbitMQ I can see the messages being queued. Now I have to read the sent messages. And here I stumbled into a situation where libstomp's stomp_read function was failing.
So now going ahead, I integrated the message sending code into the product. The requirement was simple. We had to send a fixed message to a queue with time stamp every two mins. So I put together a thread and put the message sending logic into it.
After testing it, I started work on the read part. The requirement was simple. The product has to read some messages from a queue and display them to user.
Thankfully one of the system guys fixed libstomp ( saving me some efforts :D ), and made the stomp_read working again.
So after putting together a test application to read from the queue, I ended up with a no of problems. First of them was garbage data read into the frame. Second was even more interesting. Even if I had multiple messages queued in, I would receive only one message and rest will be lost. Next there was also a problem with the ack mode.
So I shifted gears into study mode and started going through the protocol specification. There I learned about a few things and so I made following changes. Set body.length field to message length and using it restricted the amount of string read. That fixed the garbage message problem. Next I set prefetch-count to 1 and tried the test application. There was still the problem of unacknowledged messages. To fix this I got hold of message-id header and using it, sent ack frame. That fixed the unacknowledged messages problem.

So I guess that fixed everything. Later I put all this onto test platform for about 12 hrs and thankfully things worked out well and it all didn't tank.
So I guess we are finally good with STOMP.