Let's Make Robots!

RPi - Arduino - iPad robot

Obstacle avoidance and streaming video (someday soon)

http://pinkypibot.blogspot.com/

Here is a link to my blog that has a lot of project details. Current code available as txt files Arduino and Python.  UPDATE 08-19-2013: I now have the iPad app (RasPiConnect) operating and the bot doing basic obstacle avoidance. Integrating camera next, then some OpenCV processing.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
I'm using 8 x AA NiMH rechargeables for the motor drivers and they seem to drain pretty quick...is that normal?

What is the mAh rating for the cells? It must also be the same rating for each cell or bad things happen :P

Also what current draw are you getting from your motors and the rest of the system?

That will give you a clue as to what battery life you can expect.

 

 

Simply put. If you have a 1000mAh (or 1 Ah) battery, it will supply 1000mA of current for 1 hour or 500mA for 2 hours, or 2000mA for half an hour.

Most cheap NiMHs are 1300, a few 2200's around for a bit more. They go higher.

 

I know you have a seperate battery for the pi and arduino but lets go with that for an example. Your diagram on your blog marks the battery as 2.1A, I presume that it actually means a 2.1Ah battery or 2100mAh. The raspberry pi alone tends to draw about 500mA on its own (no peripherals like mice, keyboards or sensors that are powered from its GPIO. Ethernet and HDMI tend to shoot that up too), in reality your looking at 750mA to 1000mA for the pi B when its hooked up with a mouse, keyboard, HDMI display and ethernet and your using it as a mini PC. Lets go with it being 750 (I have no idea what it is using in your scenaria, I have run mine "headless" with SSH access from a 750mA supply though quite reliably, also had it booting headless from a USB port at 500mA but it did eventually crash when I told it to compile some code). 2100 divided by 750 = 2.8. So you can expect the pi to run for 2.8 hours before shut down.

 

 

 

Hopefully that helps.

It never occurred to me that the NiMH cells might have different ratings, they are all the same brand, but sure enough, 4 are 2500 mAh and 4 are 2100 mAh. The way my system is wired (poorly, by me) it's hard to get a meter on it for the total current draw from the NiMH pack. But I managed to get some readings between the pack and the first h-bridge which also supplies the 5v to the Arduino. With the motors stopped, the draw was ~60 mA and with the motors running at half speed it was ~360 mA. So I'm guessing the total draw for both h-bridges is ~700 mA. Does this make sense or do you think I got bad readings? That was all with the wheels free spinning. The RPi is powered by a dedicated rechareable LiPo with multiple USB outputs. Each USB output can deliver up to 2.1A at 5V up to a total of 2.5A and it's ~8000mAH. So I should have enough power for both. Does this sound about right? Maybe the different ratings are doing bad things?

hi

i am working on similar project.i decided to start with inexpensive parts. i am using chassis , which has 4 dc motors each rated as 3volt and 170mah stall current. as a motor driver i am using 2 dual h bridge motor driver , which can run from 6-35volt and provide 2A per channel i do have a 5v/6v voltage regulator which will power my arduino and raspberry pi. the lipo battery i am using is of 11v 2200mah: now i am confused because i am afraid that using 11v lipo for 3v motor might fry the motor? is it safe to use 11v lipo for four 3v motor's even though the lipo power is given to motor driver (i am not sure whether motor driver has any inbuilt regulator to handle such scenario) which gives power to motor. do you think that 11volt 2200mah - can run raspberry pi, arduino and motor all together for sometime?

 

This isnt the right place to be asking this kind of question. Really for your own problems you go to your own forum thread. However this one could have been answered in the shoutbox.

Answer is no. Not safe to run a 3v motor on 11v at all. The motor driver will output whatever voltage you put in. So 11v will be supplied to your 3v motors and they will possibly be killed (or just spin really fast, but most likely killed)

 

For the pi. You MUST use a 5V regulator. Anything else will kill it. From 11v I would use a switchmode from 11 to 6 or 7v, then linear the rest of the way. Unless this is what you meant by a 5/6v regulator in the first place.

 

4 * 170 = 680.

Add in 750mA for the pi (as we are only making an estimate on the run time I think it is satisfactory to estimate pi at 750).
680 + 750 = 1430.

And then if we round that to 1500 that should account for the arduino, the fact that the pi wont always be using 750 and the motors not always being at stall (or even running) so not having a constant draw of 680.

 

2200 milliamp hours/ 1500 milliamps = 1.47 hours. That is entirely an estimate. The best way to make a prediction is to take a multimeter, set it to record current and then record the current draw of your robot from the battery (not at the motor driver or pi etc). Use that value instead of 1500mA. Of course that requires you to have your robot already functioning.

 If you put 2 batteries in parallel (not saying that you should at this moment in time) you effectively double the run time. Just an FYI for if you absolutely must have a longer run time in future.

Just play nicely with that LiPo :D

 I would choose new motors if I were you. 3v motors drawing just 170mA at stall, sound a bit weedy, might not shift the bulk of the pi. Not to mention the fact that your going to kill them. I would double check that the rating you have provided is actually correct, and if it is, new motors.

there were typo in spec , it is actually 6v motor which draws 1.7A. russel (oddbot) pointed out that 

http://www.hobbyking.com/hobbyking/store/uh_viewItem.asp?idproduct=26250

i will buy a 7.2 lipo and regulator for Rpi & arduino and possibly use 4*AA battery to power the motors.

Hang on, is the type "3v" instead of 6?  

I just hope your motor isn't drawing 1.7A :)

I'm actually evaluating RasPiConnect app and server for the iPad interface now. It seemed a bit easier than NetIO but we'll see. I have the Pi and iPad talking but haven't had time to integrate the robot commands into a UI yet.
RasPiConnect up and operating. Controlling bot from iPad and displaying sensor data and camera stills. Using time lapse in Raspistill saved to a file that RasPiConnect sends to the webview on the iPad. Problem is the refresh rate is limited to 3 sec or more so it's not optimum but it works. I may try using safari for a video stream and RasPiConnect for controls.
Awesome. So I assume you were able to solve the i2c issue? And I'm guessing it was my pooish attempt at threading? I can't wait to see y'all get the NetIO up.