PDA

View Full Version : Project Worth The Wait



blake
03-25-2008, 09:50 PM
This project has been in the works for years and has stalled repeatedly. It has been such that I've been reticent to even talk about it like it might actually ever finish.

In the years since its inception things have changed dramatically. It was to be the first Mk3 running a Motec (this was before the AEM was even a rumor), it was to be the second Mk3 running an SP63, and so on.

Well it's time it actually got finished. And I don't intend to "Just get it rolling" like I've been tempted to before. It's no longer going to be the first at much, but it's going to be worth the wait.

Looks like a blank slate to me =)

http://eight.user.openhosting.com/~blake/supra/paintedbay.jpg

P.S. Those of you with really good memories might remember me as WilLyons from supraforums. My e-mail address on the sogi list was WilLyons as well.

Supra469
03-25-2008, 09:52 PM
I agree!

That's a good starting point! Nice.

blake
03-25-2008, 11:01 PM
Well I lied about the blank slate. A quick trip in the wayback machine:

http://eight.user.openhosting.com/~blake/supra/intake-rail-unpolished.jpg

You might remember SP selling these a while ago. I don't know if anyone actually bought one, but I do know who they made the first one for =)

http://eight.user.openhosting.com/~blake/supra/top7m.jpg

All nice and shiny, even the CPS housing. And thanks to Arz I'll have a matching CPS cover soon.

Speaking of shiny things, here are some valves I got from PowerHouseRacing in TX (with springs, retainers). I've long since forgotten the details but they are 1mm Oversize.

http://eight.user.openhosting.com/~blake/supra/head-valves.jpg

Ah but time is a harsh mistress, and that which shines brightly...

http://eight.user.openhosting.com/~blake/supra/sp61gt-spweb1.jpg

Not a very good shot of the rest of it, but you can see the thermostat housing, CPS, and valve covers have lost their finish.

"But that's just a picture from SP's website (http://www.spracingonline.com/store/SP_61GT_BB_87-92_Supra_Direct_Bolt-On_/3629)!" you say? Well ya you're right it is. They've been using my engine as their mockup for 7M projects for years. If there was any doubt: That's also my HPF Bronze clutch disk that's been collecting dust on the valve covers forever.

For those wondering why this has sat so long, I'll keep the explanation brief: I get the blame for the first year or so of delay, SP gets the blame for all the following years.

Mr. Sinister
03-26-2008, 09:47 AM
Good to see you're still around (with car).


For those wondering why this has sat so long, I'll keep the explanation brief: I get the blame for the first year or so of delay, SP gets the blame for all the following years.

What happened? I remember your car at SP at least 5 years ago.

blake
03-26-2008, 10:41 AM
Good to see you're still around (with car).

What happened? I remember your car at SP at least 5 years ago.

Life Happened.

----

I wasn't going to say much more than that as I don't want to be seen to be assigning blame in a situation that's taken place over years and in which nobody really remembers all the details. I had to refer to spreadsheets even for this post.

But even after my 'keep it brief' comment, you asked for more and I suppose if I'm sharing about the project it's an inevitable question. But go ahead and skip the rest of the post if you like, I assure you it's not that interesting =)

The initial stall was due to, shall we say, 'funding prioritization' on my end (a situation I'm pleased to say is long since resolved).

But after that, I suppose to a certain extent the guys at SP just got used to having the car around, and I got used to not having it.

You'd really have to ask Larry/etc I guess. Maybe it always slips in priority because they're not confident I'll pay the next bill? Still, I've had a positive balance with them for almost 4 years now (I changed my mind on some parts but had already paid), and they're welcome to ask for a deposit (and haven't).

I've been a bit bipolar on the issue myself. It has crossed my mind to just send them 10k and say "if we don't use it all, I'll pick up a check for the remainder with the car". Or conversely to 'legally request they return my previous payments for non delivery'.

Both parties bear responsibility for stalling things, so I don't plan to dwell on the issue. There are no hard feelings, as far as I know. I'm happy so long as it gets done.

If for some inexplicable reason you want to know more, feel free to PM me.

88mk88
03-26-2008, 10:43 AM
That such a clean bay and your motor looks sick! Did you paint the exterior of the car to match the engine bay?

blake
03-26-2008, 10:48 AM
Exterior repaint is on the list after the car is running.

There were a few things that needed attention when it went in (a small dent in the targa, a chip out of the paint on the hood, discoloration in the front fascia and rear bumper, the upholstery of the driver's seat) but after sitting for so long there is inevitably going to be quite a bit more.

funky_monkey58
03-27-2008, 02:57 PM
Hey man what part of Mn are you from?

blake
03-27-2008, 04:35 PM
Living mostly in St Cloud right now, though I still crash at my Dad's place in Orono (west suburbs, Lake Minnetonka) quite a bit.

I've fallen out of touch with the local Supra guys (ever meet Glen K?). Nice to know there are still a few around.

Nice build thread, btw =)

