Router>serial port>SSC. Input?

In this mod on a Netgear WGR614L they take 3 wires (Rx, Tx, ground) and adds a 3.5mm audio plug. In this mod there’s alot more done.

My questions are would it be doable to add a db9 male connector instead? What does the SSC need from the serial port?

It would need RX, TX and Ground… You could hook it up to the TTL levels of the SSC-32 without a DB9, but you will probably need to do something about the voltage differences. This is the modem is 3.3v and the SSC-32 is 5V. There are several ways to do this. Or you could go to a DB9. Some other mods like this I have seen done is that people end up using an USB to RS232 adapter cable and cut off the end and connect it to the modem, which took care of both the 3.3v issue as well as the conversion to RS232 level signals. I believe I saw that somewhere up on the DD-WRT forums… Note many of the routers are setup this way with pins for a serial connection.

Another option I am looking at is to see how hard it is to add support for a USB to serial adapter. I have seen some mention of this up on the WIKI for DD-WRT and OpenWRT, but it takes several steps and I am no means a linux expert!

The next step after that would be to figure out how one could connect to the serial port, through the net…

Kurt

Maybe I got this wrong but was that a ‘yes’ to router->3 wires->db9->SSC question?

Soldering those three wires from the router to the cutted usb end of a USB to RS232 converter would work?

My electronic skills are best described as trial-and-error… :wink:

It might, as I mentioned I believe there was a long thread up on the DD-WRT forum on this…

My electronics is trial and error as well, so I prefer methods that have a less likely probability of generating the magic smoke :laughing:

What I may try at some point is either using a prop-plug I have sitting around(USB to RS232 with the pins…) or if I want a DB9, I might try something like: sparkfun.com/commerce/produc … cts_id=449 as I don’t necessarily want to buy a whole USB to serial cable to cut it up and hope I get the wires right… With the sparkfun unit you need to connect a 4th pin which powers it at the desired voltage. I may try something like this on a Belkin Play router that I just converted to DD-WRT as the original firmware was making me want to hit the router with a sledge hammer.

Kurt

So after you’ve modified the router to get RS-232 out, where does this serial port show up, and at what baudrate? Port 10001 (?) in the router’s map? (I’m a bit out of my element).

Alan KM6VV

Me Too!!!

Some modems I know have multiple serial ports. By default I think the first port will become a console for the embeded Linux. My Guess the next step would be to change the startup script or the like for the modem, to some how make it available, probably by defining some port, like you said 1001 but again guessing. Wheres a Linux Guy when you need them?

In the DD-WRT Wiki talking about USB including things like USB to serial adapters it says things like:

It all sounds greek to me…

Kurt

Yeah, I didn’t get anything out of that Linux-speak (?) either!

But it’s interesting to know that it can be done. Others in our robotics club have put a router on top of their 'bot, and used them to control. A bit too big at this time, but maybe sometime. I DO have a large 'bot to get back out into the park.

Alan KM6VV

Yes you can go Router -> 3wire -> max232 -> db9 -> ssc-32
You need to follow the second tutorial and use a max232.

However you could simply go router-> 3wire -> voltage divider -> ssc-32 using the alternate serial input
lynxmotion.com/images/html/build136.htm
See #14

Logic level converter

You can actually skip the logic level converter, by simply using a voltage divider between the SSC-32 TX, and the router’s RX.
The SSC-32 probably won’t have any trouble with a 3.3v input signal.

included is an attachment of how to make a simple voltage divider.
You can use 22k instead of 2.2k
and 33k instead of 3.3k
It’ll draw less power i believe.

I don’t know about the netgear router, but linksys has their own router that’s hackable with UART’s, it’s a dual antenna router.
It can get a full 115kbaud. The port is accessed over the network using a serial proxy of sorts.
Once connected via wifi, or by network, you select the UART by the IP address/port you designate in the hacked firmware.

NOW THEN! With all that said and done, using a router isn’t really the best choice. You would save yourself a lot of work by simply getting a WiFly module.
rovingnetworks.com/pricing.php
The RN-122 has dual UARTs.

The Router hack is usually only used if you’re on a very tight budget and contraption size isn’t an issue, such as on a larger 4x4 rover.
Or if you simply have an extra router laying around.

PS… i had one of those routers… but gave it away before i got interested in robotics… kinda hitting myself for that one.
voltage divider.jpg

115K? I can get that with BlueSmirf.

Alan KM6VV

There was mention of higher rates, but that was a while ago, i have no clue what the firmwares are capable of now. I’m a bit busy atm but i’ll search later if i can remember to do so.

