Showing posts with label arduino. Show all posts
Showing posts with label arduino. Show all posts

Friday, January 16, 2015

How do you see the Arduino Serial.print() output?

I realised that when I was trying to learn how to use the Arduino IDE, I could not readily find the output console to "see" the output from "Serial.print()" or "Serial.println()".

The following is a newbie guide:

  1. Open the IDE -> Tools -> Serial Monitor.
  2. Change the "Baud rate" setting to the same number in the code. E.g. "Serial.begin(115200);" means the baud rate is 115200.
  3. After you switch to the correct baud rate, which is like tuning in to a radio channel on radio, you should see the output of the print command.
Good luck figuring this out!


Saturday, December 27, 2014

How to connect an Arduino with an NFC shield?

One day, at a spur of the moment, I decided to buy an Arduino uno R3 and a dynamic NFC shield. I read a few websites that sang praises about the Arduino's capabilities and ease of use by hobbyists (who need not be electrical engineers) so I thought that it should be easy to connect, much like how you plug your monitor to your CPU or similar.

The packages arrived through mail and when I opened the box, I was clueless at how I should connect it. I read the "datasheet" and "schematics" documentation but could not understand how it could be called documentation -- it did not tell you step 1-2-3, do this, do that, etc.

The documentation is in the form of a link like that: Arduino Uno R3 schematic.

NFC shield schematic. The diagram shows that there are 2 LED lights. Those will light up when power is connected.

Editted on 16 Jan: It turned out that a Male-Female jumper wire (easily searchable from google) was require to connect the NFC shield with the Arduino. All 6 pins were connected and it functioned as a tag.

The NFC shield has 6 pins.
Pinout diagram that I referenced from blog.arduino.cc.

The same pinout diagram with the 6 pin holes highlighted.

Unfortunately, at this point, the example code I test-loaded on the board still did not work, so I am still figuring that out.

I wanted to write different URLs dynamically to a tag as an advertisement. At this rate of fumbling, I have no idea when that idea will see light.

[Updated on 5 Feb 15]: After writing on the supplier's facebook that the example code didn't work, and nobody replied to 4 of my emails sent over 2 months, a reply came within the day that the example code was wrong and I was provided with a working code.