c168i interfacing to TTL microcontroller

Forum for the Open GPS Tracker

c168i interfacing to TTL microcontroller

Postby jillbensen » Thu Sep 09, 2010 5:36 am


I was busy working on a project similar to the tracker (but using a different microcontroller and a different GPS unit) when I came across your site. I decided to add the c168i cell phone to my project.

I am having trouble interfacing to it. I am using the Luminary Stellaris LM3S6965 microcontroller. It has 3 uarts, and I am using uart1 to listen to my GPS and uart2 to talk to the cell phone. (uart0 for USB and debugging)

At first I connected the phone Tx directly to the micro Rx and micro Rx directly to phone Tx. It did not work at all.

Then I noticed that although both are 3.3V devices, the phone is CMOS and my microcontroller is TTL.

I tried using a 10K pullup on the TTL to CMOS signal (microcontroller Tx, phone Rx, 10K to 3.3V), and a 10K pulldown on the CMOS to TTL signal (phone Tx, micro Rx, 10K to ground). It worked! ... sort of...sometimes...

It is flakey at best. Sometimes the phone responds to a AT*SWRESET command with its splash screen, but won't utter as much as a single OK in response to commands after that. Sometimes it won't do anything at all. Sometimes it seems to work pretty well, giving good responses and accepting a text message from the micro. (I saw my text message in its outbox!) But I believe that the serial connection is just not reliable, electrically.

I tried a stronger pullup/pulldown. 2K. It got worse. I was thinking I should try both stronger or weaker pull-ups or pulldowns, each independently, and see how that works, but I really do not know what I am doing, just grasping. So I am leaning towards converting both sides of the interface to RS232.

I am about to order an ICL3232 chip (Digikey PN ICL3232CP-ND, $2.34). It claims to be compatible with both TTL and CMOS. I would use it to convert both uarts to RS232, and then loop the RS232 tx to rx for each channel. Looks like I would only need the single IC, and a handfull of 0.1 uF caps (which I have on hand), to eliminate the direct interface of TTL to CMOS.

I was wondering if anyone else has any experience to share regarding interfacing the c168i to a TTL serial port.

Think I am on the right track with suspecting TTL vs CMOS compatibility problems, or is this phone just sooooo finicky about timing and maybe I need to time my commands to it differently?


Posts: 1
Joined: Wed Aug 25, 2010 5:35 pm

Return to General tracker discussion

Who is online

Users browsing this forum: No registered users and 2 guests