Category Archives: Arduino

Working with the SainSmart 5v Relay Board

Today we are working with our SainSmart 5v Relay Board. This is a simple and inexpensive 4 port SPDT relay board (there are boards with more or less relays)  that takes a digital signal (LOW) from the Arduino, through an optoisolator, which triggers a transistor, pulling in the relay. The relay contacts are rated for 10 amps at 120/240vac, and 10 amps at 30vdc or less.
IMPORTANT!
The contact pins are not numbered, and are reversed if you go by what the schematic appears to be saying. Facing the screw terminals, with the board face up (solder side down), the screw terminals are as follows (from left to right):
K4
1 – Normally Open
2 – Common
3 – Normally Closed
K3
1 – Normally Open
2 – Common
3 – Normally Closed
K2
1 – Normally Open
2 – Common
3 – Normally Closed
K1
1 – Normally Open
2 – Common
3 – Normally Closed
When you send a logic low, that turns on the LED, and energizes the coil. However, a disconnected input will drop out the LED and the coil, as will a logic HIGH. We will send a logic HIGH in setup to ensure the relays are disabled on boot.

There is a 6 pin male header, so you will need a cable or female pins to slide over the header to connect it to your Arduino. Pin 1 connects to Arduino GND, Pins 2-5 to Digital output pins, and Pin 6 to Arduino 5v. A red LED for each relay lights when active (LOW).

int relayPin1 = 7;                 // IN1 connected to digital pin 7
int relayPin2 = 8;                 // IN2 connected to digital pin 8
int relayPin3 = 9;                 // IN3 connected to digital pin 9
int relayPin4 = 10;                // IN4 connected to digital pin 10

void setup()
{
pinMode(relayPin1, OUTPUT);      // sets the digital pin as output
pinMode(relayPin2, OUTPUT);      // sets the digital pin as output
pinMode(relayPin3, OUTPUT);      // sets the digital pin as output
pinMode(relayPin4, OUTPUT);      // sets the digital pin as output
digitalWrite(relayPin1, HIGH);        // Prevents relays from starting up engaged
digitalWrite(relayPin2, HIGH);        // Prevents relays from starting up engaged
digitalWrite(relayPin3, HIGH);        // Prevents relays from starting up engaged
digitalWrite(relayPin4, HIGH);        // Prevents relays from starting up engaged
}

void loop()
{
digitalWrite(relayPin1, LOW);   // energizes the relay and lights the LED
digitalWrite(relayPin2, LOW);   // energizes the relay and lights the LED
digitalWrite(relayPin3, LOW);   // energizes the relay and lights the LED
digitalWrite(relayPin4, LOW);   // energizes the relay and lights the LED
delay(1000);                  // waits for a second
digitalWrite(relayPin1, HIGH);    // de-energizes the relay and LED is off
digitalWrite(relayPin2, HIGH);    // de-energizes the relay and LED is off
digitalWrite(relayPin3, HIGH);    // de-energizes the relay and LED is off
digitalWrite(relayPin4, HIGH);    // de-energizes the relay and LED is off
delay(1000);                  // waits for a second
}

read more: http://arduinotronics.blogspot.com/2013/01/working-with-sainsmart-5v-relay-board.html

Advertisements

The 5 best Arduino books

Whether tackling a new hobby, prototyping a product idea, or simply satisfying your curiosity, the world of Arduino offers a wealth of possibities.  The best way to dive in is with the right resources in hand, so EngBlaze has picked five of the best Arduino books out there to help you brush up on your skills.  Each book caters to different topics and skill levels, so check out our summaries to see which one is right for you.

Beginning Arduino

Michael McRoberts

Beginning Arduino by Michael McRobertsMost Arduino books take one of two approaches.  Some treat every new concept as individual module and present examples that are effective but simple and self-contained.  These help you learn, but can be a bit dry, and often don’t include valuable real-world application notes.  Other books take the “giant staircase” approach, where they introduce concepts one by one as you construct a complex example project.  This is useful and often more fun, but what if you don’t want to end up with a tweeting, GPS-enabled, cellular connected kegerator?

