Kit received, few questions

All about Arduino, Jeenode and other Clones (hardware & Software)

Moderator: Mdamen

Alexander
Global Moderator
Global Moderator
Posts: 1532
Joined: Sat Mar 10, 2007 11:19 pm
Location: Netherlands

Kit received, few questions

Post by Alexander »

I wasn't attending the workshop. So my questions will be within this topic. Properly some are answered at the workshop, so this would be the second time ;-)

1: The received roomboard was already assembled (the one with the pir). I think i have not a new one, because the joints arent nice and some wires are newly created. This pir is installed (http://jeelabs.org/2010/02/02/room-board-assembly/) but with another print as descripted within the documentation "new pir motion sensor". So on page 2 within the printed documentation you see two PIR's. I've the pir on the left with the board on the right... There is also fingerprints on the pir. Documention says not to touch for the accurracy. Can't be right or?

2: The software refers to pins but i can't find the layout of those numbers. Any help please.
Alexander
User avatar
JohnieBraaf
Starting Member
Starting Member
Posts: 32
Joined: Sat Sep 18, 2010 3:21 am
Location: Amsterdam
Contact:

Re: Kit received, few questions

Post by JohnieBraaf »

I'm not sure where exactly I read it, but as far as I know there are about 3 types of PIR sensors which were used on these boards.
Somewhere along the archives blog it was mentioned that the PIR was replaced by a less power hungry EPIR or vica versa.

When you look at this article you see what my board looks like.

As I'm still experimenting with leds and basic examples, I cannot advice you on how to properly connect the board.
I made a topic about the pin configuration here, try to read the Ports library documentation for pin layout!
Alexander
Global Moderator
Global Moderator
Posts: 1532
Joined: Sat Mar 10, 2007 11:19 pm
Location: Netherlands

Re: Kit received, few questions

Post by Alexander »

That's the same one indeed. With alot of conductors beneath that do not fit well with the IC underneath. Also i see on that page that they did place the rb1 and pir board separate, whill in the documentation i find to connect the pir to the rb1 which is connected to the jeenode. I can imagine the code would be different?

Your topic did not give me the solution i think. Like in the documentation the orginators refer to "D4 is de DIO pin van port 1". That is understandable, but what pinconfiguration is this with in the code? The blink code refers to pin 13, but what pin would that be on the jeenode? I think in the workshop documentation it is properly pin5, because that is what is written below "installeren van de arduino ide" at bullet 2.

The bridge board does mention 13 and 9, as D.13 and D.9, but using those pins and within the code pin13 and pin9 it will not work. Should it?

3: Documentation mention something about an adapter. That was available in the workshop i guess and not within the package?
4: "Bouw eerst het voedingscircuit (rechtsonder in het schema)".... voedingscircuit? schema? which one? I'm missing some information that was told on the workshop i guess?
Alexander
Alexander
Global Moderator
Global Moderator
Posts: 1532
Joined: Sat Mar 10, 2007 11:19 pm
Location: Netherlands

Re: Kit received, few questions

Post by Alexander »

Okay, on the bridge board the D.x pins are exactly as within the code, but when using the fading sketch, how to use the A.x pins? The example starts with digital pin9, but connecting it to D.9 nothing happens. I would think that i need to connect to a analog pin, but the example refers to "digital pin 9".

Question remains how the mapping is on the jeenode itself.

About the pir sensor, The blog from Robert looks like the same to me. Only the pir is to the right and i thought i would be to the left (above the ic): http://blog.hekkers.net/wp-content/uplo ... resize.jpg
Alexander
Bwired
Administrator
Administrator
Posts: 4704
Joined: Sat Mar 25, 2006 1:07 am
Location: Netherlands
Contact:

Re: Kit received, few questions

Post by Bwired »

Its hard to follow :)
But the powercircuit you are talking about is on page 5/7 (right below schematic)
In the beginning of the course we built a Jeenode on the breadboard as a sample test and to understand the logic.
You have a Jeenode which is already assembled, the power circuit is already on there.
Just connect 5 volt or higher to pin 1 and 3 (FTDI connector) and the jeenode wil run, if the sketch is in there.

