<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Brian,<div><br></div><div>OK, let's concentrate on hardware first.<br><div><br></div><div>So far, as far as I've got is prototyping something using:</div><div><br></div><div><ol class="MailOutline"><li>UBW32 (<a href="https://www.sparkfun.com/products/9713">https://www.sparkfun.com/products/9713</a>) PIC32MX795 development board.<br><br></li><li>MCP2551 CAN controller (<a href="http://www.microchip.com/wwwproducts/Devices.aspx?dDocName=en010405">http://www.microchip.com/wwwproducts/Devices.aspx?dDocName=en010405</a>).<br><br></li><li>FT232RL based converter (<a href="https://www.sparkfun.com/products/718">https://www.sparkfun.com/products/718</a>).</li></ol></div><div><br></div><div>The FT232RL was just wired to the first async port of the PIC32, and the MCP2551 connected straight to the PIC32 as well using the normal CAN controller ports.</div><div><br></div><div>That was the prototype. For production, I don't think we need the FT232RL at all. We should be able to use the PIC32 USB and have it present as a serial port to the host (windows, linux, osx, Android?). I have played around some with the PIC USB library (I built a little HID keyboard media player for my car - <a href="https://github.com/markwj/hidmedia">https://github.com/markwj/hidmedia</a>). But, I haven't spent much time with the PIC32 USB framework as a serial port and have no idea how the driver support works.</div><div><br></div><div>Components wise, I reckon we need:</div><div><br></div><div><ul class="MailOutline"><li>USB connector, and support components</li><li>5V-3.3V power regulator</li><li>PIC32MX795 and support components</li><li>MCP2551, and support components</li><li>DB9 connector, either "standard" CAN-on-DB9 or OVMS-on-DB9 pinout</li><li>Switch for program/run mode</li><li>ICSP pins</li><li>Case</li></ul></div><div><br></div><div>I suggest to power from the USB port, not from the vehicle side 12V. The MCP2551 (and CAN bus) is 5V, but I think can be powered directly from the USB port. The PIC32MX795 is 3.3v. But, both are tolerant and seem to be able to be inter-connected without any issues (the MCP2551 trigger level is <3.3V, and the PIC32MX795 is 5V tolerant on the CAN RX pin).</div><div><br></div><div>I've used these products:</div><div><br></div><div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;"><div><a href="http://www.can232.com">http://www.can232.com</a></div></blockquote></div><div><br></div><div>and they have a simple serial API that I am already using with my CAN-RE-TOOL:</div><div><br></div><div><blockquote style="margin: 0 0 0 40px; border: none; padding: 0px;"><div><a href="http://www.can232.com/docs/canusb_manual.pdf">http://www.can232.com/docs/canusb_manual.pdf</a></div></blockquote></div><div><div><br></div><div>I've discussed with the factory in China, and it seems fairly simple. They have done similar projects before, using the case shown below. Plenty of room and we can either use a USB type B socket, or type A plug on the end of a soldered-in cable. The PIC32 is definitely overkill, but given the price of the chip, I don't think it is much of an issue - it will give us plenty of room to do whatever we need.</div><div><br></div><div>Regards, Mark.</div><div><br></div><div><img id="7e3acb46-258a-49a3-add4-2ecca66e3435" height="415" width="460" apple-width="yes" apple-height="yes" src="cid:186AE74B-591D-4CD7-9F07-251B11F3DAC8"><img id="62d545c8-1da6-4117-ad89-f78376880acb" height="335" width="290" apple-width="yes" apple-height="yes" src="cid:0399A057-4127-4721-8F7B-84E5B548BACF"><div><br></div><div><br><div><div>On 1 Sep, 2013, at 6:41 AM, HONDA S-2000 <<a href="mailto:s2000@sounds.wa.com">s2000@sounds.wa.com</a>> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite">Hi Mark,<br><br>I would be interested in developing USB firmware for the PIC32 that meets your CAN-USB adaptor goals. I have experience writing USB firmware for multiple USB Device classes (not just plain serial), including working with the Microchip USB Stack.<br><br>I purchased the OVMS v2 with the goal of learning more about CAN signaling on my Roadster. I haven't actually used the device because I'm not primarily interested in getting a SIM card and paying for network access. I wanted to support your efforts at making a hardware platform, and I figured that I could just write my own custom hardware for recording and analyzing CAN messages. Unfortunately, as you're probably aware, the OVMS v2 is not immediately useful for my project. Also, I can imagine that you know what it's like to have more ideas than time.<br><br>The only question is how to incentivize the effort. It would be ideal if you could pay for the PIC32 USB firmware development, but I can see how that might not be within your budget. Another alternative is to just send me the new platform, and I might be able to make some progress. On that note, I would be willing to review the hardware designs before you make prototypes, just to see if I think there is anything missing in the hardware circuitry. Since I have experience designing USB platforms based on the PIC and other embedded processors, it might be worth having a second set of eyes look over the design. Also, with my combined hardware and firmware design experience, I think I have a particularly good sense of what makes a good hardware platform for particular firmware projects.<br><br>Let me know what you think.<br><br>To reiterate, I'm willing to look at the hardware design without charging anything. The reward for me will be enough to know that a new platform that I like will be made. As for firmware design, I'm hoping that some sort of compensation can be arranged, because that is much more effort. However, I think we may be able to work something out that is mutually beneficial.<br><br>Brian Willoughby<br>Sound Consulting<br><br>p.s. Regarding my existing OVMS v2, I would actually enjoy having the SIM card working for when I charge on the road, but it's just not a priority.<br><br><br>On Aug 28, 2013, at 18:25, Mark Webb-Johnson wrote:<br><blockquote type="cite">P.S. What I would really like to do is get the OVMS CAN-USB adaptor working, and then give those out in large quantities. The more people decoding vehicle CAN communications, the more cars become open vehicles. But, to do that I need some one / people to step forward and help with this. The China manufacturer is standing by and asking me for the circuit diagram, but I've got too much on my plate at the moment to take on the CAN-USB hardware and firmware as well. Using a PIC32 microprocessor (with built-in USB support), and MCP2551 CAN controller, we can do this for a materials cost perhaps around US$30 (vs US$150 retail for the cheapest commercial units). I'll send out a separate 'appeal' for this, and see if anyone will step forward to help.<br></blockquote><br><br>_______________________________________________<br>OvmsDev mailing list<br><a href="mailto:OvmsDev@lists.teslaclub.hk">OvmsDev@lists.teslaclub.hk</a><br>http://lists.teslaclub.hk/mailman/listinfo/ovmsdev<br></blockquote></div><br></div></div></div></div></body></html>