• Home
  • Help
  • Search
  • Login
  • Register
Pages: [1]
Author Topic: My Modified SheevaPlug part II  (Read 4643 times)
superpat
Full Member
***

Karma: 15
Posts: 141


View Profile
« on: August 27, 2010, 02:37:32 AM »

Hi,

I have been thinking for some time about the possibilities of using some of the other unadopted features of the Version 1.3 pcb Sheevaplug, in this case the unused pcb mounted plugs J6 and J7

J6 is a   6 pin plug,                J7 is a 4 pin plug

P1  Gnd                              P1 Gnd
P2  Uart0 RX data                P2 Uart0 RX data
P3  Uart0 TX data                P3 Uart0 TX data
P4  TW SDA                        P4 +3.3V
P5  TW SCK
P6  +3.3V

I have obtained the mating 4 and 6 pin connectors and some precrimped sockets on flying leads from RS components.

I thought I would start with J7  4 way, and try for a serial terminal, albeit without hardware flow control.

Unfortunately the Sheevaplug only has the connections for Uart 0 brought out onto the pcb, Uart 0 is shared by the USB type A debug port so it is impossible to run two physical ttys  at once. Whatever the ttyUSB0 "sees" so will this terminal!

The output of the uart is 3.3V and is DIRECTLY connected to the uart logic in the Marvell SOC, so great care has to be taken not to over volt the SOC.

I purchased from Ebay a very cheap dual  ttl to RS232 level changer. This uses the MAX3232 IC which suports 3.3V logic levels. (A converter which uses MAX232 is NO use, that is 5V logic only)  (Image attached).

I connected the converter to J7 and the serial o/p to my pc's serial port connector.  I set up a putty session for ttyS0 of my pc.  I disconnected the normal ttyUSB, USB serial connection leaving the uboot env parameter set to the normal ttyS0,115,200 and powered up.

It worked, but not perfectly. There was a lot of incorrect characters present on the putty session, but the principle was demonstrated.

I do not know the max baud rate of the serial  port on my pc.   There is a lot of points to investigate, does the elcheapo  digital to RS232 converter run at 115200 baud, is there filter caps throttling the signal, can the Sheevaplu supply both the Uart to USB converter and my serial RS232 converter?  Some 'scoping is required. I will have to change the speed of ttyS0 in the set env to a lower baud rate to see if the error rate improves.

I am not  completely happy doing this work, as I really cannot see  an application for a second serial terminal, since the usb serial port works fine. 

If I had a peripheral that had a RS232 connection AND I could see a way to redirect the console output of the Sheevaplug away from ttyS0,  and direct the application software's I/o to ttyS0 then there may be a point.

What do other SheevaPlug users think? Is there any use for a RS232 serial connection on the Sheevplug?

I have not looked at the other connector (J6) yet. This is obviously designed for a TWI or I2C  bus connection, HOWEVER it still uses Uart0  Rx and Tx data, so the caveats I mentioned above still apply.

I need the advice of someone skilled in Linux to advise me whether on a running system it is possible to change the console output from ttyS0  to another tty, leaving the Uart0 free for the I2C communication with whatever device you need.

OR Is it possible to associate Uart0 with another /dev/tty  by software on a running system?



* serial.JPG (186.76 KB, 800x600 - viewed 1794 times.)
Logged

mw
Newbie
*

Karma: 0
Posts: 7


View Profile
« Reply #1 on: September 06, 2010, 04:51:33 PM »

I had been mulling on this today, and then discovered your post.

Quote
I have obtained the mating 4 and 6 pin connectors and some precrimped sockets

Would you be able to provide part # ?

Quote
Is there any use for a RS232 serial connection on the Sheevplug?

Not quite an answer to your question, but a direct connection to the UART might just provide an alternative way of booting the plug from scratch in the absence of OpenOCD. OpenOCD did not work properly on my Mac PPC when I last tried it, due to some unfortunate big/little endian issues in the code. So I am reluctant to proceed with OpenOCD right now. The plan would be to exploit the BootROM Firmware Boot Sequence as described in Marvell's "88F6281, 88F6192, and 88F6180 Functional Specifications" document. (But it might turn out easier to audit the OpenOCD code.  Smiley )