is this helping or?
Alexander
Global Moderator
Global Moderator
Posts: 1532
Joined: Sat Mar 10, 2007 11:19 pm
Location: Netherlands

Re: Kit received, few questions

Post by Alexander »

Pieter,

I've assembled the Jeenode myself. That was easy to do. Because i didn't understand that part about power circuit, i'd skipped it. But maybe i'd missed someting after doing that that effects the rest. The page you're refering to is the same as my paper? On that page there are the schematics of the pcb (by Wippler). But if i could skip that part, than its okay. I got confused because on the first page (bullet 3 and 4) it says the led should blink but i thought the led would only blink when the blink sketch would be uploaded to the ic and that part is on the next page....
Alexander
Bwired
Administrator
Administrator
Posts: 4704
Joined: Sat Mar 25, 2006 1:07 am
Location: Netherlands
Contact:

Re: Kit received, few questions

Post by Bwired »

Right, I think you got confused with the breadboard experiments, but you can skip that part.
jcw
Starting Member
Starting Member
Posts: 15
Joined: Mon Nov 24, 2008 12:36 am
Location: Netherlands
Contact:

Re: Kit received, few questions

Post by jcw »

The PIR with the blue board is the newest. It doesn't fit nicely on the RB v1 - see http://jeelabs.org/2010/08/30/new-pir-motion-sensor/

During the workshop, I replaced everyone's RB v1 PCB with a new RB v2 PCB, as I just received them the day before. The new PCB is described here - http://jeelabs.org/2010/11/28/meet-the- ... -board-v2/

Lennart asked for an extra RB v2 PCB, but I forgot to give him one. He asked me to send it directly to Alexander ... Rotterdam. Is that you? In that case, I'll put the board in an envelope and send it over.
User avatar
JohnieBraaf
Starting Member
Starting Member
Posts: 32
Joined: Sat Sep 18, 2010 3:21 am
Location: Amsterdam
Contact:

Re: Kit received, few questions

Post by JohnieBraaf »

Alex, fading a LED can only be done with the DIGITAL (D) input/output pins of port 2 and 3 on the JeeNode.

I was also very confused about the mapping of pins from Adruino to JeeNode, and actually still can't give a direct conversion.

When looking at the Adruino, it can be seen that it had more pins than the JeeNode has, but I guess the RF12 radio takes up these extra pins.

If you use the Ports library, as demonstrated in the other topic, you see that mode and digiWrite can be used for digital pins and mode2 and digiWrite2 for analog pins!

If you don't want to use the Ports library you can use this code for testing the fading LEDS:

Code: Select all

int brightness = 0;    // how bright the LED is
int brightness2 = 255;    // how bright the LED is
int fadeAmount = 3;    // how many points to fade the LED by

void setup()  { 
  // declare pin 9 to be an output:
  pinMode(5, OUTPUT);
  pinMode(6, OUTPUT);
} 

void loop()  { 
  // set the brightness of pin 9:
  analogWrite(5, brightness);
  analogWrite(6, brightness2);  

  // change the brightness for next time through the loop:
  brightness = brightness + fadeAmount;
  brightness2 = brightness2 - fadeAmount; 
  
  // reverse the direction of the fading at the ends of the fade: 
  if (brightness == 0 || brightness == 255) {
    delay(200);
    fadeAmount = -fadeAmount ; 
  }     
  // wait for 30 milliseconds to see the dimming effect    
  delay(40);                            
}
I extended the basic code a little to have two opposing fading LEDS connected on JeeNode port 2 and 3 on the D pin!
Alexander
Global Moderator
Global Moderator
Posts: 1532
Joined: Sat Mar 10, 2007 11:19 pm
Location: Netherlands

Re: Kit received, few questions

Post by Alexander »

Jean-Claude,

Correct, that would properly be me (two correct facts, alexander and rotterdam). I've already added the LDR and smd chip on the v1. That would not be a no-go to desolder that i think?
Alexander
Alexander
Global Moderator
Global Moderator
Posts: 1532
Joined: Sat Mar 10, 2007 11:19 pm
Location: Netherlands

