The CANary project

My Nissan Leaf Forum

Help Support My Nissan Leaf Forum:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.
Are you using two of the TFT PROTO Boards inside the case,
as you show being used in the breadboard, or will you be using
just two of the displays?

For scale, the display is about 2.8 inch diagonal, I believe.

I will enjoy following your project, and making one of myself.

I have most of the hardware, I suspect, except for the Displays.
Should I order those now, or wait until the circuit board
is tested?

I am anxious to see close-up pictures of the enclosure, both
before and after your touch-up work.

Splendid Work!!!
 
garygid said:
I ordered the displays.

Perhaps you can send me the "v1" schematic
and board layout to look over?

It will be great to see how it looks (and fits)
in your custom enclosure.
Here's a screenshot of the schematic. UPS says the enclosure is scheduled for delivery today - crossing my fingers... I am half expecting to find I got the units screwed up and it is 7cmX3cm instead of 7"x3" :)
 

Attachments

  • CANary_sch.jpg
    CANary_sch.jpg
    132.4 KB · Views: 100
How do the two displays, and their touch screens get connected?

I see the OBD cable connection, two CAN interface chips,
a USB port, measurement of the 12v, and some power supply stuff.

Good luck on the enclosure. :D
 
garygid said:
Does the RS (pin 8) of the CAN chip default to a firm pull-up state?
I do pull the outputs up in the code to prevent transmit, but you can just float the rs pins by pulling the jumpers. The rs pin is in series with the vp 230 can bus driver so if you don't provide a path to ground it can't accidentally transmit.
 
garygid said:
How do the two displays, and their touch screens get connected?

I see the OBD cable connection, two CAN interface chips,
a USB port, measurement of the 12v, and some power supply stuff.

Good luck on the enclosure. :D
Both displays are on one SPI interface. Each gets its own CS pin. I put the LED driver (2n2222 NPN at the top) on a pwm output so I can control the brightness. Am hoping to find a message on the canbus indicating the condition of the cars light sensor so I can dim the display whenever the LEAFs built-in instrumentation is dimmed. Worse case, I can add a cadmium sulphide cell to one of the spare analog inputs,

For the touch screen, I connect the X&Y in series (X- on the left to X+ on the right and similarly Y- on the left to Y+ on the right). Then I just connect the remaining connections (left_X+,left_y+,right_X-,right_Y-) to four of the analog inputs (16,17,19,20). Drive X+ to 1 and X- to 0 and read Y, then dirve Y+ to 1 and Y- to 0 and read X. Ends up decoding the two screens to two of four quadrants but it easy arithmetic to convert to more meaningful X&Y coordinates. There is a calibration routine you need to go through at least once to get good accuracy. Was kindof noisy so I had to filter a bit. I also added interrupt support so the routine is only called when you actually touch the screen (no wasted power or CPU time). Right now all it does is bring up a screen configuration overlay to let you select which display you want on each screen.
 

Attachments

  • configure.jpg
    configure.jpg
    143.6 KB · Views: 65
Enclosure came in today. Finish is rough but otherwise exactly like I designed it. Here are a few pics showing the "pre-finishing." Looks like it will clean up nicely - despite the rough outer surface it is smooth durable plastic underneath.
 

Attachments

  • compare.jpg
    compare.jpg
    117.1 KB · Views: 57
  • interior.jpg
    interior.jpg
    111.6 KB · Views: 57
  • birdie.jpg
    birdie.jpg
    107.3 KB · Views: 57
Very, very nice enclosure, better than I expected.

Your enclosure even includes the special mat-surface finish
to minimize reflections, excellent.

Did you have a choice of colors, like black or dark blue?

How is the display board held onto the molded pins?

Could you have molded them with a slot and a slight bulge
so that the board would just snap onto the pins, held in place?

If you had ordered several enclosures, or re-order the same
part, would you get a better price?

Again, very nicely done!!!
 
