Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.
Photo

Confusion of PWN Pins on ShieldBase


Best Answer Chris Walker, 06 January 2013 - 06:16 AM

Quick note: this has been fixed, and the fix is currently in testing. Chris Go to the full post


  • Please log in to reply
5 replies to this topic

#1 halobox

halobox

    New Member

  • Members
  • Pip
  • 5 posts
  • LocationEurope, Germany

Posted 31 December 2012 - 01:41 AM

Hi,

 

I'm experimenting with an arduino motor shield on the Netduino Go Shieldbase and come to confusing results... I hope any of you can help me out :-)

 

I'm trying to activate the necessary PWNs.

 

If I activate for example sb.PWMChannels.PWM_PIN_D3 I get a signal at pin2 on the ShieldBase

 

CodeExample:

 

using System;using System.Threading;using Microsoft.SPOT;using Microsoft.SPOT.Hardware;using SecretLabs.NETMF.Hardware;using SecretLabs.NETMF.Hardware.NetduinoGo;using NetduinoGo;namespace NetduinoGoApplication2{    public class Program    {        public static ShieldBase sb;        public static Microsoft.SPOT.Hardware.PWM pow0;        public static void Main()        {            // write your code here            sb = new ShieldBase(GoSockets.Socket4);            double freq = 50;            double dutyc = 0.5;            pow0 = new Microsoft.SPOT.Hardware.PWM(sb.PWMChannels.PWM_PIN_D3, 50, 0.5, false);                        pow0.Start();            //pow0.Stop();            while (true)            {                            Thread.Sleep(3000);              }        }    }}

 

If I activate the PWN pins in code I get the following results (measured by a buzzer I connected to the pins on the ShieldBase via cable ;-):

 pin 3 = ShieldBase pin 2 activated
 pin 5 = ShieldBase pin 5 activated
 pin 6 = ShieldBase pin 6 activated
 pin 9 = ShieldBase pin 9 activated
 pin 10 = no signal recognized
 pin 11 = program crashed

 

I expected the PWNs to be activated on the Shield as labeled in code and as described by Gutworks (http://forums.netdui...uino-go-shield-

base-pinout/)

 

The current setting would make it necessary to bend the pins to different pins on the motorshield although they should be the same in specs.

 

Do I make a mistake or is there a bug?

 

Regards

halobox



#2 Gutworks

Gutworks

    Advanced Member

  • Members
  • PipPipPip
  • 363 posts
  • LocationOttawa, Ontario

Posted 06 January 2013 - 05:20 AM

Hi halobox, 

 

Sorry it has taken me a while to respond. I tried reproducing your sample, and I found the same sort of issues using a logic analyzer. These are bugs to the current beta version of the Shield Base and they have been passed along to the Secret Labs team. 

 

I don't advise bending any pins just yet, as I'm sure these issues will be fixed in an upcoming firmware update. I don't know when the update will be, but I don't expect that it will be a long wait. 

 

Which motor shield are you using? I have plans for my Shield Base and a motor shield as well. 

 

Cheers,

Steve



#3 Chris Walker

Chris Walker

    Secret Labs Staff

  • Moderators
  • 7767 posts
  • LocationNew York, NY

Posted 06 January 2013 - 06:16 AM   Best Answer

Quick note: this has been fixed, and the fix is currently in testing. Chris

#4 Gutworks

Gutworks

    Advanced Member

  • Members
  • PipPipPip
  • 363 posts
  • LocationOttawa, Ontario

Posted 06 January 2013 - 01:25 PM

Quick note: this has been fixed, and the fix is currently in testing. Chris

Awesome! 

 

Halobox, when the new firmware has been posted, I'd love to see your motor shield working. Perhaps we can compare notes :)

 

Steve



#5 halobox

halobox

    New Member

  • Members
  • Pip
  • 5 posts
  • LocationEurope, Germany

Posted 14 January 2013 - 06:45 PM

Thanks to the new firmware it seems to work now.  :)  I did not check on all pins but the first test I did were successful.

 

 

halobox



#6 Gutworks

Gutworks

    Advanced Member

  • Members
  • PipPipPip
  • 363 posts
  • LocationOttawa, Ontario

Posted 14 January 2013 - 08:16 PM

Awesome. Great to hear. :D






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.