ARC-32 for beginners

Just got my ARC-32 installed the software and my Windows 7 system seems to see the controller.
So far all i’ve been able to do is get the status LED to constantly blink. is there any type of walk through/tutorial
to get one going?

Well, the ARC32 is an BasicAtomPro Processor thatc an run up to 32 servos. What are you planning on doing with it. If you give an example of your robot(wheeled, hexapod,biped,quad etc…) then I can start giveing you some infor on how to do different things. Since it’s basically brand new currently the only sample code is for running some of Lynxmotions hexapod robots.

I’m building a biped. I have the torso completed. i appriciate any assistance.

Hi,

FYI, I’m working on a biped version of the Phoenix v20 code (written by Xan and modified for the ARC-32 by Kurt). The kinematic won’t work for all kind of biped leg configurations. You’ll find some info about my project here: lynxmotion.net/viewtopic.php?f=7&t=6342.
I’ve not posted any code yet, but I’ll do that when the project are done.

Do you have any picture of the biped you are building? How many DOF’s does the leg have?
How are you planning to control the walking/leg movemnt, using premade sequences or realtime IK calculations?

Zenta,
Very nice project. I do not have any pictures at this time. I was mainly trying to build a NICK like biped.
I’m sorry i dont understand what you mean by DOF. (it has alot of other meaning in my brain housing group)
But. this is the assembly instructions that i used.

Not to sure at this time. I’m just hoping to be able to get him to stand up without falling first.
If you have any suggestions I’m just learning and willing to try and experiment.

Thanks
Phil

DOF means degrees of freedom, or how many axis on each leg. For example 5 DOF leg is 2 hip axis, a knee and 2 ankle axis.

Here is a simple program for an ARC32 to start the specified servos holding their position at their center points(center of the servos not necessarily the center of your leg axis).

[code]ENABLEHSERVO2

hservo [p0\0,p1\0,p2\0,p3\0,p4\0]

main
goto main[/code]

Change the p#s to the correct servo pins and add any more servos you have to connected. This code will tell the servos to move to there center point immediately(eg as fast as they can go). After you have initialized the servo positions this way you can send other hservo commands for each servo with speed arguments to control how far to move them for how long.

Thanks for the explaination (to many acronyms in my head). I was able to run the code you posted.
I got brave and tried the ARC32 Servo Example from the data sheet it ran ok after i commented out the following lines

[code]hserout [0,” Moving servo: “,dec servopin,13,13]
hserout “VS1 voltage is: “,real (TOFLOAT hservostate 32)/1024.020.0\2,”v”,13]
hserout “VL voltage is: “,real (TOFLOAT hservostate 33)/1024.0
20.0\2,”v”,13]
hserout “VS2 voltage is: “,real (TOFLOAT hservostate 34)/1024.0*20.0\2,”v”,13]

hserout “Battery voltage is low!”][/code]

I kept getting TOKEN errors pointing to words in the line (Moving, voltage, and Battery)

Thanks for the help

I’ve been trying to get the xbee to communicate using the xbee modules without any sucssess. the baud rate is set to 115.2 all other setting are defaults that worked with the SSC-32.

I’m using J4 pin 7&8 for power -> seemed good as the loop back test worked
i connected rx -> txd2 and tx -> rxd2 of J4 AUX 1 header

I’m I missing something? :frowning:

Probably :laughing:
I have Xbee working with the Arc32 as well as the other Basic Micro processors. I am currently in the process of converting the XBee code that I was using to communicate with the DIY remote control or a VB application on the PC from transparent mode to API mode… (Covered in other threads…)

Always with communication issues like this I first like to verify I have RX and TX and ground connected to the right pins. Sometimes I will simply swap RX and TX to make sure that does not help as sometimes the pin makings on the adapter boards are confusing. But I will assume you got that right.

Next, I assume you are using the HSERIAL2 APIs to communicate with the hardware serial port.

However your problem is most likely the baud rate. That is 115200 does not work with the hardware serial port of the Arc32 or other Basic Micro processors. More details up on the thread: viewtopic.php?f=4&t=5542&p=56137&hilit=hardware+baud+115200#p56137 Note that thread is for the Bap40 which is the same processor as the Arc32.

Couple of choices here. If you stay with standard XBee Baud rates:
57600 - Closest is (56818) which is off by about 1.4% will probably work
38400 - 39062 or 1.7% may work

Or what I did was go to a non standard xbee baud rate of 62500 which has 0% error, it also has 0% error on the BAP28 that runs at 16mhz as well). You can use the ATBD command to choose non-standard interface rates. There are some complications with non-standard interface baud rates on the PC running at non-standard baud rates as X-CTU will not allow you to do certain things. You can use X-CTU to configure it though. I however mostly use a configure program I have running on one of my BAP28 boards to configure most of my XBees. MY VB apps run the XBEE on the PC at 57600 which is a standard baud rate. Yes they are different. The baud rate given in the ATBD is the rate that the XBEE communicates with the host, not the speed that it wirelessly talks to other XBees. The only problem of running the two XBees at different baud rates is, that in theory the XBee that communicates with the host at a faster speed could overrun the other XBEE if the other side can not read it fast enough. Hope that makes sense.

Good Luck
Kurt

Kurt thanks for the reply. Just to make sure this is what I’m using with the ARC-32

2 XBee 1mW Wire Antenna
1 XBee Explorer USB
1 XBee Explorer Regulated

I’m using separate power supplies for the logic and servos
I have not configured anything on the XBee’s other than the baud rate
I get a good loopback using the X-CTU software
I checked my connections - even tried swapping RX TX wires (but I’ve done that wrong before too)
-I just used the J 4 connector see picture
-I left all the jumpesr on JP5

:open_mouth: You mention API mode do I need to set that on the modules? if yes which one eneabled or enabled w\PPP?

I Tried both 57600 and 38400 baud rates it still cant fine the Atom
I’m lost here. :blush:

Thanks for the help

Your wiring looks correct. I know that mine is similar, however it is inside the Phoenix body and it is hard to see all of the wires…

What software are you running on the arc32 to try it out? I assume you enablehserial2 and you do something like:
sethserial2 cXBEE_BAUD, H8DATABITS,HNOPARITY,H1STOPBITS
(Where cXBEE_BAUD is one of the H numbers like H62500)
Maybe something like:

[code]’ Simple loop back test…

szLine var byte(100)

ENABLEHSERIAL
ENABLEHSERIAL2

SetHSerial H38400,H8DATABITS,HNOPARITY,H1STOPBITS ’ set debug terminal to 38400

SetHSerial2 H38400,H8DATABITS,HNOPARITY,H1STOPBITS ’ set up comm port for com2

Main:
hserin2 [str szline\100\13] ’ read in a line of text… no timeout
hserout [str szline\100\13, 13] ’ output line up to cr then output cr
goto Main[/code]
The above code assumes that it will only receive strings that are terminated by a CR. This only tests communications going one way. Could update this to go the other way as well…

Yes, I am converting my code to API mode, but that is not necessary. I currently have all of my stuff working in transparent mode. The differences of using API mode is that it gives you quicker control of who you wish to send a packet of information to and on the receiving side, it allows you to know who sent it to you…

As I mentioned before I use 62500.

Good Luck
Kurt

Kurt,
Im using the Basic Micro Studio. When I try to program the arc-32 i get an error that " A BasicATOMPro processor must be connected to program"

Do i need to program the ARC-32 connected to the usb?

Yes, you need to program the Arc32 using the USB connection. In particular it needs to go the IO pins associated with the USB…

Even if you were able to wire up the XBee to the first hardware serial port, I don’t think you could get the performance required to program the chip…

Kurt

Let me make sure i understand (i can be a rock sometimes) this. I have to be hard wired to program the ARC-32?

Phil

Yep!

Bummer, thought i would be able to use the ARC-32 like the SSC-32. I was able to program the arc with the code above
do i was the debug window of the studio to send the string?

Phil

The problem with most wireless serial adapters is they don’t have a PC controllable RTS or DTR line. That is because they handle their own flow control onboard. But since the ARC-32(and All all Atom/AtomPro modules) need to be told to reset to get into progrmaming mode, the RTS or DTR line must be controllable. I have yet to find a true wireless serial port commercially available that gives this control to the PC. If anyone finds one I’d appriciate you posting it.

Can one communicate with the ARC-32 using the VB controller and the XBee’s ?

After it’s been programmed with code you can use standard serial communications without flow control. Only programming the code to the board requires the RTS or DTR serial line.

ok,thats sweet. what would be a good way to test if i’m communicating. after its been programed. I would guess like a loopback test.