It appears that you used this material for your enclosure:

http://www.shapeways.com/materials/strong-flexible" onclick="window.open(this.href);return false;

For some reason, the white is the least expensive color.

Did you receive your PC board yet?

I intend to put a CANary together to better follow your work,
and have a working model to demonstrate to others.

Cheers, Gary
 
vegastar said:
I'm very interested in this. Will the source code be available?

Yes. Once it is a little more mature, I will share a link to the source code, schematics, parts list, board, and enclosure for anyone who wishes to build or expand upon this.

A few have asked in PM if I would sell completed units and unfortunately I cannot - just too much time involved - but am happy to share my files.
 
Yup. It's referred to as WSF (White Strong Flexible) in the forum and is the most popular due to its low cost but excellent properties. It is laser-sintered nylon and after sanding the back, it has a smooth, almost wet, feel - kindof like Teflon. If the rough finish was more uniform, I would have kept it as feature, but as it is it has layered appearance from the manufacturing that I don't want to keep so I'll be sanding it down.

I sent the PC board just before Chinese New Year and paid for the cheapest shipping method so it may be a while before the PC board arrives.

garygid said:
It appears that you used this material for your enclosure:

http://www.shapeways.com/materials/strong-flexible" onclick="window.open(this.href);return false;

For some reason, the white is the least expensive color.

Did you receive your PC board yet?

I intend to put a CANary together to better follow your work,
and have a working model to demonstrate to others.

Cheers, Gary
 
I really didn't expect my alignment pins to come out and figured I would have to cut/file them off but went ahead and put them in (just a mouse click or two). However, they work nicely and the rough finish adds the right amount of friction. I think a self-tapping nut would work to permanently attach it. Now I wish I added the pins for the PC board mount. The snap in idea is a good one, too. If I go for Rev2 I will consider changing to that.

Good question about the multiple order combining. I got the impression that I was paying per cm3 of deposited material. However there may be a fixed cost on top of that that could be saved. I'll look into it next time.

garygid said:
Very, very nice enclosure, better than I expected.

Your enclosure even includes the special mat-surface finish
to minimize reflections, excellent.

Did you have a choice of colors, like black or dark blue?

How is the display board held onto the molded pins?

Could you have molded them with a slot and a slight bulge
so that the board would just snap onto the pins, held in place?

If you had ordered several enclosures, or re-order the same
part, would you get a better price?

Again, very nicely done!!!
 
How do you plan to use the 6 supports that you included
on the back wall, presumably for the PC board?

In the v2 enclosure, you might want to consider adding:

1. A cutout to mount the USB full size port, and two screw holes.
2. A cutout to insert a mini-USB plug into the Mbed board.
3. A 9/32" hole, or "knockout", on the side for a cable from the OBD port.
4. A 0.25 inch hole, or knockout, for one switch on the side,
positioned so that there is room for the switch body
and possibly solder contacts on the inside.
5. Some small (1/16" perhaps) heat ventilation holes on each side,
perhaps 2 or 3 near the top edge, and the same near the bottom edge.
6. If any edge is too flexible, add a bit of thickness near/at the edge.
7. Make the non-bottom edges slightly rounded instead of "sharp" edges.

A "knockout" would really be a hole/slot that is easy to cut
out with a sharp "hobby" knife, but still a flat outer surface
for cosmetics. So, a less-thick area surrounded on the inside
surface with a "groove" (wall perpendicular to the surface on
the outside of the groove, but something like a 45 degree wall
on the "inside" edge of the groove) that goes almost all the
way through to the outside surface. Holding it up to the light,
one should be able to see the "cutout" location easily.

Super work.
Is it easy to mount the two displays, connect them to
the breadboard, and take a "real" picture?

Thanks for your continued efforts, Gary
 
I realize that you do not yet know enough about the CANary's
functions, features, or future possibilities, but...

If we manage to find a way to offer a CANary Kit,
or a Built and Tested CANary, who might be interested?

Some Features (my wording might not be perfectly correct):

1. The programming is done on-line, with no special software needed.
2. Updating the CANary firmware is done by downloading a file, and
a simple copy and paste to the Mbed's "flash drive" (that appears on
your computer when you attach the supplied mini-USB cable).
No special hardware needed.
3. "All" the EV-CAN and CAR-CAN messages can be logged into
CAN-Do compatible ".alc" files on your USB flash drive, or
onto an SDHC card (when in a suitable USB adapter).
These files have a yymmddnn (date and sequence number)
file name, which provides "Black-Box"type data recording,
holding data for days, weeks, or even months.
4. There is a Real Time Clock, and messages are usually
time stamped to about a milli-second, with Date-Time
data added. The RTC has a coin-battery backup.
5. The over-abundance of color graphical displays (2) makes
experimenting with data much easier. 240 x 320 pixels.
For example, a real-time graph of kWh per mile or braking
energy, or both, would presumably be possible.
6. Both screens have touch-input capability.