blake
03-27-2008, 04:47 PM
Picture Not My Car (people seem to get confused easily when skimming threads, so I thought I'd make it clear)

Picture is from this post (http://www.supramania.com/forums/showpost.php?p=437391&postcount=108) in the Elite Engine Thread.

Everyone seems to have their own idea of how to do the PCV routing once the stock rats nest is ripped out. This is my current favorite. Though I'll have to do something slightly different as I'm retaining my ABS Block and Charcoal Canister.

http://eight.user.openhosting.com/~blake/supra/PCV Routing.jpg

GrimJack
03-27-2008, 06:26 PM
LOL - just noticed that engine has an HKS AND A TIAL bov. :)

blake
03-27-2008, 10:31 PM
Hedging his bets I guess =p

blake
03-27-2008, 11:42 PM
Parts!

First, the biggest part:

http://eight.user.openhosting.com/~blake/supra/cps_cover.jpg

Thanks arz! I don't intend for this to be the last part I order from you. Your contribution of your CNC skills is a real asset to this community. I can't wait to see what you do next.

And the next part:

http://eight.user.openhosting.com/~blake/supra/gumstix1.jpg

At this point you're probably wondering wtf in the world that thing is. Here's another image for scale (I didn't have a 1 or change... vending machine ate it all today):

http://eight.user.openhosting.com/~blake/supra/gumstix_w5.jpg

What it is (non-geeks can skip this part):
The brand is 'gumstix'. It runs a special version of linux on hardware which is essentially a PDA. It's about as powerful as an iPhone actually (1-2x as fast as an 266mhz PC, depending on the task) and runs the same type of CPU. This one has a 400mhz CPU, 64M of RAM, 16 of onboard Flash plus a microSD card slot which I've got a 2GB card for. It has USB-Host (so it can run other devices like USB/Serial adapters, Storage, Audio, Hubs and so on, rather than just talk to a computer as a USB-Client), 802.11b/g Wifi, Bluetooth, 3 Serial Ports, 10/100 Ethernet on an RJ45 connector, some general IO ports and probably other stuff I'm forgetting. And above all: It will run Python code well (my language of choice for some years now, Java before that, Perl before that, Scheme/Lisp before that, C before that... you get the idea).

Non-Geeks can start reading again.

Lots of people put a whole PC in their car (carputer). mp3car.com is probably the most popular site devoted to it. It's called mp3car because at the time it started that was the primary reason to have a PC in your car as even the aftermarket head units that would play MP3s off of a CD weren't common yet and the iPod + Car Adapter thing hadn't taken off. Now it's roughly the same stuff high end nav systems include. GPS Mapping, etc, etc. But I've actually kinda decided my iPhone fills those needs pretty well now.

The nice thing about the gumstix is its ridiculously low power consumption (http://docwiki.gumstix.org/Frequently_asked_questions/Heat_and_power#Basix_and_Connex_At_4.5v). At full tilt it's about a Watt. At idle it's more like a quarter Watt. So I can leave it on all the time and it won't drain my battery. The car battery probably discharges more on its own just sitting there.

It's going to listen in on the Motec M600 ECU. I'll probably just setup Serial Telemetry first as that will be easier, but I can get a USB device that listens to CAN as well which will let me log more samples per second. I might start experimenting with sending data back to the ECU at some point, but one step at a time.

I can program it (in a high level language) to do things the ECU shouldn't be bothering with, doesn't have the CPU power to do, doesn't have the interface to do, and so on. MoTeC's ADL fills alot of the same roles. It's FAR more configurable in a much more general way than the ECU with a great deal more resources. But for me (because of my programming experience) this gumstix is a lot more flexible.

Some totally random examples: turn on my iPhone, select the Wifi Hotspot called "Supra", it'll authenticate (I haven't settled on what mechanism to use yet), and then load the default web page and select 'Unlock'. Or see a telemetry readout (I can use javascript/etc to show live updating data). Or use it as a remote-start, or see how much time is left on our favorite 'turbo timer' function. Like I say, it's flexible, and it's a programming environment I'm very comfortable with (like some people on this forum are comfortable with a welder, or a CNC Lathe, f'ex).

There are a couple other devices, in particular, that this gumstix will use to interact with the outside world.

One is a 5.6" touchscreen LCD which is driven via USB (or Serial). Since it's USB based I can add more than one on a hub for more displays in different places for different purposes. There are also smaller versions if needed. This fills the display function of the ADL. It's been ordered, but hasn't arrived.

The second is a Ethernet/USB based 'Data Acquisition' device with several dozen IO connections like analog input, Digital IO and PWM, etc (this fills the control function of the ADL). I've had this for months and actually written quite a bit of Python code to handle it (personally ported from C, then totally rewritten so it's Python-esque because I hate C).

And a little USB-based 'dial'. Like a volume nob, with like 20 'detents' per rotation. I plan to stick this (and a couple buttons, probably) where the stock TEMS controller goes and use it very much like Audi's 98-2003 Trip Computer/Nav system, not quite so elaborate as BMW's iDrive controller. This is for functions I use while driving and don't want to be looking at a touch screen. I've ordered this, DHL tried to deliver it today and wouldn't leave it at my door without a signature. I swear I had a release for them like I do UPS and Fedex, oh well.

I'll give more details and photos of the latter few items Soon™.

funky_monkey58
03-28-2008, 02:28 AM
Nice to see another St.cloud supra owner. Sometime in the near future we should touch base. And if you ever want some work done locally feel free to give me a shout and I can give you hand.