Quote
... J6... This is obviously designed for a TWI or I2C  bus connection...

One possibility would be to use the I2C to connect up a simple low power LED "status" display. Ideally one that could be powered off the I2C power line (3.3V might be a problem). I did notice that some pre-built modules have an I2C interface built in. There appears to be I2C support in the kernel, although for a different board. Perhaps it could be tweaked into action for the plug.

Logged

superpat
Full Member
***

Karma: 15
Posts: 141


View Profile
« Reply #2 on: September 09, 2010, 08:48:10 AM »

Hi Here are the parts I used:-

Quote
I purchased the bits from Radiospares 
http://uk.rs-online.com/web

Here is a copy of my order with the RS  stock numbers, you can look up the xxx-yyyy stock numbers on their website,  They have a pretty good manufacturers library you can check whether they are the correct parts fort you.

Your order (stocked products)
* RS Stock No. *     * Qty *     * Unit Price *     * Goods Value *     * Description *
279-9544     10     0.51     5.06     Socket to free end crimped lead,300mm L
279-9162     5     0.12     0.60     4 way receptacle housing,1.25mm pitch
279-9178     5     0.15     0.75     6 way receptacle housing,1.25mm pitch
670-6423     100     0.01     0.80     Crimp terminal,1.25mm, 26-28AWG,reel
Running Total     7.21      Delivery charge:     0.00      VAT     1.26      * Net Order total *     *8.47*   



The 10 pre manufactured sockets and leads were expensive, but the cost of a crimping tool for one job was even more frightening!


regrads

P
Logged

mw
Newbie
*

Karma: 0
Posts: 7


View Profile
« Reply #3 on: September 14, 2010, 06:07:38 AM »

Thank you so much. The seeds of an autumn/winter project begin to germinate.

I had no idea that one could acquire pre-crimped leads. Perfect.
Logged

Schmerm
Newbie
*

Karma: 0
Posts: 5


View Profile
« Reply #4 on: November 24, 2010, 06:57:00 PM »

I have a TonidoPlug and it has NO serial USB connection. It does however have J6 and J7. This is the only way for me to access uBoot.

The schematics show that the two I2C pins are dual-purpose pins that can be used for flow control for the UART (their alternate names are RTS and CTS when you trace the wires back to the SOC). I'm not sure what mode those pins are in when the system boots up (the two modes being 1) acting like SDA/SCL and 2) RTS/CTS). Maybe using them as RTS/CTS can help with the transmission errors?
Logged

Schmerm
Newbie
*

Karma: 0
Posts: 5


View Profile
« Reply #5 on: November 30, 2010, 11:54:44 PM »

So I got a 4-pin molex connector for JP7 and an FTDI USB->TTL cable (it has USB on one end and VCC, GND, RTS, CTS, TXD, RXD wires on the other). Connecting VCC->VCC, GND->GND, TXD->RXD, and RXD->TXD between the cable and JP7 actually provides enough power for the plug to run on its own without any other external power source! Opening up COM3 with PuTTY lets me access the UART just like one normally does with a MiniUSB port.

Unfortunately, the connection dies during the boot process, and the plug reboots, even when I tried plugging in the plug's main power supply into the wall. I solved this by disconnecting the VCC->VCC connection, but leaving the grounds tied (to serve as a voltage reference for communication).
Logged

restamp
Global Moderator
Sr. Member
*****

Karma: 4
Posts: 273


View Profile
« Reply #6 on: December 01, 2010, 02:40:56 PM »

Just a head's-up:  Over in the Jeff Doozan Dockstar, they are modifying Nokia CA-42 data cables to interface with the 3.3V serial logic on the Dockstar's board.  Perhaps that would be an easy solution here, too.
Logged

Pages: [1]
Print
Jump to: