Toolbox.NETMF.Hardware.core help? - Netduino Plus 2 (and Netduino Plus 1) - Netduino Forums
   
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

Toolbox.NETMF.Hardware.core help?


  • Please log in to reply
5 replies to this topic

#1 philvr

philvr

    Member

  • Members
  • PipPip
  • 23 posts
  • LocationMelksham, UK

Posted 09 September 2013 - 08:35 AM

Please can someone explain the purpose of these interfaces? I don’t quite understand how they are intended to be used as there are no direct assignments to the netduinos i/o ports. Is there a tutorial anywhere that demonstrates usage? As an example IParallelOut.cs is reproduced below. I apologise in advance if there is an obvious answer, it is taking me some time to get to grips with c#, I am not a programmer by nature and my brain is having difficulty adapting :( The write must take as an argument some port that has been created elsewhere but how is it created? namespace Toolbox.NETMF.Hardware { /// Generic Purpose Output Array interface public interface IParallelOut : IDisposable { /// Amount of bits in the array uint Size { get; } /// Writes a block of data to the array /// The block of data to write void Write(uint Value); /// Returns the last written block of data /// The last written block of data ] uint Read(); } }

#2 philvr

philvr

    Member

  • Members
  • PipPip
  • 23 posts
  • LocationMelksham, UK

Posted 13 September 2013 - 07:43 AM

Any ideas? I'm really confused and could very much do with some advice!!

Please can someone explain the purpose of these interfaces? I don’t quite understand how they are intended to be used as there are no direct assignments to the netduinos i/o ports. Is there a tutorial anywhere that demonstrates usage? As an example IParallelOut.cs is reproduced below. I apologise in advance if there is an obvious answer, it is taking me some time to get to grips with c#, I am not a programmer by nature and my brain is having difficulty adapting :( The write must take as an argument some port that has been created elsewhere but how is it created? namespace Toolbox.NETMF.Hardware { /// Generic Purpose Output Array interface public interface IParallelOut : IDisposable { /// Amount of bits in the array uint Size { get; } /// Writes a block of data to the array /// The block of data to write void Write(uint Value); /// Returns the last written block of data /// The last written block of data ] uint Read(); } }



#3 JoopC

JoopC

    Advanced Member

  • Members
  • PipPipPip
  • 148 posts

Posted 13 September 2013 - 06:35 PM

philvr, The best thing to do is to go to headTopic  "Showcase"  on this forum and read all about the examples/solutions from other Netduino users.

 

This is the fastest way to learn all about how to work with the Netduino.



#4 philvr

philvr

    Member

  • Members
  • PipPip
  • 23 posts
  • LocationMelksham, UK

Posted 08 November 2013 - 10:30 AM

Agreed that reading all the examples, etc in the forums  really does help to  learn and indeed I have learned a great deal  from other peoples work. I offer a BIG THANK YOU! to all that have contributed code to the forums.

 

But - I never did not find a direct answer to my question...



#5 stotech

stotech

    Advanced Member

  • Members
  • PipPipPip
  • 143 posts
  • LocationAustralia

Posted 10 November 2013 - 12:54 AM

Have a look at the bottom of this class.

 

http://netmftoolbox....95/Ic74HC595.cs

 

I just figured out how to make a parallel port something like this. 

 public static IParallelOut GLCD_Port;        public static void Run(bool GPO_Start_State = false)        {            Ic74hc595 OutChain = new Ic74hc595(SPI_Devices.SPI1, Pins.GPIO_PIN_D9, 3, 1000);            GLCD_Port = OutChain.CreateParallelOut(0, 8, false);                    }    }}


#6 stotech

stotech

    Advanced Member

  • Members
  • PipPipPip
  • 143 posts
  • LocationAustralia

Posted 10 November 2013 - 07:10 AM

also just figured out that when it says inverted it is changing the bit order from 0-7 to 7-0. Not true to false as i'd assumed.






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.