speed
03-28-2008, 02:33 AM
Any pics of the whole car? the engine bay paint looks GORGEOUS. Looking forward to seeing the rest of it come together!

blake
03-28-2008, 10:43 AM
I scavenged up a bunch of photos and dumped them into iPhoto. Most of them are actually from when I had a page on SupraSport.com (I was tech support for his first online store, heh). I lost the HD that had the originals but the shrunk ones I pulled back off the server. Here are a few random samples of those.

It's been in storage so long now it's probably not an accurate representation ;)
http://3.141592.net/~blake/supra/supra340.jpg

Here's my LoTek gauge pod with AFR and EGT (I was bipolar about color at the time):
http://3.141592.net/~blake/supra/lotek.jpg

Here is a photo by Geoff Mohler of the Bushings from the Group Buy he did in 2003 (we used a mailing list to coordinate it, not a forum, weird huh?:icon_razz). I still have mine in a box in the home office:
http://3.141592.net/~blake/supra/fullmk3bushingkit.jpg

This is part way through pulling the engine for the rebuild I started and Glen K deserves massive thanks for helping me finish (I'd do it again if I had the choice to make again, but I was in over my head, the engine only made it 1300 miles):
http://3.141592.net/~blake/supra/mess.jpg

This is how we managed to dislodge the main pulley crank bolt the first time. After the short block was reassembled once it sat until the winter. Then I tried to dis-assemble it again with the propane heater going full blast, but it was not to be: I broke the bolt off in the crankshaft. Had to have a local machine shop remove it. Not a good day.
http://3.141592.net/~blake/supra/crankbolt.jpg

For some bizarre reason the check engine light on my instrument cluster didn't work. I had the whole thing apart trying to figure out what was wrong with a multimeter. I think I concluded that the PCB Trace leading just to the check engine light was bad. So I made use of the pre-89 headlight washer button for a replacement LED.
http://3.141592.net/~blake/supra/checklight.jpg

blake
03-28-2008, 11:16 AM
For those more interested in the carputer/gumstix aspect, I've started another thread over at mp3car.com that might end up with some relevant comments:

http://www.mp3car.com/vbulletin/linux/118079-gumstix-now-w-usb-host.html

blake
03-28-2008, 04:31 PM
A few more 'old' photos.

Here is where I installed my Greddy Turbo Timer. I rather liked this install. Though I'll be implementing that function in the gumstix in future so I'll be needing a replacement for this panel.
http://3.141592.net/~blake/supra/greddytt.jpg

This one highlights the material you need to remove to fit a standard 5.25" speaker in the rear speaker boxes. Instead of setting into the opening on the box, the speaker seals nicely to the top surface.
http://3.141592.net/~blake/supra/rearleftspeaker2.jpg

And I was quite pleased with how this mounting location turned out for the tweeters of the front separates.
http://3.141592.net/~blake/supra/tweeter.jpg

blake
03-28-2008, 08:57 PM
Here is the Data Acquisition Device (DAQ) I referred to earlier.

http://3.141592.net/~blake/supra/labjack2.jpg

You can see I have a few random lights dials and switches on the easy access pins on the left. Those are just for testing the feedback loop through my software. There are break-out boards connected on the right which include many more pins than the left and also duplicate pins on the left. Once finally installed I'll just have two D-sub cables as the end of the wiring harness, but for now the screw terminals are really handy.

The LJ is quite the device. The full specs are on their website ( http://www.labjack.com/labjack_ue9.php?prodId=26 ). The main selling point for me is the Ethernet connection so I don't have to worry about drivers. Every platform does TCP/IP, and I can write my own code against that.

Here's another photo that gives you a broader picture of how things are to be connected:
http://3.141592.net/~blake/supra/carnet1.jpg

Edit: The ethernet cables run off to my desktop switch for now. That way I can talk to the devices from the laptop to test code more quickly than installing it on the gumstix.

The little male to male USB adapter will end up being a hub for multiple devices. In this case it's only plugged into a USB/Serial adapter (I bought several of these little FTDI ones from Parallax (http://www.parallax.com/Store/Accessories/CablesConverters/tabid/166/CategoryID/40/List/0/Level/a/ProductID/379/Default.aspx?SortField=ProductName%2cProductName)) which in turn is plugged into one of the AEM Thermocouple Amplifiers. There are two TCs plugged into that.

The AEM TC Amps (http://www.aempower.com/ViewCategory.aspx?CategoryID=82) are pretty neat in that they provide both a serial data stream and a 0-5V analog signal for each of the 4 Thermocouples (that explains the wires going from the AEM TC Amp to the LabJack, another test channel) and for cheaper per channel than most TC Amps of any sort from MoTeC or even those meant industrial, or the lab, or whatever.

Alternatively:
http://www.motec.com/images/products/expansion/E888.jpg

I'm considering using a MoTeC E888 (http://www.motec.com/products/expansion/componen.htm) in place of the AEM TC Amps. The E888 feeds its data to the M600 via CANbus. The cause for reconsideration is that with the latest version of the M600's software I can send arbitrary telemetry data via the Serial telemetry stream. So the E888 sends its data to the M600, and the M600 rebroadcasts it (alongside other data) to the gumstix. This way the M600 knows all 6 (or 7) EGTs. The alternative was to wire the 7th channel via one of the analog outputs into the M600 so it would have an EGT feed. With the E888 I don't use an analog input on the M600, and I get several additional analog inputs + digital IO that can interact directly with the M600 or just be passed along to the gumstix.

SilverSupraT
03-28-2008, 09:29 PM
I'll be watching this thread like a hawk! It seems that you're going along the same lines as I'm trying to do with the computer setup. Although, you've thought it out quite a bit more! I haven't gotten into the details of any engine management stuff this far I've only focused on the creature comfort side. So I hope you don't mind me bugging you from time to time on how you've set up certain components!

I'll be looking forward to more updates!

blake
03-28-2008, 10:09 PM
So one of the most active guys on the forums is from MN (like me) running a Motec (like me) running on E85 (like me, well future me anyways).

And now the guy most interested in the electronics side of my project... shares my name? Weird =p

And ya, feel free to ask anything. I figured most of the SM crew wouldn't really be into the electronics stuff but I thought they might like to skim some generalized posts. Like for example I don't plan on posting python code here. Though, I might toss up a few samples just so people get an idea of what it's like.

And I will have more posts in regard to the more traditional stuff in future. It's just that's all up to SP right now with the car in their shop. So if you want photos, bug Larry ;)

blake
03-28-2008, 10:28 PM
Nice to see another St.cloud supra owner. Sometime in the near future we should touch base. And if you ever want some work done locally feel free to give me a shout and I can give you hand.

I added your AIM name to my list, and added my AIM name to my profile. Feel free to IM me any time. If I'm busy I'll just ignore you until I'm not =p

blake
03-31-2008, 06:37 PM
I hate DHL.

I was hoping to have a chance to tinker with the gumstix and make sure the phidgets drivers worked, but...

The USB-based dial for User Input will presumably be delivered Tuesday the 1st, despite having made its first appearance at that location on the March 25th.

It should arrive alongside the LCD though, so that's nice.

SilverSupraT
04-01-2008, 08:24 AM
*waits for post of LCD*

I'm curious what you went with as far as size and functions. I don't think I mentioned it earlier but I'm planning on using my computer for audio/video as well as climate control (engine management too obv.), have you looked into anything with using the stock thermocouples or setting up your own?

SupraMaster
04-01-2008, 10:17 AM
WOW! Finally something I can get into. Like you, I have extensive knowledge of language programming. I used to write my own games for my Atari computer, TI-85 calculator, and so on. I've been wondering if anyone would go as far as this, and you have, sir. I will watch this like a hawk.

blake
04-01-2008, 06:02 PM
*waits for post of LCD*

I'm curious what you went with as far as size and functions. I don't think I mentioned it earlier but I'm planning on using my computer for audio/video as well as climate control (engine management too obv.), have you looked into anything with using the stock thermocouples or setting up your own?

It's the 5.6" touchscreen model from ezlcd.com. The only info I really have on it is just what's on their site. So read that and you'll know as much about it as I do =)

It is NOT a normal VGA/DVI display. I recall in the manual that loading a full screen bitmap takes something like 90 ms (from the onboard MMC/SD card). So full motion video is out of the question.

But text, gauges, and line drawings should work nicely. If it's not responsive enough to give good feedback for RPM I'll probably wire something up with LEDs or somesuch (I don't really like the physical form of the motec shift light module).


have you looked into anything with using the stock thermocouples or setting up your own?

There are no stock thermocouples. They're all RTDs (0-5v Resistive Thermo Diode). I have a few grand worth of sensors I got from Motec that I'm going to use, far more numerous than the stock set.

jt2ma71
04-01-2008, 09:32 PM
Cool project :) I remember exchanging e-mail with you a while back about the MoTeC. I didn't know what a CAN bus was back then :D
Those nylon bushings. I can't believe it's been 5 years!! I have mine still in the original box.
~Ron

da89soup
04-01-2008, 10:33 PM
Nice to see another member actually close to me, Goodluck!!!

blake
04-01-2008, 10:39 PM
Cool project :) I remember exchanging e-mail with you a while back about the MoTeC. I didn't know what a CAN bus was back then :D
Those nylon bushings. I can't believe it's been 5 years!! I have mine still in the original box.
~Ron

*sound of digging through mail archives*

Ron, 2002, "Wow! ADL, cool! I am impressed already..."

Little did he know =)