Beginning Arduino is different in that each example builds off one another, but still includes new considerations that help you apply each concept to your own ideas.  The book is extremely well-reviewed on Amazon, and readers say it provides the perfect beginner angle without any coddling.  It’s also best for hackers who have never used Arduino or other microcontrollers before, but have some sort of basic programming experience (can be any language).

Get the book here: Beginning Arduino (Amazon)

Arduino Cookbook, 2nd Edition

Michael Margolis

Arduino Cookbook by Michael MargolisThe Arduino Cookbook, published by O’Reilly Media, is a huge resource for those looking for an introduction to Arduino and physical computing.  We say huge quite literally, as this tome clocks in at 680 pages in the paperback version.  It covers everything from setting up the Arduino programming environment on multiple operating systems, through tothrough basic programming concepts, Arduino shields, and various types of possible input and output.

Filled with tons of recipes and example projects that are relatively self-contained, the book is best used as a reference and as inspiration for code and project ideas.  There are illustrated examples for outputs such as lights, relays, buzzers and speakers, and inputs such as GPS, remote controls, and various sensors.  It also covers valuable communication topics such as ethernet, RFID, and wireless networks, so you can get your Arduino talking with the outside world.

If you’re already an experienced programmer and are just looking to figure out the differences between Arduino and other platforms, the Arduino Cookbook probably isn’t for you.  However, if you’re new to the awesome world of robotics, embedded systems, and DIY electronics, the Cookbook will keep you occupied for a long time.

Grab it here: Arduino Cookbook, 2nd Edition (Amazon)

This version has been updated for the Arduino 1.0 release, so it will include all the latest changes.  It was published on December 30th, 2011.

30 Arduino Projects for the Evil Genius

Simon Monk

30 Arduino Projects for the Evil Genius by Simon MonkSimon Monk gives Arduino newcomers a walkthrough that goes further than “Getting Started With Arduino”, but still covers each topic in a very accessible way.  He also takes example projects beyond the workbench and includes helpful considerations to how you might want to implement them in the real world.  For example, the book has the obligatory “blink a LED” example, but then goes on to modify the circuit for high power LED’s that you can use in various applications.

The projects are fun and creative, including a servo-controlled laser, lie detector, magnetic door lock, and more.  Each example has a full schematic, parts list, and example code to get your rolling quickly.  If you’re looking for your next step in Arduino world domination, check this book out.

Find the book here: 30 Arduino Projects for the Evil Genius (Amazon)

Getting Started with Arduino (Make: Projects)

Massimo Banzi

Authored by Massimo Banzi, a co-founder of the Arduino platform, Getting Started with Arduino provides a great answer to “What is Arduino?”, with history and a full overview of the Arduino hardware and software.  Banzi is an expert in interaction design and obviously knows the platform he invented inside and out.  You won’t find a lot of advanced programming concepts contained within, but armed with this book, an Arduino board, and some basic electronic parts, you’ll be able to get a thorough introduction to what’s possible in the the microcontroller world.  This is the 2nd edition of the book, recently updated for the release of Arduino 1.0.

Snag the book here: Getting Started with Arduino (Make: Projects) (Amazon)

Building Wireless Sensor Networks: with ZigBee, XBee, Arduino, and Processing

Robert Faludi

Building Wireless Sensor Networks: with Zigbee, Xbee, Arduino, and ProcessingReady to take your microcontroller skills to the next level?  Arduino is a fantastic platform for sensing and data collection projects.  For extremely low time and cost investment, you can monitor your home’s energy use, track weather data, record the position of a vehicle or important possession, and more.  The question is: once you collect this data, how do you get it from the Arduino back to you?

Increasingly, wireless communications are the answer.  Building Wireless Sensor Networks is a top to bottom introduction to low power and low cost wireless using Arduino.  Zigbee is a point to point wireless networking protocol that is excellent for creating mesh networks – networks where every device can communicate with every other, and don’t require a central connection point.  Xbee is a line of popular radios that use this protocol.  The book walks you through setting up a network, exploring the Xbee API and firmware options, and starts you down the road of creating your own wireless projects.  Networking is a tricky topic, with lots of obscure settings and tricks to worry about.  Armed with this book, you’ll be up and running in no time.

Buy the book here: Building Wireless Sensor Networks (Amazon)

Advanced reader bonus: Arduino + Android Projects for the Evil Genius

Simon Monk

Arduino + Android Projects for the Evil Genius by Simon MonkThe second book on this list by Simon Monk, Arduino + Android Projects is for the hacker who is ready to step into the world of advanced electronics.  Once you’ve mastered basic projects, you may want to try your hand at getting your microcontroller projects talking to another mobile device.  Maybe you have an idea for an app+sensor prototype and want to test it in the market.  Or maybe you want to build amazing robots that are controlled via your phone.  If any of this sounds appealing, this book is for you.

Written in an inventive and creative style, the book covers advanced Arduino topics and gives an introduction to the Android Open Application Development Kit (ADK) that allows your phone to talk to external devices via USB.  It also discusses wireless methods such as Bluetooth and Wifi.  The previously mentioned Building Wireless Sensor Networks will get your Arduino talking over the air, but if you want to interact with projects anywhere using mobile devices, check this one out.

Buy the book here: Arduino + Android Projects for the Evil Genius (Amazon)

Read more:http://www.engblaze.com/best-arduino-books/

Ferrofluid Arduino Project

Just enjoy the show!!

Show Time!! Have Fun with Arduino

il_570xN.402083863_olyf il_570xN.402090812_bd25 il_570xN.402121881_6zoh il_570xN.402121947_ek5z il_570xN.402128692_71ii il_570xN.402592960_tims il_570xN.429069609_fww8 il_570xN.468532182_59uu il_570xN.402592960_tims il_570xN.468532182_59uuil_570xN.511540387_mwbg

you guys can find all those items here:http://www.etsy.com/sg-en/shop/HardResols?page=3

Temperature Control (ST7735 TFT Display + Arduino + PT1000 )

This project was set up by a fan of sainsmart named Dieter. In this project, he has used the SaintSmart 1,8″ TFT.

Let’s check how did he make it.

New Project – Temperature Control (ST7735 TFT Display + Arduino

+ PT1000 )

Hi @ll,
I have started a new poject…….
A friend ask me  to build him a temperature control unit for his home brew beer production. 🙂
This control unit should be able to hold the temperature of a fluid on a defined temperature level and control the heating of the fluid tank.
The heating element of the tank has a power of 1800W.
To control it, I will choose for this task a 20A relay.
My Setup:
  • SaintSmart 1,8″ TFT ( similar to the adafruit TFT) – useing the adafruit libraries (ST7735 and gfx)[click]
  • Arduino mini pro 328
  • PT1000 with a Hygrosens PT-MOD-10V-T2 0 – +160 °C converter unit
During implementation of the firmware I decided also to create a framework for this wonderfull TFT Display useing the Adafruit libs.
With this framework you will be able to setup very quick and easy complex graphic objects on your HMI ( TFT Display ) like Symbols,Textfields, Leds, Bargraphs and many more.
Each object has several defined functions to parametrization e.g foreColor, backColor,Text,max min Values, update an object, write a value to a object or toggle it synchronized by time. ( e.g the framework should have a similar usability like working in a modern IDE like Visual Studio .NET)
So a full working Bargraph is only some rows of code in your arduino sketch, because the working code is stored in a C++ class in my framework.
A little overview about this framework you can see in the enlosed video.
The next picture will give you an overview about my HMI screen (HMI HumanMachineInterface)
  • First row the Header Text is displayed – here the name of the application
  • 6 Symbol
    • R … RUN Mode => this symbol will toggle between green and black once a second(the time is variable to define )
    • P … Programm Mode => this symbol is static if you are in program mode
    • A … Automatic Mode  => this symbol is static if you are in automatic heating mode
    • m … manual Mode      => this symbol is static if you are in manual heating mode
    • H … Heating                => this symbol is static if the heating element is on
    • E … Error                   => this symbol is static and shows that warning or error  occur
  • IST Temp = actual temperature ( e.g here 51°C – its only sample  here)
  • ZIEL Temp = target temperature ( e.g here 20°C – its only a sample here )
  • dT = delta temperature – this will be the lower power up position of the heating element. If the actual temp. is bigger than the target temp. the heating element is switched of and turns on if actual temp. is lower than target temp minus dT
  • on last position a Bargraph of the actual temperature is displayed with the maximum and minimum values
