Recent Posts

Pages: 1 ... 4 5 6 7 8 ... 10
Software / Re: MD25 Motor Driver encoder read problem
« Last post by Webbot on December 06, 2014, 08:16:32 AM »
Both those algorithms look ok and are effectively doing the same thing. The first one shifts they byte to the right place before adding to the result. The second adds each byte into the result and repeatedly shifts the result - ie the first byte will get shifted 3 times and 3 x 8 = 24.

You dont say what libraries you are using eg WebbotLib, WebbotLibStudio, Arduino, Atmel AVR Studio 6, WinAVR. or something else.
The reason for asking is that you may actually be building up the 'long' ok - but falling down in the way that you are trying to print it as a number over the USB port. So would be interesting to know how you are doing that.
Electronics / Re: Starter Kit
« Last post by BenBilly on December 06, 2014, 05:06:18 AM »
So does this kit have the ability to have more sensors added at a later date?:

I have been also looking at this bot which is more about programming because its already built is there another kit like this but cheaper?

Thanks again,

Software / MD25 Motor Driver encoder read problem
« Last post by helicopter on December 05, 2014, 10:00:19 PM »
Hi Guys

I am having troubles getting the motor driver to read the encoder for a EMG30 motor from Devantech.
All other data requests can be returned to USB to display on hyperterminal no problems but when it comes to receiving 4 bytes of data I am stuck!
I have tried most options (arrays, etc) but have yet to crack it! I am missing something.  I have searched and used other examples from the internet all without success.

The Data sheet for the MD25:

When a read encoder command is issued the MD25 will send out 4 bytes high byte first, which should be put together to form a 32 bit signed number. For example a GET ENCODER 1 command may return 0x00,0x10,0x56,0x32.

So declare a 32 bit signed variable in your program, for C:
long result;
 result = serin() << 24;    // (0x00 shifted 24 bits left, effectively * 16777216)
 result += serin() << 16;   // (0x10 shifted 16 bits left, effectively * 65536)
 result += serin() << 8;    // (0x56 shifted 8 bits left, effectively * 256)
 result += serin();         /  (0x32)
result now equals 1070642 decimal or 0x105632 hex. If the highest bit was set then it would be -ve.
 read encoders will send encoder count 1 and then encoder count 2 but is put together in exactly the same way. The registers can be zeroed at any time by writing 0x35 to the MD25.


The encoder read function example from for serial connection is

long readEncoder(){                        // Function to read and display the value of both encoders, returns value of first encoder
  long result1 = 0;
  long result2 = 0;
  while(Serial.available() < 8){}          // Wait for 8 bytes, first 4 encoder 1 values second 4 encoder 2 values
  result1 =;                 // First byte for encoder 1, HH.
  result1 <<= 8;
  result1 +=;                // Second byte for encoder 1, HL
  result1 <<= 8;
  result1 +=;                // Third byte for encoder 1, LH
  result1 <<= 8;
  result1  +=;               // Fourth byte for encoder 1, LL
  result2 =;
  result2 <<= 8;
  result2 +=;
  result2 <<= 8;
  result2 +=;
  result2 <<= 8;
  result2 +=;

A month of failures and I have no other option but to ask for help!

Does anyone have a code for this function to use to grab 4 bytes of data and return a value for use as a counter to get a motor to stop at a given angle!
I am using the Axon 2 with the Devantech MD25 driver.

The joys of programing!
Otherwise the Axon 2 is a great piece of kit, 5 stars for that bad boy SoR!!

Thanks Heli

Electronics / Re: Starter Kit
« Last post by Schlayer on December 05, 2014, 09:04:42 PM »
There are about 100 kits out there, a few in that price range. Of those that immediately come to mind...
Arduino kit - micro controller, involves programming and building from bare component kit parts.

VEX kits - a bit out of your price range but they use a system like an erector set and are thus modular and easy to build hardware wise. Designed rouse RC controller or programmed automation. Many variations.

OWI Kits - dirt cheap, but you get what you pay fore. Easy to assemble cheap plastic parts, the servers are slow and not too powerful, but it's OK to learn from for a first time roboticist.

Lynxmotion kits - bridging the gap between VEX and OWI, these use similar construction to OWI with the quality and similar price range to VEX. MANY different project options, be careful of 'sold separately' and 'hardware only' lables. (very pricey)

Radioshack's Make-It Kit - not too expensive and MAKE is usually pretty sweet for beginners, though you need the Arduino Uno rev 3 sold separately which rounds out the price to about $100 USD

I hope one of those helps!

Mechanics and Construction / Re: Making an impossible to juggle juggling club
« Last post by Schlayer on December 05, 2014, 08:16:42 PM »
I am unsure what exactly the benefit of a linear bearing might be; I have a feeling that given the right sized, properly smooth dowel, or even a relatively loosely sized (as in a considerably smaller diameter than your rings' internal diameter) rod, might prove to have a very small frictional effect on a magnet. The magnet will likely be made out of something like neodymium which itself is quite smooth in my experience, and strong enough that even considerable friction tends to be negligible compared to the forces between two of such magnets. That said, it can't hurt to cover your bases by getting something which would sill leave space for a linear bearing if need be.
Electronics / Starter Kit
« Last post by BenBilly on December 05, 2014, 02:51:30 PM »
I'm sure you've been asked this a lot so I'm sorry to be another who ask but I'm looking to buy a robotics starter kit something that I can experiment with and gain experience. Currently I'm studying electronics at A level and have studied pic tutor and ladder logic programming languages now i don't know if these are used in robotics but anyway is there a kit with loads of different parts in which i can possibly program to do different things because i love programming at the minute in computing and electronics I'm willing to pay up to/around 100 in price.


Electronics / Re: Audio Robots...
« Last post by Webbot on December 05, 2014, 01:57:56 PM »
The SOMO14 board is good for replaying recorded sounds from a microSD card - and is small. Gives you about 250 pre-recorded tracks to play back (limited by size of the SD memory card) and is simple to use,  Speech synthesis (for an unlimited vocab) is harder - WebbotLib has one - but it is retro sounding - see and click the links for output examples.
Mechanics and Construction / Re: Making an impossible to juggle juggling club
« Last post by MrPrezident on December 04, 2014, 04:36:30 PM »
I'm wondering if I should get some linear ball bearings for this.
Mechanics and Construction / Re: Making an impossible to juggle juggling club
« Last post by MrPrezident on December 04, 2014, 01:34:38 PM »
Hmm... that's a good point that the position of the weight would probably influence the club more than the club would influence the position of the weight.  Now I am very confused as to what would actually happen.  I still suspect that the system might come to some sort of equilibrium, but if it doesn't that would be really cool.  It is worth a try :)
Electronics / Re: Accelerometer/gyro data to serial port using bluetooth.
« Last post by Gertlex on December 03, 2014, 10:31:51 AM »
Resistors for what?

Your interface would be:
MPU6050 --i2c--> RFDuino --???--> Primary data recording device.

You can't communicate with the MPU6050 via serial, as far as I know. You would almost definitely use this library on the RFDuino, which manages the i2c to the MPU6050 for you:

Looks like if you use a LiPo, you would need a regulator such as the one I linked in my previous post, since LiPos get up to 4.2 V when fully charged. If you can find a LiFePo4 battery of the desired form factor (I couldn't find one on ebay/hobbyking just now), that would allow you to directly power the RFDuino. The power input limits on the MPU6050 may also need to be considered.
Pages: 1 ... 4 5 6 7 8 ... 10

Get Your Ad Here