Sort of a follow up on my previous post. I went ahead and got the serial port to work on the Belkin router. This part was a piece of cake. I simply opened the cover. I found that they already have pins soldered into the board for it on the area marked J3. The 4 pins are: + TX RX -. So I drilled a hole in the case, undid one end of a spare servo extension wire I had so I could get through the new hole and then plugged into 3 pins (Don’t need power for this).
Belkin-play-serial-1.jpg
At the other end I then unded the 3 pin housing and used a 4 pin instead as the Prop plug has 4 pins and I don’t need reset… I then used a couple of the servo extension Male/male things so I could plug the wire into the prop plug, as seen:
belkin-play-serial-2.jpg

I connected up a terminal program to the comm port associated with the prop-plug and configured it for 115200 and then plugged the router in. I started to get lots of data printed out, starting like:

[code]Decompressing…done

Init Arena

Init Devs.

Boot partition size = 131072(0x20000)

et0: Broadcom BCM47XX 10/100/1000 Mbps Ethernet Controller 5.10.128.0

CPU type 0x19740: 453MHz

Tot mem: 65536 KBytes

CFE mem: 0x80700000 - 0x8079A640 (632384)

Data: 0x80731730 - 0x80733AF0 (9152)

BSS: 0x80733AF0 - 0x80734640 (2896)

Heap: 0x80734640 - 0x80798640 (409600)

Stack: 0x80798640 - 0x8079A640 (8192)

Text: 0x80700000 - 0x80731730 (202544)

Copying boot params…DONE

Bootloader version 0.06e boot_version 0.06e

Project name : WG8017F22 1-LF-AK

Press space bar to cancel startup…

Device eth0: hwaddr 94-44-52-1B-0E-FF, ipaddr 192.168.1.1, mask 255.255.255.0

    gateway not set, nameserver not set

Loader:raw Filesys:raw Dev:flash0.os File: Options:(null)

Loading: … 3896 bytes read

Entry at 0x80001000

Closing network.

Starting program at 0x80001000

Linux version 2.6.24.111 (eko@dd-wrt) (gcc version 4.1.2) #2356 Sun Sep 26 16:29:21 CEST 2010

CPU revision is: 00019740

Determined physical RAM map:

memory: 04000000 @ 00000000 (usable)

…[/code]
At the end of all of the booting up of the router, you can then hit enter at the keyboard and you will get a login prompt…

Kurt

Whoa, lot’s of replies. Where to start? :smiley:

Well, if you run linux (dd-wrt) it will probably be at /dev/ttyS0 (or something similiar). Don’t know about the baudrate. The setup I’m going for is to have the output from my PS2 control being sent to a port then I’ll have the router listening on that port and pass everything it recieves to the serial port. Like this:
PC (running Linux)
echo -e “#1 P750 \r” | nc 192.168.1.1 3000

Router (dd-wrt):
nc -l 3000 > /dev/ttyS0

The greek language seems to tell you to install a usb driver.

The popular linksys router to hack is the WRT54, my teacher told me to also checkout the netgear one. So I did. It’s about $20-30 cheaper so it’s my best option. Any opensource router that you can add a serial port/usb to is useable here I believe.

True, but…

I enjoy these workarounds. It’s fun

I’m on a very tight budget. DIY is alot cheaper than bying ready-to-run parts

I’m on my first year as a linux network/systemengineer (think I translated it right…) so I might use this as my project.

About the size… Well, bigger must be better right? :wink: Think it will end with 1/10 scale truck or truggy. (It has to be a larger scale if I decide to put a paintball gun on it :smiling_imp: )

Already spent a week to get a working bash script to print a SSC-32 friendly output from PS2 control

Probably easier with a router when it comes to adding ip cams

Voltage divider seems to be a nice fix! :slight_smile:

'Hope you’re not expecting to get SSC-32 commands out of a PS2 controller!

PS2 will send 7 or so bytes of data over an SPI (similar) interface, or via radio link. These 7 bytes are the PB closures, and the analog joystick values (bytes).

The SSC-32 wants “#1 P750 \r” as you’ve noted. You’ll need some sort of processing to make the conversion. (hint: use a PIC/BM part).

“192.168.1.1 3000” did answer one question for me.

Alan KM6VV

I took this to mean he has completed a week worth of work getting a script to generate SSC-32 commands in relationship to the received PS2 commands.

Exactly.

OK, I didn’t read close enough! But I have seen others confused about the process.

Alan KM6VV