maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   The Other Half (https://talk.maemo.org/forumdisplay.php?f=59)
-   -   [] Jolla OtherHalf UART/232 Interface (https://talk.maemo.org/showthread.php?t=92382)

kimmoli 2014-01-13 15:32

[WIP] Jolla OtherHalf UART/232 Interface
 
Originated from other thread....

Quote:

Originally Posted by phenoboy
I'd like to add serial port (UART RX/TX pins at least) capability to Jolla with I2C.

Quote:

Originally Posted by nieldk


I have given some toughts to this already...

--> either SC16IS750. Has 3.3V operation, but you'll need I2C levelconverter (e.g. PCA9517) and 1.8V regulator. Easier to interface to the 232 transceiver.

http://talk.maemo.org/attachment.php...1&d=1389602581

--> or SC16IS850L. Has 1.8V operation, no need for I2C level converter, but needs 1.8V regulator. and some tricks to interface to 232 transceiver.

http://talk.maemo.org/attachment.php...1&d=1389602574

nieldk 2014-01-13 16:18

Re: Jolla OtherHalf UART/232 Interface
 
trying to see if i can get a ssmple, or two. as they have a distributor close by

phenoboy 2014-01-13 18:41

Re: Jolla OtherHalf UART/232 Interface
 
Looks good! What about the software side - what kind of interface we would have to use with this SC16IS750 ? I mean do we have to write a library from scratch ?

Pardon my ignorance.. I'm not an HW expert and new to Jolla. What is TCVR ?

nieldk 2014-01-13 18:45

Re: Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by phenoboy (Post 1406177)
Looks good! What about the software side - what kind of interface we would have to use with this SC16IS750 ? I mean do we have to write a library from scratch ?

Pardon my ignorance.. I'm not an HW expert and new to Jolla. What is TCVR ?

tranciever
the purpose - and interface is rs232/ infrared addition to communicate with serial devices or connect fx to retrieve logs from bootloader

kimmoli 2014-01-13 23:45

Re: Jolla OtherHalf UART/232 Interface
 
I should have all parts for the -750 version.. and some code ready, as this was used in one project to interface 232 touchscreen via I2C.
Only thing missing is time to tinker it..

nieldk 2014-01-14 14:38

Re: Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by kimmoli (Post 1406251)
I should have all parts for the -750 version.. and some code ready, as this was used in one project to interface 232 touchscreen via I2C.
Only thing missing is time to tinker it..

And, I just got a qoute that the connection close here is very interested in this, and wants to help where they can - So, all chips and technical assistance is 'almost' ready :)

kimmoli 2014-01-19 09:47

Re: Jolla OtherHalf UART/232 Interface
 
1 Attachment(s)
Looking for the thinnest D9 -connector (Straight) solution... The WP 425 was thinnest after 30min go'ogling.

http://wppro.com/content/typo3temp/p...237bdb06db.gif


kinda-retro-look

kimmoli 2014-01-20 23:10

Re: Jolla OtherHalf UART/232 Interface
 
1 Attachment(s)
update
V0.02 schematic. ready. then layout.
(The 232 transceiver changed to SP3203E -has separate logic supply for interfacing 1.8V and with more channels)

No leds, should be buffered as there is no outputs with enough drive-strength.
Signals available in connector
  • TXD -->
  • RXD <--
  • DTR -->
  • RTS -->
  • CTS <--

kimmoli 2014-01-22 13:48

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
I have seen some discussions about IRDA transmitter/receiver things?
Or are they talking just IR transmitters like in remote controllers?
IRDA shold be doable with this uart.

nieldk 2014-01-22 13:51

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Thats what I plan, I believe irda is a thing missing, since N900 ;)

kimmoli 2014-01-22 14:31

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by nieldk (Post 1408196)
Thats what I plan, I believe irda is a thing missing, since N900 ;)

Ööö . IRDA is serial comms over infrared (RX/TX), afaik N900 is/was only capable of transmitting IR (like with Irreco app)

Hmm... Using just the UART to send IR 'bits' with carrier frequency could be possible. The carrier is about 30...60 kHz, say 40kHz. If this is set to uart bitrate.
The actual datarate is way much lower, say something like 1200 bps. So we need send about 4 bytes of 0xAA for one high bit (and 4 bytes of 0x00 for one low bit (hoping that the STOP bit doesn't cause problems)

Doing it like this would free the phone cpu from low-level timing and lets the uart to do it. just feed the data to fifo over i2c.

Could be doable. Just add buffer and IR led there.
For IRDA something like TFBS4711 could be suitable.

Zeta 2014-01-22 19:28

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Why not use a dedicated IRDA chip, with an I2C interface then ?
Something like this : http://www.nxp.com/products/interfac..._gpio_bridges/

Would solve problems like the stop bit.

By the way this chip seems to also provide RS232/485 interface and GPIO.

kimmoli 2014-01-22 19:44

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by Zeta (Post 1408283)
Why not use a dedicated IRDA chip, with an I2C interface then ?
Would solve problems like the stop bit.
By the way this chip seems to also provide RS232/485 interface and GPIO.

:confused: Project is already using the SC16IS850L

There is no problem with the IRDA, it will work.

The idea here was to use the IRDA transmitter to mimic the e.g. TV remote control by making the ~40kHz (or 38kHz) carrier signal with bit pattern.
https://learn.sparkfun.com/tutorials...munication/all
and something here
http://youtu.be/BUvFGTxZBG8

nieldk 2014-01-22 20:16

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
exactly, main purpose, for me at least ;)
Oh and, yes, I know the N900 have irda :) that was my point. No of the devices i have had since that have had irda interface. So, even better if we can combine this with rs232 as well - and - that OLED / perfect device!

Zeta 2014-01-22 20:30

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by kimmoli (Post 1408291)
:confused: Project is already using the SC16IS850L

My bad... as I didn't remembered you talking of IRDA out before on this topic, I assumed the chip you selected didn't have IRDA and didn't check the previous page...

Quote:

Originally Posted by kimmoli (Post 1408291)
The idea here was to use the IRDA transmitter to mimic the e.g. TV remote control by making the ~40kHz (or 38kHz) carrier signal with bit pattern.
https://learn.sparkfun.com/tutorials...munication/all
and something here
http://youtu.be/BUvFGTxZBG8

Thanks for the link. I think I understand now.

Wouldn't the proper way to do this be that the chip is configured with the expected 1200 bauds and modulate it after (with an ne555 like or an I2C PWM expander if its period needs to be software controlled).
This would reduce the I2C load (probably not a problem anyway), and remove the need for some bit conversions to send data, so something like "cat /dev/xxx" would allow to see directly the received value (and not a list of 0x0 or 0xF for each individual bit) ?

Your solution work, but I always tend to choose hardware when possible to avoid doing tricky stuff in software.

Edit : After second though, there may be problems with the start/stop bits with this proposal. Don't know if they are the same on IR than with say a RS232 line, so that the UART would understand them correctly ?

kimmoli 2014-01-22 20:51

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by Zeta (Post 1408307)
Wouldn't the proper way to do this be that the chip is configured with the expected 1200 bauds and modulate it after (with an ne555 like or an I2C PWM expander if its period needs to be software controlled).

That is one possiblity... but i like to do things inside-out... (or atleast try)

Quote:

Originally Posted by Zeta (Post 1408307)
something like "cat /dev/xxx" would allow to see directly the received value (and not a list of 0x0 or 0xF for each individual bit) ?

no intention to receive "remote control" data here, just transmit.
transmit can be done to work like echo "123" > mytransmitthingy with piece of software.

Quote:

Originally Posted by Zeta (Post 1408307)
there may be problems with the start/stop bits with this proposal. Don't know if they are the same on IR than with say a RS232 line, so that the UART would understand them correctly ?

In sending bit '1' there is no problem with start/stop's, but when sending '0', the stop bit gives a pulse of half period of 38kHz every 10th period of that. Hopefully that is filtered out by the IR receiver.
One possibility is to stop transmitting at all when '0' but to get proper timing is pain.

kimmoli 2014-01-22 20:55

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
1 Attachment(s)
Quote:

Originally Posted by nieldk (Post 1408304)
So, even better if we can combine this with rs232 as well - and - that OLED / perfect device!

uf... ....

kimmoli 2014-01-25 12:24

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
1 Attachment(s)
Stupid question... What would be the best direction of IR ?

This affects the PCB design.
  • A = USB connector direction (i think it is this)
  • B = Where the camera points
  • C = Left
  • D = Right

The transceiver can be mounted in top view or side view, so the option B will be possible with any other option.

Option B only will make smallest PCB area.
With option A, have to go around the camera...

CLRS530 2014-01-25 13:31

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
B would be no option in my opinion. if you think of the theoretically possibilities like playing with a joystick you can't put the phone on a table without any special mounting.
Also I would consider it only if it would shrink into the OH (unlike your render) that would result in a really thick OH.

How would a construction of A/C/D look like? You also would have to have an OH thickness as wide as the R232 or your OH go around the phone on all- or only the upper side(s). Did you think of this idea?

One more effect to consider is the one on the bags for jolla. The only possibility to maybe not break every already existing bag is A. Then only the thickness can still be the problem.
Thats the reason A would be the one I vote for.

Mentioned before and now asked for all options. Are you planning to shrink it into the OH or put it on top?

kimmoli 2014-01-25 14:35

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
this was mainly about the Infrared direction... i have not considered yet the D9 Direction yet. maybe it will be facing to dir A or towards you. display direction. making phone little longer

Bundyo 2014-01-25 16:14

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
I'm also for A, seems most logical and compatible.

CLRS530 2014-01-25 16:46

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Ah yeah misunderstood then. For infrared it doesn't matter that much in my opinion. If it is easier to build it can be B either.
But only A or B.
Have me in mind for one of these OH. Seems to be really cool - but only if there will be some Calls/Apps supporting the technologies. :/

kimmoli 2014-01-25 17:36

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
checked quickly, D9 is wider than there is space between edge and usb connector..
or i need to use completely different connector ...
small, robust, competitive priced, available ...äh

D9 why so big...

kimmoli 2014-01-25 21:03

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
couldn't resist make some sketching...

USB micro connector is there to allow charging when this TOH is connected, as the phones own usb connector goes behind d-sub. (it is connected to the 5VIN dc input pogo)

(I have to check does this have effect on handsfree/echo cancellation as the top mems microphone is now located behind the D-sub connector.. small hole close to the jolla -logo)

https://lh4.googleusercontent.com/-Q..._3d_1_7_r1.jpg

https://lh4.googleusercontent.com/-z..._3d_1_7_r2.jpg

https://lh3.googleusercontent.com/-M..._3d_1_7_r3.jpg

mikecomputing 2014-01-25 21:52

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Why not just use FT232 and connect to already avaible USB and make USB host work on Jolla?

kimmoli 2014-01-25 22:48

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by mikecomputing (Post 1408940)
Why not just use FT232 and connect to already avaible USB and make USB host work on Jolla?

I did think about this first... but
I will not even try to get USB host working...

and i would need to get micro usb male connector plugged in while inserting toh...

If and when USB host works, one can use external powered usb hub with ready usb-232 cables. and there is no fun with that.

MaemoUser 2014-01-25 23:51

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Why not integrate a simple micro adapter in the other half to make the rs232 pluggable? I think this would look much better and you can use this adapter with other fancy pluggables.

Kabouik 2014-01-26 02:49

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Have you tried some sketching with the connector on the side, opposed to the hardware volume and power keys? This way, the Jolla would be easy to handle, as the large plug would not be in the palm, nor on fingers holding the Jolla on the left side (if you are right-handed of course). Additionally, it would keep the phone thin, wouldn't block the micro-USB plug nor the microphone, and would be easy to put in a jean's pocket.

Or on the bottom, but the orientation may be an issue for some uses.

minimos 2014-01-26 08:18

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by kimmoli (Post 1408896)
checked quickly, D9 is wider than there is space between edge and usb connector..
or i need to use completely different connector ...
small, robust, competitive priced, available ...äh

D9 why so big...

What about using instead a RJ45 connector, as e.g. in Cisco consoles?
Yes, it would require a RJ45-to-DB9 adapter cable for typical usage, but thinking about the bulkyness of a DB9 male+female when connectors are mated together, that would put a lot of strain on the PCB, and a RJ45 could be a little more on the lightweight side.

