1) Open up the scroll tablet WARNING THIS WILL VOID YOUR WARRENTY, looking at the hardware compared to previously posted images my version is more integrated with a single board.
Main board - http://www.flickr.com/photos/jcoxon77/5649906783
2) Identify the Serial port pads, there are 4 small solder pads close to the SD card slot,
Serial Port - http://www.flickr.com/photos/jcoxon77/5649905993
From bottom to top (away from SD slot)
GND
Rx
Tx
Vcc
These are 3.3v TTL pads.
3) Solder some wires to these pads and attach to your 3.3v Serial port - PC/Laptops don't have 3.3v serial ports so you'll need some form of convertor such as http://www.coolcomponents.co.uk/catalog/product_info.php?products_id=356
To access the Scroll's debug console you'll need some form of terminal - I personally use kermit, you'll need to set the serial baud rate to 115200. Remember that tx->rx and rx->tx when attaching the scroll to the usb serial port.
4) Boot the scroll - you'll see lots of debug, once the scroll has booted you'll be dropped into a root console (this actually means you don't need to root your machine - though it'll help for the next step.)
5) To get GPS data onto your scroll you'll need a GPS that outputs data over serial at 3.3v - in this example I've used a GPSbee http://www.seeedstudio.com/depot/gps-bee-50-channel-ublox-5-p-560.html with a simple breakout board. I've powered it separately from some batteries through a voltage regulator but you 'should' (but untested) be able to run it directly from the VCC pad.
As the scroll's serial port is set at 115200 and by default this GPS is set at 9600 I first power up the GPSbee and connect it via the usb serial port to the computer, you can view the data stream in the terminal you used to see the debug console (but first changing it to 9600). We need to send a command to the GPSbee to set it to run at a baud rate of 115200 so:
- Code: Select all
echo "\$PUBX,41,1,0007,0003,115200,0*18" > /dev/tty.usbserial
Now when you view the GPS's data you'll have to set it to 115200 rather than 9600. This setting isn't saved by this GPS module so we need to continue powering it, we now can connect it to the scroll's serial port.
http://www.flickr.com/photos/jcoxon77/5649905427
6) Your scroll needs to be rooted and to view the data in a nice gui you should install http://code.google.com/p/android-serialport-api/downloads/detail?name=SerialPort_0.7.apk&can=2&q= which contains a nice program called Serial Port which allows you to access this device.
7) Open up SerialPort, go to settings and select the right serial port (tccSCA0) and the baud rate is 115200, then go back to the main menu and select console - you should start seeing the GPS's nmea data:
http://www.flickr.com/photos/jcoxon77/5650471942
Yes this is quite complicated for a relatively simple setup but its a first start, I haven't worked out yet how to change the baud rate of the scroll's serial port - i suspect it is set by the kernel at boot or we may need to compile a binary such as stty. My plan is not to actually attach the GPS directly to the serial port but to instead put an arduino mini pro in between, this arduino will allow me to have more then just a GPS attached such as temperature sensors and leds etc. The arduino will communicate with the scroll using its hardware serial and the GPS will be attached using software serial.
Scroll <-hardware serial-> Arduino <-software serial-> GPS
There is a quite a bit of space inside the scroll, especially around the battery pack so it shouldn't be too hard to fit everything inside!
Here comes the cool part. If we can match up the baudrate and stop the console posting to ttySCA0 then we should be able to get android to actually regard our hacked GPS as an internal GPS. In /init.tcc92xx.rc there is a commented out section regarding
- Code: Select all
setprop ro.kernel.android.gps tcc-uart0
If its not possible to change the debug serial speed then the arduino in the middle will allow us to get round this - the arduino can easily be made to forward anything it receives on its software serial to its hardware serial and this will convert the baud rates appropriately. Of course I haven't tested this at all - just a theory (though someone has thought of it before http://www.slatedroid.com/topic/13293-pl2303-and-other-usb-to-serial-modules/