I going to report more details about this and especialy the HMI Framework soon.
Enjoy it 🙂

HUMAVIPS robot finds you in a party

What makes a good friend? All right. Ability to recognize a number of other people, from These are the social skills of a team of researchers has given operating system € 2.600.000 € of funding from the European Commission sought to create in three years for new Arduino robot.

high quality arduino robot kit,6wd robot chassis online for sale.

“Humanoids with hearing and visual abilities in populated” project to test new ways to help the autonomous mobile robots to mimic the social skills that we can “cocktail effect” or the ability of a person or a lone voice among the noise and called several other people. In the past there were many best arduino robots with any type of voice or facial recognition software, but it has a different level HUMAVIPS robot. The ability to focus on one person, this type of system a large group of data that could be something specific to focus on just the next step in the direction of anthropomorphic robots.
High quality 4wd arduino robot kit with Omni-directional wheel
Another way to understand this robot is able to communicate with friends and maybe people gestures. Project Director and Director of Research INRIA, Radu Horaud, he explained, as shown by neurophysiological experiments, exercise activates the auditory areas of the brain. Wholesale arduino robot with an emphasis on his words with gestures is one thing that is not given much importance in the past, and add an interesting dynamic interaction between humans and robots.
2wd arduino robot kit,3-wheel robot chassis
As Horaud reveals the goal of all of these studies is to determine ultimately HUMAVIPS robots in a room full of people to enter and be able to be the voice of one, select the person you want to talk to him, we are focused on themselves and go to the development of communication involved. To achieve this goal, it is much more complicated than that, but what I think people think it’s not so easy to get the other.

read more: http://www.mhobbies.com/blog/humavips-robot-finds-you-in-a-party-2/

Top 10 DIY Arduino Projects and HOW-TO Tutorials!

Arduino has been widely popular among hackers and DIY-addicts out there for modding/hacking things.

For those of you just entering the Arduino world, here’s a bunch of great Arduino tutorials/projects that can help you jump-start your next project.

1) Did you know that you can program/flash your Arduino wirelessly?  For those of you who are going to be making devices where the Arduino is hidden from easy access, read up on how you can program your Arduino wirelessly using Xigbee modules over at Lady Ada’s site.

https://i0.wp.com/www.ladyada.net/images/xbee/ftdipowered_t.jpg

2) Arduinome is a project the Monome for audio sequencers.  Theses are minimalist input for any Arduino project so I think this is a great device to add-on to your project, even it’s not audio-related.  You can see an example of how Arduino is applied to a project here as a pocket jammer.

https://i0.wp.com/farm3.static.flickr.com/2485/3979704894_e356e4934c.jpg

3) For energy eco-projects, you can refer to this great site on OpenEnergyMonitor, which uses Arduino and complete details are provided for making your own home energy monitor.  Of course, I am sure you can apply energy monitoring to anything else that matters to you.

https://i2.wp.com/openenergymonitor.org/emon/sites/default/files/display.jpg

4) DIY Arduino Earthquake Seismic Detector can actually detect earthquakes, perhaps great for any project requiring sensing of vibrations and whatnot.

https://i2.wp.com/zedomax.com/blog/wp-content/uploads/2009/11/seismic-diy-1.jpg

5) Need some resources on robots using Arduino?  Check out George Frick’s Arduino Tank Robot.  Robots can be great ways to learn about sensor implementation and general Arduino programming.

Also see RC lawnmower using Arduino and the solar lawnmower.