A Wish List (might be possible, or might not):
1. I am hoping to add simultaneous GPS logging capability.
 
garygid said:
How do you plan to use the 6 supports that you included
on the back wall, presumably for the PC board?
Yes, those are for the PCB. I will add pins to them like I did for the displays on the next rev.
garygid said:
In the v2 enclosure, you might want to consider adding:

1. A cutout to mount the USB full size port, and two screw holes.
2. A cutout to insert a mini-USB plug into the Mbed board.
3. A 9/32" hole, or "knockout", on the side for a cable from the OBD port.
4. A 0.25 inch hole, or knockout, for one switch on the side,
positioned so that there is room for the switch body
and possibly solder contacts on the inside.
5. Some small (1/16" perhaps) heat ventilation holes on each side,
perhaps 2 or 3 near the top edge, and the same near the bottom edge.
I didn't add any holes because drills work really well for that, but the USB punchout is a good idea - I could put several options (back, top, side). Also I may do something for ventilation as you suggest since an array of holes would be tedious to drill and I could do something that looks nicer. For the OBD cable, I intend to come out with a flat flex cable so it can slide easily under the trim so no need for a hole for that:
flextrim.jpg
This isn't the flex cable I intend to use - just a random piece I had lying around. I have a 20 conductor flex with zif connectors ordered for this project (~$5).

garygid said:
6. If any edge is too flexible, add a bit of thickness near/at the edge.
All the walls are .125" thick and seem pretty sturdy.
garygid said:
7. Make the non-bottom edges slightly rounded instead of "sharp" edges.
done
garygid said:
A "knockout" would really be a hole/slot that is easy to cut
out with a sharp "hobby" knife, but still a flat outer surface
for cosmetics. So, a less-thick area surrounded on the inside
surface with a "groove" (wall perpendicular to the surface on
the outside of the groove, but something like a 45 degree wall
on the "inside" edge of the groove) that goes almost all the
way through to the outside surface. Holding it up to the light,
one should be able to see the "cutout" location easily.
great suggestion - I will do that.
garygid said:
Super work.
Is it easy to mount the two displays, connect them to
the breadboard, and take a "real" picture?
sure. I didn't want to mess with the breadboard setup while I was debugging so I used a display I accidentally dropped on the concrete floor for the previous photo. I don't have a PCB to go inside yet but I can put the two displays in.
garygid said:
Thanks for your continued efforts, Gary

I discovered a few other things I need to address in the next rev.
1) the surface behind the console is not flat. The enclosure rocks on two corners with about 3/16" gap on one corner when the other three are touching. Adding feet so they can be filed down to rest flat
2) displays are not quite aligned with the opening - need to shift the alignment pins a bit (25mils)
3) modified the shade to extend further and clear the console lip
4) adjusted the display angle
Here's what I've got so far:
Rev2a.jpg
 
Back
Top