Saturday, July 20, 2013

pyelm327

Last night I set up a bitbucket account and this morning I got the setup.py script working for my ELM-327 device library/driver.

Here is the link: https://bitbucket.org/xtacocorex/pyelm327

The documentation isn't all there yet on how to install and run, but I did provide a sample script that you'll have to edit.  On Linux the script has to be run with sudo or you need to change the device permissions of the com-port the ELM-327 device creates.  No elevated permissions are necessary for OS X.  I haven't tested it on Windows yet.

From my testing so far, the com ports defined in the elm327unitttest.py script are as follows:
OS X: /dev/tty.SLAB_USBtoUART
Debian Based: /dev/serial/by-id/usb-Silicon_Labs_CP2102_USB_to_UART_Bridge_Controller_0001-if00-port0

Windows will probably have it be COMX, where X was the next available com port when the device was attached.

I set up an issue tracker on the bitbucket page, so if you run into issues with the library, put the issues there and I'll take a look at them.

This is a mostly complete library, but there could be issues that I haven't run across.

I plan to add some more of the ELM-327 command set, I only wrote the basic stuff I needed for the CarHUD.

Friday, July 19, 2013

Quick Update

Just wanted to throw out a quick update.  I created a bitbucket repo for my ELM-327 Python Library, but I don't have any code pushed to it yet.  I also have to create the setup.py script for it and test to make sure it works.  I'll have a sample script provided that can be used to run with and see how it operates.

I'm going to be fairly busy for the next couple of weeks, hopefully I can get some time to put ideas on paper and collect my thoughts.  Maybe I'll get a couple of schematics sketched out the old-school way with a pen.

Saturday, July 13, 2013

Initial Projector Requirements and Thoughts

Since I'm not done with the embedded OS yet, I'll touch on the projector system.  I've been thinking about this a lot recently as the design and implementation will dictate other aspects of the total system design.

If we refresh our memories on the Requirements Page, we can see that Tier 2 requirements have been defined for the projector system.

I'll copy them here:
  1. The projector system shall receive video over an RCA Component signal.
  2. The projector system shall be powered by 12V.
  3. The projector system shall be able to control brightness.
Here's what I currently have, hardware wise, for my projector system:

3.5in LCD Monitor

Yep, just the monitor.  I think I paid $18.29 for mine from a different seller on eBay.  Cheap enough that if I break it, I'm not out of a lot of money.

Here is a nice picture.


This is my idea for the projector.

My plan all along was to disassemble the LCD monitor and cut the connection to the backlight.  I also am going to remove the metal backplate that evens the backlight out, leaving just the raw LCD panel and the control circuit board.

For my new backlight, I found these really cool 0.8in 8x8 LED matrices from Adafruit that have an i2c controller.  The i2c controllers allow for four of the devices to be hooked to the Raspberry Pi's i2c lines.  I think I only need two of them initially.  The LED's themselves have 16 levels of brightness, which meet my Tier 2 requirement of being able to change the projector brightness.  The brightness will be controlled by 3 buttons connected to open GPIO pins on the RPi, one for increase, one for decrease, and the other will be a mode button to cycle between all LEDs on, every other LED on, and every 2 LED on.

So what does this design mean for the rest of the system?

Well, I now have to get the schematic drawn up for the STN1110 OBD chip since that will hook to the RPI uart lines.  I need to get all the components and attempt to get my ideas prototyped out.

On another note, I'm probably going to be working on putting the OBD library and ELM-327 device code on github soon.  Need to get a setup.py file created that will install it properly.