Nice to see another member actually close to me, Goodluck!!!

Evidently people who live in Fargo have a different definition of "close" =)

blake
04-01-2008, 11:04 PM
Toys!

http://3.141592.net/~blake/supra/usbdial1.jpg

Fortunately DHL didn't return my USB Dial all the way to Cananada. I might give it a quick try on Ubuntu in VMWare tonight, but the gumstix is elsewhere right now so none of that. Actually I haven't even got cross compiling working for the gumstix yet and I don't have time for that tonight.

Here are the parts that came with the ezLCD (the bezel was extra):
http://3.141592.net/~blake/supra/ezlcd-all.jpg

Nevermind the weird looking screen, I have the protective film still on it:
http://3.141592.net/~blake/supra/ezlcd-front.jpg

And all the doodads on the back:
http://3.141592.net/~blake/supra/ezlcd-back.jpg

You can see the USB plug for scale. More postage when I get a chance to play.

SilverSupraT
04-01-2008, 11:23 PM
I'm jealous! I wish I had some of that stuff to play with right now.

So the LCD isn't going to be able to do any streaming video, eh? Was this LCD that much cheaper or were the ones that could handle it THAT much more expensive or did you just not care for video at all?

Thanks for the info on the Supra not having thermocouplers. I just assumed. Although the RTDs are basically the same thing though, right? Probably just less accurate?