https://sainsmart.files.wordpress.com/2013/10/a0ad0-wanderingtankfinal.png

6) If you are a total newbie and you have no programming/soldering skills whatsoever, I highly recommend Lady Ada’s starter kit ($65). This can get you started learning basics of Arduino and making small LED projects.  (Sparkfun also has these for $59.95)

Of course, if you want to jump-start into robotics with Arduino, Maker Shed has a great Arduino-controlled Servo Robot Kit for $175 here. The Pop-Bot Robot Kit is another one you can get but be aware, it doesn’t come with Arduino, you will have to buy them separately.

https://i0.wp.com/www.adafruit.com/images/medium/starterpax_MED.jpg

7) Arduino is great because there’s so many tutorials to help you get started on hacking.  One of my favorites is this brain-controlled Star Wars Trainer device coupled with Arduino to build a brain-controlled device.

https://i2.wp.com/zedomax.com/blog/wp-content/uploads/2009/10/brain-arduino-hack.jpg

8) For chemistry lovers out there, you might want to start your Arduino adventure with this pH meter, which can be great for automating your pool pH balancing.

http://zedomax.com/blog/wp-content/uploads/2009/09/ph-meter-hack.JPG

9) The Magic Mirror is one of my all-time favorites.  This is a fairly complex project involving many things but once you master Arduino basics, you might want to tackle big projects like this one. You can buy the kit here.

https://i1.wp.com/zedomax.com/blog/wp-content/uploads/2009/07/diy-mirror.jpg

10) The RGB Color Table is probably something I will personally make someday.  This one uses Arduino and can even play the game Tetris!  How cool is that?

OMG, there’s so many more Arduino projects you need to check out.  We have about a hundred of them featured here on Zedomax.com, check out our Arduino section here.

read more:http://zedomax.com/blog/tech/top-10-diy-arduino-projects-and-how-to-tutorials/

The top 5 Arduino projects for advanced hackers

As the Arduino surges in popularity, people keep dreaming up crazier and more complex ways to use it. We’ve rounded up five of the most impressive Arduino projects on the web to show what’s possible with such a versatile and inexpensive platform. Be warned – these projects aren’t for beginners, but if you’re looking for a challenge and something to brag about, they could be just the ticket.

Click any item on the list to jump to the relevant section:

  1. Open Energy Monitor – Build a home energy monitoring system
  2. OpenMoCo – Make automated camera control rigs like the pros
  3. DIY Drones – Fly an unmanned aerial vehicle
  4. DIY Magic Mirror – Create a cinema-worthy prop
  5. Arduino beer brewing – Get yo’ geeky drink on

Open Energy Monitor

Open Energy Monitor is an open source energy monitor for use throughout your entire house.  Much more than just a quick circuit you slap on your utility meter, OpenEnergyMonitor consists of multiple components that work together to take readings on energy consumption by room or device, room temperature, and more, then feed all of it wirelessly back to a dashboard that can be displayed locally or through a web interface.

We like Open Energy Monitor a lot because it’s a great introduction to real-world systems. When you build a home monitoring or automation platform, you’re using your Arduino as part of a larger network rather than just a standalone device.  Learning how to get your microcontroller talking to the outside world is critical as you graduate to more complex projects, and OEM provides a great example of a polished, well designed architecture.

OpenMoCo – The Open-Source Photographic Motion-Control Community

As described in the expanded title, OpenMoCo is all about enabling motion in photography. Whether shooting video, time-lapse, or panoramic photography, accurate camera motion is often an important consideration. As many photographers know, professional equipment for automating camera movement and activation can be prohibitively expensive. OpenMoCo serves as a repository for community knowledge on how to design and create motion control tools on a budget.

Most OpenMoCo tools start with the OpenMoCo reference design, which is a modular platform that consists of an engine, interfaces, and elements. The Arduino-based engine covers the brains of the operations, interfaces include various UX controls and displays, and elements comprise motion tools such as stepper motors or actuators.

DIY Drones

Have you ever seen Predator drones in the news or watched the robot planes in Terminator movies and thought “Man, I wish I could build one of those”? Well, now you can. DIY Drones describes themselves as “the home for everything about amateur Unmanned Aerial Vehicles (UAVs)”. We don’t think too many people would argue, as the community has grown to over 20,000 members and is one of the top 100,000 websites in the world.

DIY Drones goal is to create hardware and software for any type of aerial robot, whether it be a helicopter, plane, quadcopter, or blimp. Their site is packed with various user groups, blogs, and forums, all with useful information on starting your own project. The DIY Drones store offers their premier product, the ArduPilot, a universal autopilot board equipped with an Arduino Mega 2560, 6-axis gyro/accelerometer, and GPS. Depending on what type of vehicle you’re creating, you can flash appropriate software such as ArduPlane or ArduCopter and be completely ready to fly. If you’re interested in drones or even radio controlled aircraft of any type, check out the site, because there’s a wealth of useful experience for any level of hobbyist.

DIY Magic Mirror

The DIY Magic Mirror is nifty contraption that will turn heads at your Halloween party, theme house, or even a bar. By combining an Arduino-compatible sensor kit with a laptop display and open-source software, you can create a mirror that interacts with visitors and spits out custom messages with text-to-speech. The site is more of a business venture than some of the other communities here, but the code is out there and the prices for the hardware are reasonable. You can get as involved as you want, by building the kit from scratch and even adding a breathalyzer so your mirror can publicly shame friends that overindulge at your holiday party.

Arduino beer brewing

Home brewing has gotten increasingly popular recently, as breweries get smaller, equipment gets cheaper, and Portland hipsters get more discerning in their IPA preferences. Luckily, Arduino can make this process easy, and a number of enterprising hackers have posted information on their automated beer brewing journeys.

The best resource we know of for this type of project is the HackaDay beer hacks category, which has plentiful examples of homemade mashtuns, kegerators, and automated dispensers, all enhanced with Arduino.

There are also several other noteworthy destinations for Arduino-powered beer projects. First up, Kegbot is an impressive and full featured beer tracking and pouring system. As described on their site:

Kegbot is a free, open-source project to turn your beer kegerator into a computerized drink tracker. Kegbot is an open source project, intended to beer enthusiasts, DIY hackers, homebrewers, and anyone with an interest in monitoring their beer.

Next, homebrewing.com has an article on home brewing automation with Arduino, which links to several other projects such as the Halfluck Automated Brewing System (HABS) grain brewing machine.

Wrap up

There’s enough here to keep you tinkering for a while, but we know we’ve only scratched the surface of great high-level Arduino projects. Do you have any suggestions that we should add to this list? Let us know in the comments. In the meantime, happy hacking…

read more:http://www.engblaze.com/top-arduino-projects-for-advanced-hackers/

Magnetic Levitation using the Arduino

arduinomaglev_cc1

 

This great project uses the a soleniod’s magnetic coil, a Hall sensor, and Arduino to perfectly levitate a magnet. The Hall sensor detects the field of the permanent magnet and uses that information to modulate the magnetic field of the electromagnet. If you’re unfamiliar with the Arduino, see our Arduino tutorial and top arduino projects.

Read more:http://hacknmod.com/hack/magnetic-levitation-using-the-arduino/

Just for fun, Eye Catching LCD Video Glasses

FQHVNJHG4JV6QK1.LARGE 未标题-2

While you may think that the glasses shown below would be rather expensive, you can actually make them for less than $15.  It’s as simple as buying two small digital photo frames on eBay for $6 and sacrifice an old pair of glasses.  Of course, you can’t see out of them

 

The overall idea is pretty absurd and I can’t believe I’m posting something related to Lady Gaga on HacknMod.  Nonetheless, the use of cheap LCDs is still pretty unique. The project is simple enough – the only critical components are the cheap digital photo frames. Just be sure that the digital frames fit into the glasses frames.

Read more:http://hacknmod.com/hack/eye-catching-lcd-video-glasses/

http://www.instructables.com/id/Lady-GaGa-Video-Glasses/