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.

Emilio x64's Content

There have been 39 items by Emilio x64 (Search limited from 18-June 23)


By content type

See this member's


Sort by                Order  

#52311 NetworkAvailabilityEventChanged event handler not working?

Posted by Emilio x64 on 24 August 2013 - 02:55 AM in General Discussion

In doing my netduino networking code (UDP & TCP) I tried something that was suggested back in 4.2 to detect when the connection is broken due to the inherent limitations of the NETMF.

 

It was proposed to use the NetworkInformation.NetworkAvailabilityChanged event handler. Basically one defines the delegate method and in there depending on the e.IsAvailable property one would stop or resume network operations (tx/rx).

Microsoft.SPOT.Net.NetworkInformation.NetworkChange.NetworkAvailabilityChanged += new Microsoft.SPOT.Net.NetworkInformation.NetworkAvailabilityChangedEventHandler(NetworkAvailabilityChangedHandler);

I have no hardware yet so I was trying it on the emulator which is supposed to have already a "connection" to the host system. I placed a breakpoint on that event handler method but it never gets called.

private void NetworkAvailabilityChangedHandler(object sender, Microsoft.SPOT.Net.NetworkInformation.NetworkAvailabilityEventArgs e)        {            lock (this.threadLock)            {                if (e.IsAvailable)                {                    StartServices();                }                else                {                    StopServices();                }            }        }



#52154 Lcd library to learn from

Posted by Emilio x64 on 14 August 2013 - 04:06 PM in General Discussion

You need to be more specific as to what you want to learn from it. There are tons of things you can have in the LCD library and a lot of it also depends on the LCD hardware capabilities (pixel depth, color/b&w, dimensions, character set, etc.)




#52196 Roundtrip communication latency

Posted by Emilio x64 on 16 August 2013 - 05:15 PM in General Discussion

I think my NETMF software is nearly on its last phases of development, I just hope it fits in Netduino Plus 2. Anyway, my NETMF application is supposed to run on the Netduino Plus 2 hardware and it would communicate with a service on the desktop to get some live information.

 

So that means the Netduino would send a request to the desktop and get some data in return. Since I haven't had the chance to try that on real hardware I would like to know what you can suggest me for this, USB or Ethernet? and what sort of roundtrip communication times I should be expecting.

 

My .NETMF state machine loop runs every 200ms and the service on the desktop would also be updating information around the same rate perhaps even a bit slower (like 1Hz).




#52243 Roundtrip communication latency

Posted by Emilio x64 on 20 August 2013 - 05:13 PM in General Discussion

Well now that I have been told that USB is not possible without extensive work, Serial is not a possibility either because I don't want to use a legacy system and that the ethernet connection has been suggested as the best....

 

I got my desktop proxy software developed, I got my custom emulator developed and running and also my .NETMF application to run on the Netduino Plus 2. But as it turns out (?) there is no support for UDP or TCP in the 4.3 SDK ?! can anybody shed some light into the subject?

 

In my .NETMF application I need an UDP listener that will exclusively listen for UDP broadcasts from the desktop application, this is basically to respond to the "WHO is out there" question because there is no guarantee whether the embedded device would start running before or after the Desktop proxy "server". I am using VS.2012 with .NETMF 4.3.

 

My .NETMF application then mostly uses a TCP connection to the above named desktop proxy server to send commands and receive a response.

 

When I try to write ANY net code in the NETMF the network communications classes are missing. I added a reference to Microsoft.SPOT.Net but that doesn't have anything of use. I also tried the MFDWSEXTENSIONS.DLL suggested in the MSDN but also, nothing of use.

 

I was looking for TcpClient and UdpClient .NET classes but I can't find them. I tried to then make something equivalent based on the Socket class but also, not available anywhere. I am stuck.




#52126 kan anyone help me ?

Posted by Emilio x64 on 13 August 2013 - 05:11 PM in General Discussion

Use the intellisense help to see the arguments expected by your method.




