Active Topics

 


Reply
Thread Tools
Posts: 20 | Thanked: 1 time | Joined on Apr 2008
#41
I use this to build a display for my car, since i dont have obd2 port. i started discussion at http://www.internettablettalk.com/fo...ad.php?t=19671

Currently i have Flash talking to Arduino using python proxy. havent gotten this to work with AS2, but AS3 works. there are definitely problems with Flash > Firmata > Arduino. i`m trying Actionscript2 to get working with xmlsocket, since i`m pretty new to AS3 and dont have time to learn it..

Bluetooth version is also welcome, but for now there are too many problems with current setup to deal with..
 
cmdowns's Avatar
Posts: 100 | Thanked: 13 times | Joined on Mar 2008
#42
Originally Posted by valtersboze View Post
I use this to build a display for my car, since i dont have obd2 port. i started discussion at http://www.internettablettalk.com/fo...ad.php?t=19671

Currently i have Flash talking to Arduino using python proxy. havent gotten this to work with AS2, but AS3 works. there are definitely problems with Flash > Firmata > Arduino. i`m trying Actionscript2 to get working with xmlsocket, since i`m pretty new to AS3 and dont have time to learn it..

Bluetooth version is also welcome, but for now there are too many problems with current setup to deal with..
Am I correct in interpreting that you are trying to make a diy obd for your car?
 
Posts: 20 | Thanked: 1 time | Joined on Apr 2008
#43
well kind of.. part of analog inputs will be bound to car ECU pinouts, other part to external sensors, since i haven`t got oil pressure and temp sensors on car by default..
 
cmdowns's Avatar
Posts: 100 | Thanked: 13 times | Joined on Mar 2008
#44
I have finally succeeded in replicating D-rock's project. I used his Python code with no changes other than reducing the display size to half. And I used Fanoush's drivers, specifically his ftdi_sio.ko and usbserial.ko drivers. In addition, I had to download and install pySerial. This was all almost exactly as D-rock had specified.

I connected my Arduino Diecimila to both my laptop running Ubuntu and my n800 with identical results. To work on the n800, i used the mini-usb to type A usb OTG adapter that jolouis produced .

Instead of using D-rock's Arduino code as-is, I modified it to control an h-bridge chip that is controlling a couple of small fa-130 motors in a gearbox made by Tamiya. The code in incredibly simple, so I won't bother to post it. But if anyone wants to see it, just let me know.

Soooo. . .now I want to do a couple of things. I want to replace the serial cable with a Bluetooth connection, most likely using a bt device made by Sparkfun, such as their DIP module or their Blue SMiRF.

And I want to alter D-rock's python code to register a couple more buttons, specifically the L and R buttons on the n800's d-pad.

At this point I'm just fishing for useful info. For example, can anyone tell me what it will take for the n800 to send the serial data to the Arduino via BT? And can anyone experienced with Pygame tell me how to modify the code to recognize the L and R buttons on the d-pad as event cues?

I'd like to thank everyone who has contributed to this thread, as well as all the other helpful users in this forum. In particular, I'd like to thank D-rock for posting the step-by-step info that allowed me to replicate what he had had already done.
 
Posts: 20 | Thanked: 1 time | Joined on Apr 2008
#45
doesnt the bluetooth module work like serial? someone mentioned that it might work, no idea. just try to direct python code to bluetooth port (device). i`m still doing a lot of things with n810 + flash + arduino and bluetooth priority is way too low for now, but definitely on the list!
kudos for great writeup with links, it will definitely help others!
 
Guest | Posts: n/a | Thanked: 0 times | Joined on
#46
Originally Posted by cmdowns View Post
At this point I'm just fishing for useful info. For example, can anyone tell me what it will take for the n800 to send the serial data to the Arduino via BT?
Bluetooth readily provides a cable-free replacement for a standard serial port. From a low-level point of view there are similarities to how USB devices emulate a serial port.

You can use the stand-alone rfcomm program to create a virtual serial port attached to a device, which is automatically connected when a program requires serial port access. You create such a virtual serial port with the bind command of rfcomm. Sadly, rfcomm is not included in the tablet by default, you need to install package bluez-utils-test yourself.

You don't necessarily need a virtual serial port. PyBluez can directly connect to RFCOMM ports of Bluetooth devices. See the PyBluez-provided rfcomm-client.py for a working example.
 

The Following User Says Thank You to For This Useful Post:
Posts: 20 | Thanked: 1 time | Joined on Apr 2008
#47
a bit offtopic, but can anyone help out with two things?
1. write a script that would do insmod operations on tablet startup (i dont know linux much, please be kind) and maybe also go in usb host mode. i guess insmod operations also require "sudo gainroot"?
2. write a script that would start a python program as soon as the arduino is connected to /dev/ttyUSB0 (like with usb flash drive - as soon as you insert flash drive the file manager is started)
 
Posts: 384 | Thanked: 90 times | Joined on Mar 2008
#48
Originally Posted by fanoush View Post
For N800 with OS2008 you can try to get my archive of various modules and try to insmod the drivers/usb/ftdi_sio.ko from it.
http://fanoush.wz.cz/maemo/modules-2...-custom.tar.gz

For N800 with OS2007 it is here

http://fanoush.wz.cz/maemo/4.2007-usbhost-kernel.tar.gz
http://fanoush.wz.cz/maemo/4.2007-us...modules.tar.gz

See also N800 usb-host thread in mailing list for details.

For 770 I currently don't have ftdi_sio.ko but could make one easily if there is a need. However there is usbserial.ko and pl2303.ko in /mnt/initfs/lib/modules/current which should be enough for pl-2303 based usb to serial converters (which are fairly common in various mobile phone cables).
Anyone know if the OS2008 usb to serial .ko's here work with Diablo ?
 
Posts: 2,152 | Thanked: 1,490 times | Joined on Jan 2006 @ Czech Republic
#49
Most probably yes, just try. Diablo kernel has same version as before. There are only with few additional patches/bugfixes. Those patches should not affect buiding most/all external modules.
__________________
Newbies click here before posting. Thanks.

If you really need to PM me with troubleshooting question please consider posting it to the forum instead. It is OK to PM me a link to such post then. Thank you.

Last edited by fanoush; 2008-07-04 at 05:11.
 
Reply


 
Forum Jump


All times are GMT. The time now is 13:45.