Re: Kit received, few questions

Post by Alexander »

JohnieBraaf wrote:If you don't want to use the Ports library you can use this code for testing the fading LEDS:
I extended the basic code a little to have two opposing fading LEDS connected on JeeNode port 2 and 3 on the D pin!
That worked indeed, thanks!
Alexander
jcw
Starting Member
Starting Member
Posts: 15
Joined: Mon Nov 24, 2008 12:36 am
Location: Netherlands
Contact:

Re: Kit received, few questions

Post by jcw »

JohnieBraaf wrote:I was also very confused about the mapping of pins from Adruino to JeeNode, and actually still can't give a direct conversion.
Yes, it can be confusing, unfortunately. Here's a diagram which may help, at least for the "basic" I/O pins: http://cafe.jeelabs.net/ref/pinouts/JN-colors.pdf
Last edited by jcw on Thu Dec 02, 2010 8:26 pm, edited 1 time in total.
jcw
Starting Member
Starting Member
Posts: 15
Joined: Mon Nov 24, 2008 12:36 am
Location: Netherlands
Contact:

Re: Kit received, few questions

Post by jcw »

Alexander wrote:Correct, that would properly be me (two correct facts, alexander and rotterdam). I've already added the LDR and smd chip on the v1. That would not be a no-go to desolder that i think?
Ok, I can send it out in an envelope tomorrow.

De-soldering the LDR is not too hard. For the SMD chip, you have to be careful - use solder wick to remove as much solder as possible, and lift things *gently*.

If you prefer, I can do it for you - but you'll have to send it over. In that case, perhaps I should wait with sending you the board?
User avatar
JohnieBraaf
Starting Member
Starting Member
Posts: 32
Joined: Sat Sep 18, 2010 3:21 am
Location: Amsterdam
Contact:

Re: Kit received, few questions

Post by JohnieBraaf »

Alex glad it works now!

Just for comparison, here is the same fading LED example making use of the JeeNode Ports library!

Code: Select all

#include <Ports.h>
#include <RF12.h>

Port portTwo (2);
Port portThree (3);

int brightness = 0;    
int brightness2 = 255; 
int fadeAmount = 3;    

void setup()  { 
  portTwo.mode(OUTPUT);
  portThree.mode(OUTPUT);
} 

void loop()  { 
  // set the current brightness level
  portTwo.anaWrite(brightness);
  portThree.anaWrite(brightness2);  

  // change the brightness for next time through the loop:
  brightness = brightness + fadeAmount;
  brightness2 = brightness2 - fadeAmount; 
  
  // reverse the direction of the fading at the ends of the fade: 
  if (brightness == 0 || brightness == 255) {
    delay(200);
    fadeAmount = -fadeAmount ; 
  }     
  // wait for 30 milliseconds to see the dimming effect    
  delay(40);                            
}
Alexander
Global Moderator
Global Moderator
Posts: 1532
Joined: Sat Mar 10, 2007 11:19 pm
Location: Netherlands

Re: Kit received, few questions

Post by Alexander »

jcw wrote:
JohnieBraaf wrote:I was also very confused about the mapping of pins from Adruino to JeeNode, and actually still can't give a direct conversion.
Yes, it can be confusing, unfortunately. Here's a diagram which may help, at least for the "basic" I/O pins: http://cafe.jeelabs.net/ref/pinouts/JN-colors.pdf
Yes but this document was also in the paper version that they guys had created. I see digital 4 ... 7 and analog 0 ... 3 in the document. But on the bridge board we have digital 0 ... 13 and analog 0 ... 5. Are those binary combinations which results in extra ports that aren't directly on the jeenode?
jcw wrote:Ok, I can send it out in an envelope tomorrow.

De-soldering the LDR is not too hard. For the SMD chip, you have to be careful - use solder wick to remove as much solder as possible, and lift things *gently*.

If you prefer, I can do it for you - but you'll have to send it over. In that case, perhaps I should wait with sending you the board?
I will try it tomorrow. I'll let you know!
Alexander
Post Reply

Return to “Raspberry, Arduino, Cubietruck and other clones Forum”