Netduino Firmware v4.1.1 ALPHA 1
#1
Posted 02 September 2010 - 05:59 PM
#2
Posted 02 September 2010 - 07:13 PM
#3
Posted 02 September 2010 - 07:19 PM
If you have questions, please let me know.
Hi Bob,
Thanks for testing this, and for the quick feedback...
Three questions:
1. Are you using the original .NET MF 4.1 SDK or the new "QFE1" one?
2. Are you running inside a virtual machine (Parallels/VMWare/VirtualBox) or in a native Windows install?
3. Were you running the v4.1.0.3 alpha firmware before?
Chris
P.S. You can switch back to the production v4.1.0.2 firmware without issue if you need to.
#4
Posted 02 September 2010 - 09:45 PM
#5
Posted 02 September 2010 - 09:59 PM
#6
Posted 02 September 2010 - 10:06 PM
string root = "SD_Card"; StorageDevice.MountSD(root, SPI.SPI_module.SPI1, Cpu.Pin.GPIO_Pin12); string path = Path.Combine(root, "test.txt"); string content = "This is a test"; byte[] bytes = System.Text.Encoding.UTF8.GetBytes(content); File.WriteAllBytes(path, bytes);
Sure enough, a file named "text.txt" with the content "This is a test" was on the SD card. It appears to me that this is only an issue with the debugger connecting to the device.
I am using the GPS Shield from the ladyada site. It has a 2GB SD card. This is looking very easy to use. Thanks!
Bob
#7
Posted 03 September 2010 - 01:43 AM
I have a microSD card shield from Sparkfun (http://www.sparkfun....roducts_id=9802) and a Sandisk 8GB microSD card and the code shown by Bob doesn't appear to work.
Further to that, after deploying the following code, the LED doesn't flash (as per the while loop) and I have to use MFDeploy to erase the code before it will allow me to deploy or debug again.
using System; using System.Threading; using Microsoft.SPOT; using Microsoft.SPOT.Hardware; using System.IO; using SecretLabs.NETMF.IO; using SecretLabs.NETMF.Hardware; using SecretLabs.NETMF.Hardware.Netduino; namespace SDTest { public class Program { static OutputPort LED = new OutputPort(Pins.ONBOARD_LED, false); static bool LEDstate = false; public static void Main() { string root = "SD_Card"; StorageDevice.MountSD(root, SPI.SPI_module.SPI1, Cpu.Pin.GPIO_Pin12); string path = Path.Combine(root, "test.txt"); string content = "This is a test"; byte[] bytes = System.Text.Encoding.UTF8.GetBytes(content); File.WriteAllBytes(path, bytes); while (true) { LED.Write(LEDstate = !LEDstate); Thread.Sleep(100); } } } }
When debugging, the 'StorageDevice,MountSD' line is reached and the debugger exits.
Using the 4.1.1.0 Alpha firmware linked above, and the references are added to VS2010 correctly.
Strange indeed... I'll see if anyone here has a microSD card smaller than 2GB.
#8
Posted 03 September 2010 - 03:07 AM
I have a microSD card shield from Sparkfun (http://www.sparkfun....roducts_id=9802) and a Sandisk 8GB microSD card and the code shown by Bob doesn't appear to work.
No, it doesn't support SDHC, so nothing over 2gb.
MicroSD is tricky, I've been reading the specs lately. All the other SD standards mandate SPI support, but Micro does not, so it might be hit or miss with getting micro cards working. Probably going to vary by make/model.
#9
Posted 03 September 2010 - 03:20 AM
Haven't had much chance to try anything beyond the sample code though.
I was unable to debug this firmware on my mac running parallels 5 + windows 7 64bit. When I tried to debug it would just reboot the netduino and stop. I had this issue with the shipped firmware, as well as the beta firmware, so it's not new. I'll just stick to pure windows for now i guess.
#10
Posted 03 September 2010 - 04:21 AM
#11
Posted 03 September 2010 - 04:25 AM
I have a microSD card shield from Sparkfun (http://www.sparkfun....roducts_id=9802) and a Sandisk 8GB microSD card and the code shown by Bob doesn't appear to work.
Further to that, after deploying the following code, the LED doesn't flash (as per the while loop) and I have to use MFDeploy to erase the code before it will allow me to deploy or debug again.
If you try to mount a card that .NET Micro Framework doesn't support, .NET MF may throw an exception or lock up. Exceptions are good; the locking up is something we're seeing if we can fix and contribute back to the .NET MF codebase.
If this happens to you:
1. Unplug your Netduino from USB and any other power source.
2. Start the MFDeploy program on your PC (Start Menu > Programs > .NET Micro Framework 4.1 > Tools > MFDeploy.exe)
3. Select the USB transport in MFDeploy (instead of the default Serial)
4. Hold the pushbutton on your Netduino down and plug it into your computer while still holding down the button. This will put you in "bootloader" mode
5. Press the ERASE button in MFDeploy to erase your Netduino app.
In theory, just taking out the SD card should fix the situation too--but if it doesn't you can always fall back on the bootloader to erase your Netduino app.
Chris
#12
Posted 03 September 2010 - 04:26 AM
I can confirm that I can run the sample sd card code (provided in the other thread) on the seeedstudio sd card shield. I tested it with the switch in the "3.3v" position.
Woot! Great--another supported SD shield.
I was unable to debug this firmware on my mac running parallels 5 + windows 7 64bit. When I tried to debug it would just reboot the netduino and stop. I had this issue with the shipped firmware, as well as the beta firmware, so it's not new. I'll just stick to pure windows for now i guess.
Parallels seems to work well for some users--but a few are having this issue. It looks like something that needs to be solved within the .NET MF SDK itself--so we're trying to track down a mac we can borrow so we can fix the issue Unfortunately, the regular builds work great inside Parallels on our Macs...
Chris
#13
Posted 03 September 2010 - 07:28 AM
If you try to mount a card that .NET Micro Framework doesn't support, .NET MF may throw an exception or lock up. Exceptions are good; the locking up is something we're seeing if we can fix and contribute back to the .NET MF codebase.
Ahh that would explain some of my symptoms then. I should be able to try it tonight with a 128MB microSD card.
The SparkFun MicroSD shield uses pin D8 for CS, will that need an update to the firmware or should it work with it hardcoded to D10?
#14
Posted 03 September 2010 - 07:37 AM
Ahh that would explain some of my symptoms then. I should be able to try it tonight with a 128MB microSD card.
The SparkFun MicroSD shield uses pin D8 for CS, will that need an update to the firmware or should it work with it hardcoded to D10?
Got it working as per this post
Excellent!
#15
Posted 03 September 2010 - 11:36 AM
Woot! Great--another supported SD shield.
Parallels seems to work well for some users--but a few are having this issue. It looks like something that needs to be solved within the .NET MF SDK itself--so we're trying to track down a mac we can borrow so we can fix the issue Unfortunately, the regular builds work great inside Parallels on our Macs...
Chris
I'd let you come use my MacPro but you have to come to Chicago for it - I'm not shipping it!
#16
Posted 03 September 2010 - 05:12 PM
#17
Posted 04 September 2010 - 02:30 AM
Version: 4.1.1 ALPHA 1 (version 4.1.1.0 a1)
WARNING: This firmware is pre-release firmware. It may temporarily cause your Netduino to cease functioning properly. If this firmware does not work for you, you will likely need to erase your Netduino completely and re-flash the production v4.1.0.2 bootloader using Atmel SAM-BA tools (on a 32-bit Windows installation) and the production v4.1.0.2 firmware using MFDeploy.
With that warning out of the way, we've added the first new feature to the Netduino: SD card and FAT16/FAT32 file system support. We have also added some debugger enhancements to help with debugger reconnections during deployment.
If you're an early adopter and would like to help us test and refine this new feature, this alpha release may be for you.
This firmware update includes the following updates:
1. SD card support using SPI
2. Visual Studio debugger should connect to Netduino easier during deployment (on non-virtual machines)
You may update to this pre-release firmware using the MFDeploy tool:
1. Download and unzip the attached file to a directory on your computer.
2. Go to the Start Menu > Programs > Microsoft .NET Micro Framework 4.1 > Tools
3. Run MFDeploy.exe. Be careful to run MFDeploy.exe and not MFDeploy.exe.config (as file extensions are hidden by default)
4. Plug your Netduino into your PC using a Micro USB cable. If your Netduino does not connect successfully, try plugging the USB cable into your Netduino first...and then your PC.
5. In the Device section at top, select USB instead of Serial. Your Netduino should appear in the drop-down; if not, select it.
6. Click "Browse..." and select the unzipped files from step #1 (ER_CONFIG and ER_FLASH).
7. Press "Deploy". It will take a few minutes to update your Netduino.
ASSEMBLY NOTE: You will need to manually add the SecretLabs.NETMF.IO assembly as a reference in your project to use the SD feature. You will also need to add the System.IO assembly.
Please let us know if this:
[a] works with your SD card
[b] reduces/eliminates any "could not reboot Netduino" messages in Visual Studio
[c] causes any other errors
Also, please note that some VMs may lose their connection to the Netduino when it reboots. If your VM loses its connection to the Netduino during deployment, it will give you an error that the debugger failed to connect. If this happens to you, please let us know in this thread.
Chris
I'm not sure what you guys did differently with this build but it is the most stable with respect to debugging than any other release that I have been able to try. I initially thought that the 4.1.0.3 Alpha was a great step towards fixing my debug errors ("There was a problem with the hardware", "Rebooting device..." (which doesn't seem to go away until I unplug the Netduino)). It was much better with 4.1.0.3 but with the new 4.1.1 Alpha 1 release. I'm able to stop and restart a debugging session without fail. I'm also able to compile with Visual Studio and go to MFDeploy and connect to the device and actually see the Debug.Print statements in the output window. I have not seen any issues or differences with my existing code. Thank you, thank you, thank you!!
PS I'm using Win 7 Ultimate x64, Visual Studio 2010 Ultimate, .Net MF 4.1 QFE 1 and now the v4.1.1 Alpha 1 firmware all without being in a virtual environment.
- Gui Ambros likes this
#18
Posted 05 September 2010 - 09:02 PM
#19
Posted 05 September 2010 - 09:10 PM
Looks like you guys have a good reason to buy a MBP ;-)
Which MacBook Pro are you using? We have an aluminum MacBook here which we use for testing...
#20
Posted 05 September 2010 - 09:20 PM
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users