kimmoli 2014-01-26 09:03

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by Kabouik (Post 1408975)
Have you tried some sketching with the connector on the side, opposed to the hardware volume and power keys?

now i have..

https://lh4.googleusercontent.com/-d...3d_1l_1_r1.jpg
https://lh4.googleusercontent.com/-W...3d_1l_1_r2.jpg

Quote:

Originally Posted by minimos (Post 1408994)
What about using instead a RJ45 connector, as e.g. in Cisco consoles?

I have some personal issues against RJ45, but i agree about the mechanical issues with bulky D9.

jesper 2014-01-26 09:30

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
1 Attachment(s)
Does it have to be a DB9?
Better to use a smaller connector type, like micro-D or something.

kimmoli 2014-01-26 11:19

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by jesper (Post 1409014)
Does it have to be a DB9?

actually it is DE9 ... but that is another story.

I have given lots of thoughts for another connectors.. then the toh needs to include this adapter cable, but mjaa it shouldn't be a problem.
Micro D is one option, but it is not so Micro afterall..

Maybe then go even more miniature... something like JST SHL or whatever... >10⁷ different connectors out there...
This would keep the TOH slim, no overhangs. IR (and IRDA) usable, fits in pocket, not blocking phones own connectors, and with the adapter cable get access to RS232 pins in standard D9.

You pushed, i iterate.

stb 2014-02-13 23:09

Re: [WIP] Jolla OtherHalf UART/232 Interface
 
Would be nice to have a connector to TTL, so I could use my video terminal (https://code.google.com/p/tinyvt/) on it. :)

kimmoli 2015-02-07 15:19

Re: [] Jolla OtherHalf UART/232 Interface
 
Long time no update. Actually the design has been frozen for a year now.

Today i managed to progress it to level - order PCB's for first version

https://lh6.googleusercontent.com/-k...art-leiska.jpg

This is what i ended up with:
  • RS-232 available in DE-9 connector
  • Logic level signals in pinheader, external supply 2.5V to 5V, or internal 3.3V
  • When voltage in VIN pin present, RS-232 disabled
  • IrDA port (assembly alternative with pinheader)

Then some 3D design...

nieldk 2015-02-07 15:33

Re: [] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by kimmoli (Post 1459955)
Long time no update. Actually the design has been frozen for a year now.

Today i managed to progress it to level - order PCB's for first version

https://lh6.googleusercontent.com/-k...art-leiska.jpg

This is what i ended up with:
  • RS-232 available in DE-9 connector
  • Logic level signals in pinheader, external supply 2.5V to 5V, or internal 3.3V
  • When voltage in VIN pin present, RS-232 disabled
  • IrDA port (assembly alternative with pinheader)

Then some 3D design...

Preorders?
Iam in! :)

kimmoli 2015-02-07 21:21

Re: [] Jolla OtherHalf UART/232 Interface
 
built picocom for jolla, made a test driver that creates a pseudo-terminal like /dev/pts/1
works.
hope that the China newyear/spring festival doesnt delay pcb delivery too much.

robthebold 2015-02-08 00:20

Re: [] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by kimmoli (Post 1459955)

[*]RS-232 available in DE-9 connector

Thank you for not writing DB-9!

robthebold 2015-02-08 00:23

Re: [] Jolla OtherHalf UART/232 Interface
 
Quote:

Originally Posted by kimmoli (Post 1459985)
built picocom for jolla, made a test driver that creates a pseudo-terminal like /dev/pts/1
works.
hope that the China newyear/spring festival doesnt delay pcb delivery too much.

Although the holiday is technically something like 2 weeks long, the production delay never seems to be anywhere that that bad in my experience.

nieldk 2015-03-09 14:29

Re: [] Jolla OtherHalf UART/232 Interface
 
Hey kimmoli

Just waiting to purchase this one ;)

kimmoli 2015-03-09 14:32

Re: [] Jolla OtherHalf UART/232 Interface
 
Still waiting for PCBs to arrive, shipped during MWC (but not shown on tracking yet :( )


All times are GMT. The time now is 05:41.

vBulletin® Version 3.8.8