#52013 Netduino Board Support Package?

Posted by Emilio x64 on 07 August 2013 - 12:33 AM in Netduino Plus 2 (and Netduino Plus 1)

In addition to the NETMF 4.3 SDK I also installed the Netduino SDK. Isn't there some "using netduino;" kind of using directive that can/should be used to have access to Netduino-specific things?

 

In my custom emulator how do I set the available RAM/ROM and perhaps speed of the Netduino's core processor? I ask because there must be a way (I think) that the development environment warns me if my code or data segments are too large for the hardware I am targetting.




#51989 Netduino Board Support Package?

Posted by Emilio x64 on 06 August 2013 - 04:22 PM in Netduino Plus 2 (and Netduino Plus 1)

I am planning to use the Netduino Plus 2 (don't know if it is an overkill yet, have to see my memory requirements). I was wondering if there is some Netduino BSP (Board Support Package) that contains the definitions that map Netduino-specific stuff to NETMF ? 

 

For example, I read that in an SDK I should map my own pin definitions (board specific) to the NETMF Cpu.Pin.GPIO_* enumeration. Is there such a thing for Netduino?

 

Also, how do I go about specifying GPIO 16 ??? if that is possible.




#51664 How you debug these things?

Posted by Emilio x64 on 24 July 2013 - 05:40 PM in Netduino Plus 2 (and Netduino Plus 1)

I am planning a design based on the Netduino Plus 2 (tentative) and I created a custom emulator (nothing fancy really) project in VS.2013 Ultimate on Windows 7 Ultimate x64. As pointed out in a previous question this is targetted to a desktop framework (.NET 4.5) and it seems to work well.

 

I also created the Microframework application (SDK 4.3). Basically the application sends commands to the device (as emulated) via the SPI bus, It sends 16 bit commands to control a MAXIM 7219 chip.

 

I seem to have gotten the communication between emulator an app right from the examples. So, I can click on a button on the emulator which causes an interrupt to be processed on the app (Emulator to App comms). Also the application sends commands via SPI to the emulator (no actual device yet). My emulator receives the SPI commands and acts accordingly to update the custom UI. I also have a form that shows the registers of the device which has SPI (slave) and see that the commands are received.

 

The problem is... If I add initialization code in the app that sends initialization commands via SPI then the whole thing crashes. If I omit the initialization code (sent by SPI) and simply assume everything is initialized then I can interact with the emulator.

 

So to my question, how can one debug these things? when I enabled the initialization code sent to my device the emulator UI appears, I see in the Output Windows "found emulator!..."  and then I briefly see a bunch of messages, the thing crashes and the whole output window is ERASED leaving me with absolutely no clue as to what went wrong. 

 

I put a breakpoint on the call to the initialization code which is invoked in Program.cs then it doesn't even break, it craps out erases all output and no clue.... If I remove that call to the initialization then 99% of the times it starts and works. But usually the 1st time it crashes (same modus operandi of erasing all useable output) and the next time it runs fine.

 

How can I debug this???? I am not even using an actual hardware device. Why are the breakpoints ignored in DEbug mode?




#51665 How you debug these things?

Posted by Emilio x64 on 24 July 2013 - 05:47 PM in Netduino Plus 2 (and Netduino Plus 1)

I found the following messages on the "Microframework Device Deployment" category of the Output Window in VS.2013:

Looking for a device on transport 'Emulator'Launching emulator with command line: '"N:CodeMicroFrameworkDisplayMyDeviceEmulatorbinDebugMyDeviceEmulator.exe" "/waitfordebugger" "/load:C:Program Files (x86)Microsoft .NET Micro Frameworkv4.3AssembliesleMicrosoft.SPOT.Native.pe" "/load:C:Program Files (x86)Microsoft .NET Micro Frameworkv4.3Assemblieslemscorlib.pe" "/load:C:Program Files (x86)Microsoft .NET Micro Frameworkv4.3AssembliesleMicrosoft.SPOT.Graphics.pe" "/load:C:Program Files (x86)Microsoft .NET Micro Frameworkv4.3AssembliesleMicrosoft.SPOT.Hardware.pe" "/load:N:CodeMicroFrameworkDisplayMyDeviceEmulatorbinDebugleMyDeviceEmulator.pe"'Restarting interpreter...Attaching to device...Deployment error: failed to (re)connect debugger engine to debugging target.The debugging target and the debugger engine failed to initialize because of unspecified device errors.The debugger engine thread has terminated unexpectedly with error 'Debugger engine could not attach to debugging target.'.

But that "unknown device errors" isn't really much of a help, isn't it? shouldn't it give a stack trace or something to work with?




#51670 Production Ideas...

Posted by Emilio x64 on 24 July 2013 - 07:59 PM in General Discussion

OK, I am new to Netduino, let's say I spent quite some time developing a project using the .NET uF based on the Netduino hardware and I am ready to create boards... Obviously I wouldn't want to just have a true netduinon inside.

 

1.  How do I go about creating my own board that would integrate the Netduino (minus a few things I don't need from the board) and my own "add-on" module all in one board?

 

2. Who can produce those boards in small quantities?

 

3. Would I need to re-port the uF or something? 

 

4. How do I get to permanently download my custom firmware (the app developed in vs.2013) into the board?

 

I don't know if somebody has already gone through that process or what. I would like to do it with Netduino but if that is not possible then I would opt for a PIC based design that is perhaps easier to produce. Anyway, just need some feedback for my "custom appliance"




#51692 Common library target choice

Posted by Emilio x64 on 25 July 2013 - 10:44 PM in General Discussion

Just found out it is not possible. If you reference a uF common library from the emulator you get this error:

Warning	1	The project 'CommonLibrary' cannot be referenced. The referenced project is targeted to a different framework family (.NETMicroFramework)	MyDeviceEmulator

so the problem remains how to share certain data types (interfaces, classes, structs) that are common to both the emulator and the uF application taking into consideration that the common library should behave the same (some methods such as ToString are implemented differently in the frameworks) and compile under both frameworks. Pity...




#51668 Common library target choice

Posted by Emilio x64 on 24 July 2013 - 07:53 PM in General Discussion

Since I don't have a device yet and it is good for early prototyping, I am using a custom emulator for my project for the time being. As we all know (I recently only...) the Device Emulator project is targeted to the standard .NET framework (v4.5).

 

My actual application is a .NET Microframework v4.3 project with ".NET Microframework 4.3" as the target. So far so good...

 

Now, since for the configuration of both applications I need things like pin numbers and perhaps a few interface definitions, rather than duplicating them in both the uF console app and the .NET device emulator project, I thought a common library project would be more suitable to share those things I mentioned.

 

My question is... such "common library" project to be used with both the Device Emulator project AND the uF Console Application should be targetted at the uF (the lowest denominator) or is this approach just not possible?




#52125 The right Netduino board and my application

Posted by Emilio x64 on 13 August 2013 - 05:10 PM in General Discussion

How do I know if my application is within the RAM/Code limits of Netduino Plus 2?




#51554 The right Netduino board and my application

Posted by Emilio x64 on 19 July 2013 - 12:09 AM in General Discussion

I am new to NetDuino... Since it is obvious the RAM and ROM on an embedded system such as the netduino is limited, I believe some 384KB maximum on the Plus 2, I would like to know how can I determine what are the actual memory requirements of my application.

 

I have not bought the netduino board yet because I don't want to buy one and then find out it doesn't have enough  memory to run my application. I don't know how effective the .Net MF is at squeezing stuff up. Back in my embedded days I developed (with my team) a multihandset cordless phone with only 512 bytes of RAM using C but for that I had to really know my compiler's output very well to adjust the coding accordingly.

 

Currently I have my eyes set on the Netduino Plus 2 but I will first have to see how big my application is.





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.