29 April 2012

Creating a Range Map

So, the first thing I though about for my swarm project, after getting through all the wifi tutorials (actually, I have another week to go, now that Dexter Industries Wifi Week 2 is out), is having my main, user controlled (or autonomous, using AI algorithms if necessary) be able to know it's surroundings. Now, I could use my NXTCam v3 and transmit a video feed to the user, but that would be an expensive option (okay, maybe on-board cameras are not expensive in the real world, but scaled to my project, they are expensive). In swarms, cheaper is better. So, I decided to try and use the ultrasonic sensor and create a "range map" of its surroundings. This would a much cheaper solution, although it sacrifices more user information. Nonetheless, I tried it out.

21 April 2012

Wifi Working

Well, after extensive emailing back and forth with the Dexter Industries guys, I was able to get my DI Wifi Sensor working. So, I will drop the project I posted last time to give more time back to the real project.

However, if anyone wanted to know how my last project was coming along, HERE is the code/LDD  for it.

For the robot, you'll need to modify it a little for the caster ball section, switch the light for a color sensor, and add a gyro sensor for more precise turning.

11 April 2012

New Project Flow

This is the flow chart I made for my next project. It will consists of 3 robots, each with a specialty, and will work together to achieve a goal (in this case, getting the red object).
Here is an LDD for my first robot, with the Light and US sensors (the ball acts as a caster that should be under the NXT between the motors):

Again, the files for the LDD are available HERE

06 April 2012

Running a Maze-Sensor-LESS

The joy in swarm robotics is that many cheap robots can run together to achieve a goal. These "cheap" robots do not have many complex sensors and cameras because each receives information from the other, or does a separate task. One may have a camera to relay positions. The other merely as wheels, yet acts as checkpoints. The third will have simple claws to grab things. Alone, they are useless; together they are a remarkable team.
See THIS video to understand what I am talking about.

Why the nice intro? Well, it was a segway to my project I just completed. It is comprised of two robots: 1 with a UltraSonic sensor, 1 sensor-less. The first completes the maze, all the while sending information to the clone robot about movements and turns. Then, the clone runs it, no problems. See for yourself:

Here is a pic of the robot with the US sensor. If you see my previous post, you can see the clone (it is the same model).

The code for this project is available HERE
That about wraps it up. Till my next project.

15 March 2012

Moving in a Shape: Basics of Bluetooth

Well, I decided to do some work on bluetooth messaging so that I when it comes time to real swarm algorithms and such, I won't have to keep referencing guides and stuff for how to send and receive messages. So, I designed this little program that, on the master:
  1. Opens a bluetooth connection with the slave.
  2. Runs a designated shape path (triangle, square, decagon, etc);
  3. Sends the total degrees turned by the right wheel (total encoder reading)
  4. Quits the program.
Meanwhile, the slave:
  1. Receives the encoder rotations
  2. Runs through a loop that does the number of turns and straight runs = to the number of turns encountered by the master which is sent to the slave
  3. Disconnects from the master
  4. Quits
Here's a little video:

Note: I realize the shapes aren't perfectly normal, and that the slave ends up in a different orientation than the master. I realized what was going on after I taped this, and I didn't feel like doing it again, but I will explain why. After each turn/straight, I had the master and the slave wait for 50 milliseconds, but I forgot to state motors A & B should be = 0, so there was a minor rotation error. Because the slave had a battery on max charge, it rotated more through those 50 milliseconds than the slave did, which had a mere 6.2 volts of battery. And there you have. An explanation for the discrepancy.

Here are some pics, in case you want to see how the robots are built:

Later on, I'll make a post on my Projects tab for this project. Until next time, then.

12 March 2012

Slowly, but Steadily

Well, 3 months have passed, so I'll tell you what's happened.

A bunch of coding for drivers has been done in NXC by Matt Allen after a very nice, long chain of responses on the Mindboards forum from my original post. It's good to know the NXT community caters so fast to people who are in need of help.

Meanwhile, I was also trying to follow Dexter Industries Wifi Week tutorials on using the Wifi Sensor. However, those were unsuccessful right from the start too. I keep getting an "unexpected warm boot (possibly low battery)" error. However, I am currently talking with a DI professional, so hopefully, everything will work itself out.

Apart from all that, I was getting down the basics of bluetooth. In RobotC, I whipped up a quick remote control program that allows me to control the speed of another NXT vehicle with a Ultrasonic sensor and can make it turn left or right with the arrow keys. So that's definitely a start. I think I'll be focusing more on the swarm aspect of the project through bluetooth for now, staying in the autonomous realm. Later, when I get the hang of the Wifi Sensor, I'll make the shift to a user controlled swarm.

In other news...

I recieved an NXT omniwheel keychain courtesy of Xander. I was one of the three winners in his NXT haiku contest, which was pretty neat.
You can his post HERE

There is also a chance to win a free DI dCompass sensor.

Just head on over to the Guy NXT door blog and subscribe, and you'll be entered in a random lottery for the dCompass sensor. His blog is HERE

One last thing before ending this post. My team recently competed in the FTC State Championship last weekend. We were 3rd in the 5th round, but after the 6th, we dropped to 7th. However, the 3rd place team did choose us as their alliance partner. Therefore, when all is said and done, you can say we safely came in 3rd place.

And that about wraps it up. Till next time.