blake
04-01-2008, 11:39 PM
So the LCD isn't going to be able to do any streaming video, eh? Was this LCD that much cheaper or were the ones that could handle it THAT much more expensive or did you just not care for video at all?

The limitation of the LCD is not the 'glass' (it's just some random Sony or Toshiba or whatever LCD). It's the USB/Serial communication used for the controller (well the controller probably can't handle either). And that USB/Serial based communication (rather than a traditional VGA/DVI port driven by a normal video card) was the main selling point for me. The gumstix itself is smaller and lower power than most video chipsets. It's not capable of driving a traditional display.

But it is capable of driving multiples of these, which is an option I want to leave open.


Thanks for the info on the Supra not having thermocouplers. I just assumed. Although the RTDs are basically the same thing though, right? Probably just less accurate?

From http://en.wikipedia.org/wiki/Resistance_temperature_detector

Resistance thermometers, also called resistance temperature detectors (RTDs), are temperature sensors that exploit the predictable change in electrical resistance of some materials with changing temperature. As they are almost invariably made of platinum, they are often called platinum resistance thermometers (PRTs). They are slowly replacing the use of thermocouples in many industrial applications below 600 °C.

From http://en.wikipedia.org/wiki/Thermocouple

In electronics and in electrical engineering, thermocouples are a widely used type of temperature sensor[1] and can also be used as a means to convert thermal potential difference into electric potential difference.[2] They are cheap[3] and interchangeable, have standard connectors, and can measure a wide range of temperatures. The main limitation is accuracy; Kieran Thomas' research shows that system errors of less than one degree Celsius (°C) can be difficult to achieve.

A K-type thermocouple is the most common. The kind I have are sheathed such to survive EGTs well. AEM sells RTD based EGT probes in fairly massive sheaths (I have 6, anyone buying?), but most other probes are K-Type thermocouples.

The main downside of TCs are how incredibly low voltage the signal is. Instead of just sending 5V and measuring the 0-5v voltage coming out the other side, you need a thermocouple amp (ballpark $100/channel or more) to bring it into a usable range. The AEM TC Amp is probably the best deal for more than a channel or two.

In addition to the physical properties and temperature range of the K-Type TC, the nice thing is that they all have the exact same electrical properties so every TC Amp set for K-Type TCs works for EVERY K-Type TC no matter who made it in what country and what sheath they put it in.

--------

And btw, VMWare rocks:
http://3.141592.net/~blake/supra/vmwareusbchoice.png

blake
04-01-2008, 11:56 PM
When you want it to run on anything (like a gumstix): Linux
http://3.141592.net/~blake/supra/phidget-linux.png

When you just want it to fucking work right now (new toy!): Mac OS X
http://3.141592.net/~blake/supra/phidget-osx.png

(edit) Oh and this is what the Linux version was supposed to look like:
http://3.141592.net/~blake/supra/phidget-osx-terminal.png

blake
04-11-2008, 01:27 AM
Finally had a chance to spend a few minutes with the display. The smaller models explicitly use the FTDI hardware and drivers which make the USB device show up just like your computer had another serial port. This larger one uses a different controller which itself supports USB. I had hoped they would emulate the FTDI chip somehow and I would get a virtual serial port on OSX and Linux. No such luck. So I'll be using a separate USB/Serial adapter from FTDI. Another bit of hardware I was hoping to do without.

In any case. I did play with the Windows Demo software (via VMWare, as usual) and thought you might find this image amusing:
http://3.141592.net/~blake/supra/ezlcd-logo.jpg

Big Wang Bandit
04-11-2008, 01:32 AM
Haha, very cool.

Nice build

SilverSupraT
04-11-2008, 02:01 AM
Cool man! MOAR updates! :)

blake
04-14-2008, 10:25 PM
link to gumstix mailing list archive entry (http://sourceforge.net/mailarchive/forum.php?thread_name=2E314E46-C496-4D0B-A044-934B54237B0A%40110110.org&forum_name=gumstix-users)

Short update. I think one of the expansion boards (the one that does the ethernet, wifi and microSD) might be defective. ::Grumble::

SupraMaster
04-15-2008, 06:57 AM
link to gumstix mailing list archive entry (http://sourceforge.net/mailarchive/forum.php?thread_name=2E314E46-C496-4D0B-A044-934B54237B0A%40110110.org&forum_name=gumstix-users)

Short update. I think one of the expansion boards (the one that does the ethernet, wifi and microSD) might be defective. ::Grumble::

That blows major monkey chinks. Best of luck to you, sir.

blake
04-16-2008, 07:14 PM
Unfortunately I don't think I have enough onboard flash to install the package to support Python without the use of the microSD card on the expansion board. So even though the connections to the display and input dial are USB, without Python that means no display or input device development.

Though I can do development on the laptop, it's always nice to prove to yourself it actually works on the intended platform.

SupraMaster
04-16-2008, 07:17 PM
True.

There's nothing quite like a good challenge to wrinkle the old noodle.

blake
04-17-2008, 11:41 PM
This is hopefully as arcane as this project's programming gets. I don't plan on making posts with hexadecimal values in them in future =)

I said I might post some Python code. I thought a simple example of the way I'm working with the display right now might be interesting. I have it connected to the mac via a USB/Serial adapter (0-3.3v TTL, not the usual voltages you get over your computer's connector, I had to order a different USB/Serial adapter for this).


saint-wifi:ezlcd blake$ python
Python 2.5.1 (r251:54863, Jan 17 2008, 19:35:17)
[GCC 4.0.1 (Apple Inc. build 5465)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import serial
>>> s = serial.Serial()
>>> s.baudrate = 115200
>>> s.port = "/dev/tty.SLAB_USBtoUART"
>>> s.parity = serial.PARITY_NONE
>>> s.stopbits = serial.STOPBITS_ONE
>>> s.bytesize = serial.EIGHTBITS
>>> s.open()
>>>
>>> from struct import pack
>>> v = pack("BBBB", 0x84, 0x00, 0xF0, 0x21)
>>>
>>> s.write(v)
>>>


That's loading the Python interpreter, setting the serial config values and opening the serial port.

Then I make a string 'v' that's 4 characters long, the format of which is represented by the four "B" (for byte, kinda) in the first argument. The next arguments are the values I want. The first is the 'set color' command, 0x84. Then two bytes each half describing the color I want. Then finally the clear screen command, 0x21.

s.write(v) sends that to the LCD and the screen turns red.

blake
04-21-2008, 05:53 PM
I wasted 2 days chasing an issue with the drivers for the UI-encoder crashing. After digging through their C code I think I know what it was. It would crash whenever I imported their drivers into any non-trivial codebase. So what I did is have my main program call a tiny little program that runs as a fully separate process for the sole purpose of watching the Phidget Encoder and relaying the results to the main process.

Short version: Crashy drivers, still don't know what the problem was, but I've worked around it and moved on in a not terribly elegant but nonetheless kinda neat way.

So now I've gotten a chance to work on what I meant to be doing 3 days ago before I got hung up on random crashes (I really need to find the charger for the real camera. The iPhone has a really hard time auto-exposing for this display).:
http://3.141592.net/~blake/supra/ezlcd-gauge1.jpg

Each of those bars fills and empties in response to their appropriate channel. The top one is a potentiometer attached to the LabJack (via Ethernet), and the next 5 are the AEM Thermocouple Amp (via Serial->USB).

The AEM values are out of whack because I have different scales on the gauges to test what happens when the values are too low, too high, or unavailable.

This was the simplest gauge style I could think of (it's just two rects, one filled, one not) as a proof of concept. Prettier stuff to follow.

SupraMaster
04-21-2008, 06:18 PM
I wasted 2 days chasing an issue with the drivers for the UI-encoder crashing. After digging through their C code I think I know what it was. It would crash whenever I imported their drivers into any non-trivial codebase. So what I did is have my main program call a tiny little program that runs as a fully separate process for the sole purpose of watching the Phidget Encoder and relaying the results to the main process.

Short version: Crashy drivers, still don't know what the problem was, but I've worked around it and moved on in a not terribly elegant but nonetheless kinda neat way.

So now I've gotten a chance to work on what I meant to be doing 3 days ago before I got hung up on random crashes (I really need to find the charger for the real camera. The iPhone has a really hard time auto-exposing for this display).:
http://3.141592.net/~blake/supra/ezlcd-gauge1.jpg

Each of those bars fills and empties in response to their appropriate channel. The top one is a potentiometer attached to the LabJack (via Ethernet), and the next 5 are the AEM Thermocouple Amp (via Serial->USB).

The AEM values are out of whack because I have different scales on the gauges to test what happens when the values are too low, too high, or unavailable.

This was the simplest gauge style I could think of (it's just two rects, one filled, one not) as a proof of concept. Prettier stuff to follow.

I am enjoying your progress so far. I like the fact that you have chosen to test out the functions instead of building the programming first without testing. I can't wait to see more progress.

blake
04-21-2008, 11:27 PM
More Progress:
http://3.141592.net/~blake/supra/ezlcd-menu1.jpg

The real camera is elsewhere at the moment, so you get blurry stuff for now.

Those are menu items, the phidget scrolls through them and selects them, press to activate. You can kinda see where I'm going with the user interface. However the concept hasn't totally solidified yet. If anyone has any feedback on that aspect I'd love to hear it, and soon.

SupraMaster
04-22-2008, 06:28 AM
More Progress:
http://3.141592.net/~blake/supra/ezlcd-menu1.jpg

The real camera is elsewhere at the moment, so you get blurry stuff for now.

Those are menu items, the phidget scrolls through them and selects them, press to activate. You can kinda see where I'm going with the user interface. However the concept hasn't totally solidified yet. If anyone has any feedback on that aspect I'd love to hear it, and soon.

My major question as far as this goes, is : How dynamic can your interface be and still run reliably?

blake
04-22-2008, 02:41 PM
My major question as far as this goes, is : How dynamic can your interface be and still run reliably?

My answer is: Very.

Are you doubting my mad coding skillz? =p

Seriously though, Python is really great about exception handling without crashing. I'm quite glad to have moved those C drivers out of my main code base so my main program is extremely unlikely to crash in a way that can't be caught and recovered. And even if the Interpreter does crash I'll have a watchdog program reset it.

Of course it's not magic. I do have to write the error handling code, but the code that handles the LabJack and other modules is already very robust. Once the display/interface code stabilizes some I'll start adding more error handling to it.

P.S. You don't need to quote a 3 paragraph post with images in your consecutive reply =p

SupraMaster
04-22-2008, 02:49 PM
The reason for the question was to find out how far you could take it without any problems. The reason I replied with the previous post is because, although it's early in the programming, the set-up looks archaic. No offense if any is somehow implied.

There are so many places you can take this, due to your selection of Python, that I'm not sure how far is too far.

Mike

blake
04-22-2008, 03:09 PM
It looks "archaic" because in a way it is. There's graphics library built into the display is very rudimentary. I'm building my own library on top of it in Python by drawing rectangles and lines and so on. But on top of that layer I'm adding another layer of intelligent elements like gauges.

Here's the code to add the top gauge:

ain0Gauge = ezlcd.hGauge(self.w.ez, 10, 10, 180, 10)
ain0Gauge.min = 50
ain0Gauge.max = 100
ain0Gauge.channel = self.w.chanForName("ain0")
ain0Gauge.show()
self.w.ez.elements.append(ain0Gauge)

Here's the code to add the menu:

for i in range(10):
self.w.ez.menu.addItem("Menu Opt%s" %i, None)

So when I added the code for the tick marks and the numeric readouts (I haven't posted a photo since those changes) all the gauges get that feature.

Forgive me if I'm wandering back and forth between too obscure/technical and borderline patronizing ;) I'm not real sure of your background -- actually I just scrolled up and reread your first post in this thread. You'll recognize the drawing routines as not entirely dissimilar to your TI-85 or your Atari. But the code behind it is a totally different thing.

P.S. I actually want to keep it fairly rudimentary. I don't want to be interacting with a traditional desktop window environment or even a touch screen while I'm driving. I'm basing the interface loosely on Audi's Nav/Trip computer interface from their 98-2003 models.

SupraMaster
04-22-2008, 03:20 PM
My experience with the TI-85 and the Atari computer were just minor examples. I understand the code you have presented, that's not a problem to read at all.

I like the fact that you are simply using rectangles and ticks. There's nothing more that you need, to convey the gauge readouts so they are understandable.

Now you can just dress it up a little, throw readout labels on it, and give it a test.

blake
04-22-2008, 03:32 PM
Now you can just dress it up a little, throw readout labels on it, and give it a test.

I'd show you a photo of just that, but I'm at the office right now =)

SupraMaster
04-22-2008, 03:37 PM
I'd show you a photo of just that, but I'm at the office right now =)

I can't wait to see it.

I'm gonna head out for the day, so I look forward to seeing the update when I return @ 4 A.M.

blake
04-22-2008, 08:24 PM
http://3.141592.net/~blake/supra/ezlcd-ticks-numeric.jpg

Don't know if I'll get any coding in before I pass out tonight. Long day.

blake
04-22-2008, 11:54 PM
I found the other camera. I'll have to play around with the settings a bit to see what comes out best, but a quick stab in the dark is still better than the iPhone:
http://3.141592.net/~blake/supra/ezlcd-realphoto.jpg

Rough draft of a different gauge (there might be a better name for it but I'm calling it a Ramp Gauge). More suitable for at a glance viewing.

If anyone has any suggestions for different readouts I'd love to hear them now while I'm still tinkering with the drawing (and it's fresh in my mind). I can technically create any image on the screen but some are easier than others. So I may not end up doing exactly what you suggest but with luck it'll spark an idea for something practical.

IJ.
04-23-2008, 12:03 AM
Blake: Can you give an example of what you'll actually use the Gumstick for?
(might have to dumb it down a bit I'm old)

blake
04-23-2008, 01:43 AM
If I didn't have the gumstix with its display(s) I'd be installing an ADL. One of the data channels I haven't been demonstrating is the one from the M600. Since the M600 has been sitting in a box at SP I haven't had a chance to test with it.

The Gumstix + LCD + LabJack all together cost maybe half (or with the dollar tanking maybe more like a third) the price of the ADL. Since the ADL was on the plan from the start I can pretty much add displays until I run out of dash/gauge cluster space and still come in under the older budget.

I get a whoooole lot more flexibility even in just the ADL-like features. Like say, I can do as many PID controls as I like, I have no limit of 'channel maths', and so on. Not that I'd recommend you ditch your ADL. As complicated as it is to set up, it's still configuration of a preprogrammed system that someone's already thought through. If all I wanted was feature parity with the ADL this would be a monumental waste of time.

The thing I really like about the gumstix is, aside from not having a monitor, keyboard, and mouse: It's just a computer. It has USB, Ethernet, Wifi, and Bluetooth just like a normal computer. So my programming can interact with the world as if it was running on a pretty normal computer (my experience with python code is usually nested so deep inside an existing framework it doesn't actually interact with a normal KB/Mouse much anyways).

One of the random examples I gave earlier of what that means is that I can run a web server on the gumstix, which is acting as a WiFi hotspot. I can then display additional information on a web page on any web browser. My phone (an iPhone) has a pretty decent web browser. I can add controls to that web page. One of them could be 'unlock doors'. I press that button, the gumstix tells the LabJack to set channel FIO5 'high' for 0.2 seconds. FIO5 is connected to a relay bypassing the unlock switch. Tada: remote keyless entry from my phone.

Or remote start, or a engine cool down (turbo timer) function, or have the windows roll up, lights turn off, and doors lock whenever my phone is out of bluetooth range. And reverse that process when I come into range. Now it's the Mercedes Proximity Key thing (I think a few other makes have added that feature now).

For right now though it's just a fancy gauge. But I'll push that too. I plan to have a whole bunch of different screens I can select to show me different sets of readouts. All 6 EGTs side by side on one screen. A normal screen with RPM and ground speed (constantly calibrated against the GPS?) and an 'alert' space. Any channels that get out of range will pop up as a warning.

All of these feature take time to implement. But that's what hobbies are for =)

I was originally going to just use the gumstix to stay on all the time consuming minimal power and then wake a 'normal' computer (Mac Mini) from sleep mode (or boot entirely) when required.

But then they introduced a model with "USB-Host" so devices (like USB/Serial Adapters) can connect to it, instead of it just being the 'client' of a normal computer.

The gumstix also couldn't really display anything. But there are now displays (like the ezLCD you keep seeing) that I can drive with a USB port. Since the gumstix can now drive USB devices I can run as many of those as I like. They're actually touch screens too by the way, I just plan on the first one going in my gauge cluster and I don't expect to be reaching through my steering wheel to press buttons while driving.

Hopefully that gives a few more concrete examples of where I'm going with this. I wandered around a bit to try to touch on a few different aspects. Let me know if you want more on anything in particular.

I guess I tend to gloss over the specific functions right now because there have been a bunch rattling around in my head for a long time now and I really don't know which ones I'll implement first. "No Promises" =)

But I do love to hear new ideas. Even if I never implement them it's fun to work through if they're even possible, and then how I'd go about making it work. So speak up if you have any =)

P.S. Well that stab in the dark turned out to be pretty lucky. I can't seem to duplicate that clarity again. It's just a Canon SD110 from a few years ago. I wish atleast one of my buddies into photography was local still.

I end up looking at these photos on the computer for a while and then glance back at the actual display and it amazes me how bright and crisp it is =p
http://3.141592.net/~blake/supra/ezlcd-100.3.jpg

SupraMaster
04-23-2008, 08:12 AM
I was just thinking, after reading your progress of course, that it would probably be easier to use the speed sensors on the car, rather than trying to screw with the GPS. Just a thought.

IJ.
04-23-2008, 10:37 AM
Blake: (ummm was that the dumbed down version?) ;)

Sounds perfect for my car!

NOT a big fan of the MoTeC displays and being able to pick and choose exactly what I want to display would be a huge benefit for me.

After you get it working I'd be very interested in duplicating it (or having you duplicate it for me I mean, me being an electronics Neanderthal)

blake
04-23-2008, 05:04 PM
I was just thinking, after reading your progress of course, that it would probably be easier to use the speed sensors on the car, rather than trying to screw with the GPS. Just a thought.

You'd be surprised. Just plugging something like this (http://www.gpscity.com/item-garmin-gps-18-pc/oem18pc.htm) into one of the serial ports gives me a data stream that includes my ground speed. It's something I've already tested with my Garmin eMap.

Where as the Vehicle Speed Sensors need to be attached to a frequency counter (not just a voltage input) and then need to be calibrated (how many 'clicks' per mile). Not real hard either, but more work to get right.

I expect to use both though. The GPS only updates once a second. I'll probably write the code to calibrate the VSS against the GPS and then just leave it self-calibrating all the time.

I just thought I'd point out how easy the GPS part really is ;)

blake
04-23-2008, 05:32 PM
Blake: (ummm was that the dumbed down version?) ;)

Sounds perfect for my car!

NOT a big fan of the MoTeC displays and being able to pick and choose exactly what I want to display would be a huge benefit for me.

After you get it working I'd be very interested in duplicating it (or having you duplicate it for me I mean, me being an electronics Neanderthal)

There's not much to the 'electronics' of it. It's all software. Plug this into that, and a few bare wires here and there. Serial line between the Motec and the Gumstix. USB or Serial between the Gumstix and the Display.

As I develop the software I'll try to keep things so the Motec and Display software modules run sanely on their own. It's easy to let things get heavily interdependent but I've done a pretty good job of avoiding that so far. Some of the 'screen shots' I've posted don't show values for the Thermocouples because I just unplugged the AEM TC Amp, and it handles it cleanly.

I've had ideas about configuring my gauge pages in text files that get read by the main program at run time. So if I want to add a page with a different set of gauges I don't need to edit the code. No promises of course, but that would certainly make things more configurable for you.

Chronus24
06-11-2008, 11:24 AM
I wish atleast one of my buddies into photography was local still.


I have a lens that can take that picture from here, just hold the screen up a little bit.:biglaugh: