Some kind of robot

Discussion in 'Embedded Systems and Microcontrollers' started by Klipeti, Aug 28, 2013.

  1. Klipeti

    Thread Starter New Member

    Nov 25, 2012

    Note that English isn't my first language :)
    I have plans on making a robot similar to Aperture Science Sentry Turret (from Portal game) and I'm looking for help with the project. I need help selecting programming platform, microcontroller etc. I think that MSP430 LaunchPad would suit my needs, but what about the microcontroller? And could my plan work?

    Here's what I think I need:
    -MSP430 LaunchPad ??
    -Motion Sensor to see movement
    -Distance Sensor to see if robot is picked up
    -Tilt Sensor to see if it is knocked over
    -Speaker for sound
    -Something to play sound, MP3 perhaps
    -LEDs for "eyes" and to look better

    Here's how I think it could function:
    -When nothing is triggered, it just stands still LEDs on.
    -When the Tilt Sensor is triggered, it should block rest of the program, play a random sound from selected list (MP3?). After it has been lying down for a while, LEDs are turned off. When it is standing again, LEDs are turned on and it plays random sound and program continues.
    -When Motion Sensor is triggered, robot says something from the MP3 files. It should block rest of the program until the sound clip is finished.
    -When Distance Sensor detects that robot is picked up, it play another random sound and blocks rest of the program. It plays random sounds every now and then until it is put down again. Then program continues again.


    Is this possible to make? Robot should be as cheap as possible too.
    Another thing worth mentioning, that every Sensor should have it's own set of sound clips.
    I live in Europe, so I prefer ordering needed parts from Europe.
    Also, it would be nice if you guys could suggest sensors/parts and tell me how I could make the robot even better.
  2. Shagas

    Active Member

    May 13, 2013
    No shooting enemies? 0.o

    Do you have any experience with mucrocontrollers ?
    The MSP launchpad uses ARM micros . I've never used one myself but from what I heard they are more difficult than 8 bit micros .

    The easiest will probably be to use an Arduino . It uses 8 bit micros and you don't need to learn too much about programming . It's basically a platform that makes life easier for beginners to micros .
    If you have no experience with microcontrollers then it's going to be quite a challenge Imo.

    So tell us, what experience do you have with electronics?
    This is the kind of project that interests me (escpecially since it concerns aperture :) )
    so I can help you out .
    Also , there is a forum that I found that deals specifically with robotics called .
    Haven't lurked around there too much though ...yet .

    Also , where in Eu are you from ? :)
  3. Klipeti

    Thread Starter New Member

    Nov 25, 2012
    I'm from Finland.
    I have basic knowledge and understanding of electronics, and I have used Matrix Multimedia Flowcode in programming so far. Infact, even better if I could do programming using Flowcode since I have experience with it.
    MSP430 is cheaper than Arduino, so I thought it would do the trick. I don't have much experience in complicated programming but I know how to make LOOPs, IFs etc basic stuff in C++.
  4. Alan brad

    New Member

    Aug 29, 2013
    HI shagas i am expert in micro controller field.hey what doubt u have? which microcontroller need for choose robot? i thing PIC and ARM controller is the best controller of robotics field!
  5. Shagas

    Active Member

    May 13, 2013
    Not Avr ? :)
  6. Shagas

    Active Member

    May 13, 2013
    Well as mentioned , you can do what you want on alot of diffrent micros .
    Start your programming and ask questions here when you run into trouble (which you probably will )
    Maybe someone more experienced will tell you that starting with ARM is not a very good idea.
  7. panic mode

    Senior Member

    Oct 10, 2011
    I don't see why using ARM would be bad idea. It is a powerful platform, low cost etc. One can get Discovery boards for $12-15 and have something that runs circles around any 8-bit platform (up to 168MHz, 32-bit, floating point, tons of IO...). But careful here... If your budget is sensitive, pay attention to cost of development tools because that is where most of your money goes. If you think some development kit sold for $50-200 is expensive, check the price for compilers/IDEs like uVision or IAR. That will make you quickly sober up and appreciate what TI has offered. There are free (open source) tool chains as well and they will not cost you a dime but it may take some effort to configure them.

    And if you think $5 spent on hardware is cheap while $25 is a lot, wait till you spend a month loosing hair and banging your head against the wall trying to resolve something that would not have existed if you only were not so cheap in the beginning and opted to spend the extra $20.

    As far as programming being hard or easy, I think there is no telling until YOU do it yourself. When I was kid, I learned to program in Pascal and later found C syntax to be clunky and awkward. When I started dealing with embedded systems, I found that using C is simpler because 98% is the same regardless of target platform while (at a time dominant) programming in ASM (while powerful) was clunky because it could be very different from platform to platform. In other words, at diffrent times i thought completely differently about one and same language (in this case C).

    I strongly recommend learning ASM (on any platform) just to get better understanding how hardware processes code. This builds indispensible knowledge of how to be efficient, what the limitations are etc.

    Using ASM is also recommended if working on one platform often enough and trying to get most out of it. C makes transition from one platform to another easier, things like math can be much easier (try to do some floating point math in ASM on an 8-bit micro or develop some fixed point math functions like 32-bit multiply or divide and you will see why). For someone who is just starting, such tasks are rather mundane, one would likely be much more interested in getting some results fast and slowly build on that experience.

    This is where Arduino comes in - it gives you opportunity to get something done without getting too deep on how things work internally. Before arduino, there were Basic Stamps (this is usually seen as even easier to learn but the overhead was larger). Arduino gives you also free software (TI software for MPS430 is also free).

    Finally if you are going to depend on support of others, it may be wise to stick to something many users are familiar with. In that case before choosing platform, check out microcontroller section and see for yourself which platform gets most usefull replies and code examples (not most traffic).

    And if you are interested in playing MP3s take a look at ICs with MP3 codecs. You can control them from any MCU. Another thing is where those MP3 will be stored. I hope you already realize that this is not going to fit in any MCU. You will need some flash card for storage - then you can just save the MP3s there using computer (easy to try different things) and use MCU only for playback. But that brings more things to look after - need to use FAT file system. Usually the flash is in form of SD card. This means only few IO needed for interface (compared to CF) and compact size.
    Last edited: Aug 29, 2013