-
Notifications
You must be signed in to change notification settings - Fork 29
First steps
These are some important steps to follow before you start using your panStamps:
-
Install Arduino 1.5 IDE. This is the only IDE compatible with our latest libraries and core files. It is also the only IDE compatible with both panStamp AVR and panStamp NRG. If you want to use your old Arduino 1.0.x IDE you can still do it but only with panStamp AVR and our older "all-in-one" Arduino library documented in our old wiki.
-
Download panStamp's Arduino files, containing sample sketches and a patch for the Arduino 1.5 IDE. This patch will add the necessary board definitions, core files and libraries to the standard IDE in order to make it compatible with panStamp's family of boards.
-
Uncompress the zip file and move the "arduino-1.5_patch" folder to the directory where Arduino-1.5 is installed. Then navigate to arduino-1.5.XX/arduino-1.5_patch/ from a terminal (console) and run install.sh or install.bat, depending whether your OS is Linux/MacOS or Windows. Your Arduino IDE is now panStamp-enabled.
-
Depending on your model of panStamp (AVR or NRG), you have to select the correct board from Tools->Boards. Then open any of the sample sketches and program your module. Each sketch is designed to provide different functionality. Some of them use the SWAP protocol and other don't. Before starting a new development, try to identify which of the available sample sketches better fits your project and try to understand the code. This wiki will try to help you along this process but you can also read our forums and post your questions to them.
Like Arduinos, panStamps include a programmable microcontroller. You can program Arduinos and panStamps from the same IDE but you still have to know the basic differences between these two architectures:
-
Arduinos are usually generic boards with a well-known pin-socket format and compatible with a long list of shields and child boards. panStamps are OEM modules with integrated low-power radio and designed to be used stand-alone or assembled onto mother boards with other sensors and/or actuators.
-
Arduinos and panStamps don't necessarily share the same position and amount of pins. There are even some differences between panStamp AVR and NRG, due to the inherent differences between microcontrollers (Atmega328p vs CC430F5137).
-
panStamps are low-current consumption boards made to last for years from simple batteries. They don't include an on-board USB front-end to save power and costs but they can be connected to panSticks or any other USB-(3.3V)UART converter.
- panStamp doesn't load HardwareSerial by default so the Serial object used to print (print, println) our packets throuch the UART is not available unless you include HardwareSerial.h in your sketch.
#include "HardwareSerial.h"
This technique prevents panStamps from wasting resources when Serial communications are not needed.