Hi …im new here and have a problem i cant seem to find a answer for…
I have my scout wireless with a smirf…everythings OK
but I want to add the bot board to run programs…cant find the info on how to run them all…
the smirf doc has the setup for 115,200…but the bot and ssc-32 are set to use 9600 plus the fact that the both want to be in the same place…rx-tx wise…
you would use either the smirf or the bot board to talk to the ssc32, not both. you could hook the smirf up to the bot board though and write code to either pass through commands, or define your own command set to send sequences out to the ssc-32 (for example.)
Read this post: lynxmotion.net/viewtopic.php?t=2396 it connects to the SSC-32 but you would use the RX and TX pins from the SMiRF to the bot board. You will need to write your own code since there aren’t any examples around as far as I know.
It doesn’t matter. You choose what servo pins you want to use: Example - 0-3 or 10-15, and attach the blue SMiRFs RX/TX pins to any of the bot boards servo I/O pins. To connect the SSC-32 board to the bot board, you again, decide what I/O pins you would like to use, then connect the data cable (the yellow and black cable that came with the SSC-32) and plug it between the pins you chose.
Connecting it all up is the super easy part. As I said before, you will need to write code that will use the chosen pins for communication.
if you are using a basic atom pro in your bot board then you most likely want to put the smirf on P14 and P15 so you can take advantage of the hardware serial port. the communication from the bot board to the ssc-32 is mostly one-way output from the bot board to the ssc-32 so using one of the other ports at the highest bitrate you can will create the least amount of time overhead spent bit-banging. to prove concept you can simply poll the hserin port on the smirf and send any byte received to the serout por to the ssc-32… effectively a pass-through connection. the preceding run-on sentence has been provided as an example of something you can do to test the idea out as you are wandering down a road not too many have wandered down before.
Jim called me today and help a lot with some of the questions i had…
a big TKX goes out to him for that…
i know the bot board and ssc have to be set for 38400 but how do i get the smirf configed to that…
i looked in the forums and the smirf stuff on there site but couldnt find a reference to it…i figure its in hex and the comand in the set for the smirf shows the setup for 115200…but doent explain the numbers…
the smirf works great…im gonna try to hook up the tree so i can program without the cable and run the progs on the bot board…
im gonna put a swith in so as to change between the two…
need the smirf info…
im posting some pics of my scout with the stuff i added to mine …
Guys,
I have a very similar project. I am working on a hexapod with SSC-32 and ATMega8 which are connected. Right now I download programs onto ATMega8 via serial cable and it works fine.
I need to make this wireless. Someone suggested I could use a serial port bluetooth reciever - what exactly is this smurf? Can I use any serial port bluetooth reciever or are there any specific ones that go with it? I don’t want to touch the SSC-32, I want it to recieve commands from ATMega8 and want to attach the wireless reciever onto the ATMega8.
whoops… I meant, there is a SSC-32 and a mini-ABB which is connected to it. So right now I talk to the mini-ABB only through serial cable. I need to make this wireless, so wondering how to go about it without touching the SSC-32. Will this blue-smirf connect to mini-ABB?
OK, that’s a little more clear. Yes, you should be able to use the BlueSmirf from Spark Fun mentioned in this and other threads here.
Configure the Powerpod program to generate a COM program for you.
The BlueSmirf is TTL level, so I’d switch over to using the Hserout/in routines and pin 15 (RX hardware USART) to talk to it, rather then the DB9 connector which is at RS-232 levels. You can still use the DB9 for program downloads. You’ll probably need to use an additional pin for the TX, as the Basic program will send a char to your PC to advise it that it’s ready for a command (like is currently done).
I’ve got the stuff at home, I might even get a chance to wire up my “Creepy Hybrid” (contest entry) project for wireless this weekend.
Parts:
1 x WRL-00158 : Bluetooth Modem - BlueSMiRF RP-SMA
1 x WRL-00150 : Bluetooth USB Module
1 x WRL-00145 : 2.4GHz Duck Antenna RP-SMA
Hi,
Thanks a lot for your reply, but I am a newbie in robotics and so some stuff I did not understand… you said:
you mean in the basic code change “serout” to “Hserout”?
How do I use the pin15 to talk to it? in the basic code right now it says for example:
serout p15,i38400,"#",RRHH,RRHH2,“P”,…
so here I change serout to Hserout as mentioned before. But the p15 remains as it is right?
You said I can still use DB9 for downloads, you mean I can still use serial cable for downloads? But I don’t want that actually, I want to program the robot wirelessly, infact, I want to be able to give it commands in real time.
The link you posted, it shows the connections of blue-smirf to SSC-32 board. But I need to connect it to mini-ABB only, I don’t want to touch SSC-32 as it is well connected to mini-ABB.
It is desirable to use P15 for the wireless coms, as it can use the hardware USART (Hserout/in). the line (and code) to the SSC-32 would be changed to something else, like P8
Downloads may be a little trickier over blue tooth, I don’t think anyone has verified that process yet. I have only worked with blue tooth to the hardware USART of the PIC, and that was a PIC18F4620. I’ll add blue smirf to my Creepy Hybrid when I get a chance!
yes, I posted a lot of links, one was blue tooth to the SSC-32, but it has other information as well.
Since I am up here I will try to answer a few of these. I read here you have a mini-ABB, but I don’t remember seeing what you have plugged into the mini-ABB. Is it an Atom Pro, Atom, or some form of Basic Stamp?
I will assume for now that it is a Basic Atom or a Basic Atom Pro. They both have a hardware serial port that uses pins 14 and 15. On the pro the transmit pin is on Pin 15 and the receive is on pin 14. I believe that this may be reversed on a standard Atom. To some of your specific questions.
Yes the basic code changes from using the serout command to using the hserout command, like wise for serin.
My assumption here is that you will be using the bluetooth to talk to a PC and not to the SSC-32. So if right now you are using P15 to connect between the mini ABB to the SSC-32, you may want to move this to another IO pin such as pin 8. You will need to change the current serouts that go to P15 to the new io pin.
Again my assumption is what you want to change is all of your code that does serouts to S_OUT and serins from S_IN to use the HSERIALOUT and HSERIALIN commands. If for example you are modifying the serial input code that was generated by powerpod, you would change the code in this section:
[code]ain
;SerialQuery
serout S_OUT,i9600,“Rd”] ; ‘Ready’ to recieve data now
serin S_OUT,i9600,100,NoData,[str DualShock(0)\7]
if CheckSum <> DualShock(0) then
Sound 9,[50\2000]
NoData [/code]
What he was saying was when you change the basic code that runs on your microcontroller that is plugged into the mini-ABB, you will need to use the DB9 connector to do it. However when your program is running on the PC and the mini-ABB you will use the new serial port that was created for your bluetooth device. I hope that makes some sense.
Not sure exactly what you are asking here, but the hook-up would pretty similar to SSC-32, When I tried it earlier what I did was: to solder male IO pins onto the bluetooth. Then I used a standard 3 pin servo extender wire, and two 1 wire jumper wires. I first plugged in one of the 1 wire cables to the two outside pins of the BT module (CTS and RTS). I then modifyed the three pin servo cable on end to swap the ground and power pins. I then plugged this end into the BT module and the other end to I believe the 3 pins of IO port P14 on the ABB. I then used the 2nd one pin jumper to jump from the one last pin on the BT module (RX) and connected it to the signal pin on P15 on the ABB.
Well so, seems like I have to figure out some basic stuff first. This project was being done by someone else before, and seems like the reports are confusing. The person who was working on it before has assembled the robot. So now I have a few more questions:
Its AH3-R purchased a couple of years back actually. The report says its Basic stamp 2 on mini-ABB. But I have been using Basic Micro ATOM IDE 02.2.1.1 (says Basic Atom 28) to program it and it works fine. So that means its not Basic Stamp 2 right?
For your point 3, I am still confused about this DB9 connection. So I guess it brings me to my new question, since right now I write up a program for the robot to do something, and download it onto the microcontroller using a serial cable.
a. Now I want to make this wireless, and want to be able to change the code - give commands in real time – is that possible? Is that what you mean by running the program on the PC?
b. You’re saying when I change the program, I will need to use DB9 connector - using DB9 connector means using a serial cable right?
I think I am getting a bit of idea, but sorry if I am asking too many questions.
now will this be compatible with my mini-ABB and if so, isn’t it easier to just use this instead of blue-smirf. This should work just like the serial cable except there is no cable, so i am guessing not many code changes will be needed??
I will go through the rest of the stuff you told me and try it out.
I’ll try this then. I am thinking using batteries instead of AC cable. Lets see if that works.
But also, as I mentioned before, I need to be able to give it commands while the program is running on the microcontroller. So for that, I will just have to change it in the code itself? like, the fact I am using bluetooth/wireless or serial cable shouldn’t effect it right?
Any ideas on how to change code in this regard?
Yes, you should be able to start from a COM version of the Powerpod generated program, and the Serial_CP_H3 program running on your PC will simulate a PS2 wireless joystick. This should work through a wireless link.
Any changes to the commands simulated this way, and you will have to write the code to accommodate it! There is a sample C++ program furnished with the Powerpod download that might help as well.
What you really need is the source code for Serial_CP_H3, that way, you’d have a starting point, and could add the control code you desire. Maybe we should ask Jim. I don’t know if it was written in Visual Basic 6 or what. Could be in C++?
Try looking in your directory that powerpod is installed in. I think the source files are included: On my machine it is:
“c:\program files\powerpod\tools\C++ Demo”