Page 1 of 3 123 LastLast
Results 1 to 10 of 27

Thread: Biped Controller

  1. Post Biped Controller

    Needed a controller for a biped, so I purchased an OpenCM 9.04 controller, OpenCM 485 expansion board, and a Sparkfun MPU-9150 (SEN-11486). Have however found a few issues so far.

    First is that the OpenCM software v1.0.2 is buggy. One issue I found is the Dynamixel.cpp function rxPacket checksum is not correctly calculated if the sum is greater then 255. Fixed it by modifying the code to mask the result prior to the test as follows:

    if(mPacketType == 1){ // Dxl 1.0 checksum
    for(bCount = 2; bCount < bLength; bCount++){
    bChecksum += mRxBuffer[bCount]; //Calculate checksum of received data for compare
    }
    bChecksum &= 0xff; <-- new line
    if(bChecksum != 0xff)

    Second is that I cannot connect the MPU to the controller when using the expansion board. Haven't decided if I'm going to solder wires to the controller pins, reverse the controller pins so the MPU can be plugged into it, or something else

    Third is that I purchased a ST-Link/V2 as I plan to switch to a Linux development environment. However I was not able to read the flash with my Windows 7 setup. I considered trying to load the Robotis firmware, but have held off so far as I was concerned it would render the controller unusable.

  2. #2
    Join Date
    Sep 2010
    Location
    ಠ_ಠ
    Posts
    2,282
    Images
    27
    Rep Power
    275

    Re: Biped Controller

    They only had one person at Robotis somewhat dedicated to working on the OpenCM IDE and core, so not too surprising there are still several bugs lurking in their rewrite of the dynamixel library (they reverted to somewhat older code when they made it modular to support multiple dxl objects). The Maple core that was adapted into the OpenCM core was quite shite, so much of the OpenCM core continues in that tradition. If I were still being paid to work with it, I would have continued the complete rewrite of the USB functionality and transforming the rest of the core to mimic/reuse the Arduino 1.5.x ARM core.


    Kind of disappointed that they did not add double headers (two 2x20) on the RS-485 breakout to maintain access to the pins of the OpenCM, but there are alternatives like using extra long pins that protrude above and below the OpenCM or using the long pinned stackable pin/socket headers like some arduino shields do (give socket access above and shield pin below). The OpenCM come without any of the 0.1" headers soldered, so should be able to use whatever you want instead of the short headers that come with some of the kits.


    The ST-Link is only needed if you want to replace the bootloader, not for normal firmware uploading. If you have an ST-Link dongle, then you have direct access to the entire memory space (RAM, FLASH, and all memory mapped peripherals) so there is no way to bork the STM32 short of disabling JTAG/SWD interface or performing some sort of security lock of the FLASH.

    If you use RoboPlus to upload the Robotis firmware to work with RoboPlus Task/Motion/Manager, then you should still be able to use the OpenCM/Arduino IDE to replace it with any other firmware at a later time. The only possible issue is if you have to use the ST-Link to upgrade the CM-904 to the closed-source bootloader they added to all newer OpenCM IDE github repository to use RoboPlus. In the unlikely event that it has changed the upload process such that it breaks compatibility with the OpenCM IDE, then you would still be able to use the ST-Link to upload an older bootloader to restore compatibility with the OpenCM IDE.
    Please pardon the pedantry... and the profanity... and the convoluted speech pattern...
    "You have failed me, Brain!"
    bleh

  3. Re: Biped Controller

    Quote Originally Posted by tician View Post
    Kind of disappointed that they did not add double headers (two 2x20) on the RS-485 breakout to maintain access to the pins of the OpenCM, but there are alternatives like using extra long pins that protrude above and below the OpenCM or using the long pinned stackable pin/socket headers like some arduino shields do (give socket access above and shield pin below). The OpenCM come without any of the 0.1" headers soldered, so should be able to use whatever you want instead of the short headers that come with some of the kits.
    Just finished replacing several pins on the OpenCM9.04 with longer ones. Did it by removing the plastic frame to allow changing one pin at a time, then put the frame back on in three four pin sections to keep the correct mating pin length. Somehow I bumped off the AREF capacitors while modifying the board, but the card works otherwise.

    Noticed that the documentation sheet has errors in the layout figure (i.e. section 2). The 1339 version (i.e. number on the bottom of the sheet), has the 5V and 3.3V pins swapped, and both the 1339 and 1438 version has an extra pin labeled IO 26.

  4. Re: Biped Controller

    Been having a problem with my ST-Link/V2 probe and OpenCM9.04 controller where the ST-LINK utility software kept reporting "Connection to device is lost: ...".

    Turns out the diagram (see below) that ROBOTIS has for connecting the controller to the probe is wrong.

    Note that the controller can get power from either the probes pin 19 (i.e. 3.3 V) or an external source such as the USB port or a power supply.

    When the controller was connected to the probe as shown in the diagram, the ST-LINK utility would report a supply voltage of 1.6 V, but would not work reliably independently of the how the controller was powered.

    Turns out you need to connect the controllers 3.3 V pin to the probes pin 1 (i.e. MCU VDD), at that point the ST-LINK utility will report a supply voltage of 3.3 V (external supply) or 3.1 V (probe supplying) and will work reliably. Note to power the controller from the probe, just connect the probes pin 19 to the probes pin 2 (i.e. pins 1 and 2 are connected internally).
    Attached Thumbnails Attached Thumbnails Click image for larger version. 

Name:	opencm9.04_6.jpg 
Views:	4321 
Size:	69.4 KB 
ID:	5843  
    Last edited by vehemens; 02-24-2015 at 06:03 AM.

  5. Re: Biped Controller

    Quote Originally Posted by vehemens View Post
    Note that the controller can get power from either the probes pin 19 (i.e. 3.3 V) or an external source such as the USB port or a power supply.
    Took another look at the probe in terms of using it to provide power and found that unloaded it reads 3.28 V and when powering the controller it drops to 3.141 V. So as I've not found any information on max load in the probes documentation, I would advise caution when using the probe to power a device.

  6. Re: Biped Controller

    Now able to load the controller firmware (i.e. boot loader and a OpenCM program) using my Fedora system, openocd and a ST-Link/V2 probe.

    In addition, I can now build an OpenCM program on my Fedora system using make and arm toolchain.

    One annoying aspect of using the Robotis boot loader is that it sets the "Read Out Protection" bit.
    Last edited by vehemens; 03-01-2015 at 11:36 PM.

  7. Re: Biped Controller

    Took some searching but found the code for the two libcs3_stm32_XXX_density.a libraries (i.e. five source files and make file). Also got rid of startup_stm32f10x_md.c as it doesn't appear to be used anywhere.

  8. Re: Biped Controller

    Now able to run a subset of the DARwIn-OP CM730 firmware on a OpenCM9.04. Currently it's just the Dynamixel communication routines, but it's enough for most of the DARwIn-OP applications.

  9. Re: Biped Controller

    Was looking for a way to use NeoPixel strips and rings a while back and found a solution on GitHub. It's uses DMA and a timer to reduce processor overhead. Finally had some time to try it and now have it working with an OpenCM9.04, NeoPixel strip and level shifter (i.e. BSS138).

  10. Re: Biped Controller

    Got the STM USB VirtualComport_Loopback example (i.e. stsw-stm32121) running on an OpenCM9.04. Built it as a STM3210E_EVAL board as the documents were available (i.e. user guides, schematics, etc.). Only code change required was to switch the USB disconnect pin to GPIO port C pin 13.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Biped IK?
    By ArduTank in forum Mech Warfare
    Replies: 14
    Last Post: 07-17-2013, 09:01 AM
  2. My new biped
    By rebel in forum Humanoids, Walkers & Crawlers
    Replies: 97
    Last Post: 03-10-2012, 12:13 AM
  3. Biped. What Controller, Gyro, Pressure sensors to use?
    By kiwibrisa in forum Humanoids, Walkers & Crawlers
    Replies: 7
    Last Post: 05-28-2010, 05:19 PM
  4. ED 209 biped
    By 4mem8 in forum Mech Warfare
    Replies: 0
    Last Post: 01-20-2010, 02:16 AM
  5. Question(s) Motor Controller. Do I need a servo controller too?
    By kankatee in forum Arbotix, Microcontrollers, Arduino
    Replies: 7
    Last Post: 11-14-2008, 10:03 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •