- Netduino Forums
- → ash's Content
ash's Content
There have been 65 items by ash (Search limited from 26-June 23)
#33503 Camera Modules for any Netduino
Posted by
ash
on 13 August 2012 - 07:49 AM
in
Netduino Plus 2 (and Netduino Plus 1)
#33590 Camera's
Posted by
ash
on 14 August 2012 - 01:47 PM
in
General Discussion
#43144 cant deploy to plus 2
Posted by
ash
on 11 January 2013 - 11:01 AM
in
Netduino Plus 2 (and Netduino Plus 1)
with have the new batch and ive upgraded to 4.2.2. also updated the netdunino sdk. ive already got the 4.2 qef sdk installed but when i try to deploy my old netdunino plus code to the plus 2 it fails!!!! please help
#43148 cant deploy to plus 2
Posted by
ash
on 11 January 2013 - 11:56 AM
in
Netduino Plus 2 (and Netduino Plus 1)
got it going but ive got an issue which im not sure about yet but i tried to go back to my plus 1 and now it wont deploy to that!!!! we have devices with version 1 out there
#43172 Com2 on the plus 2
Posted by
ash
on 11 January 2013 - 04:17 PM
in
Netduino Plus 2 (and Netduino Plus 1)
serialPort = new SerialPort("COM2", 38400, Parity.None, 8, StopBits.One);
hi, sorry. its noting special
#43173 Com2 on the plus 2
Posted by
ash
on 11 January 2013 - 04:18 PM
in
Netduino Plus 2 (and Netduino Plus 1)
changing the baud rate
public bool ChangeBaudRate(Baud baudRate) { byte b1= 0x2A,b2= 0xF2; switch (baudRate) { case Baud.B57600: b1 = 0x1C; b2 = 0x4C; break; case Baud.B115200: b1 = 0x0D; b2 = 0xA6; break; } byte[] outbuff = new byte[] { 0x56, 0x00, 0x24, 0x03, 0x01, b1, b2 }; serialPort.Write(outbuff, 0, 7); byte[] inbuff = WaitForResponse(5, 50); if ((inbuff[0] == 0x76) && (inbuff[2] == 0x24)) { serialPort.Close(); serialPort.BaudRate = 115200; serialPort.Open(); return true; } return false; }
#43382 Com2 on the plus 2
Posted by
ash
on 14 January 2013 - 12:20 PM
in
Netduino Plus 2 (and Netduino Plus 1)
I dont think its the com port as i did a loop back test and it seemed ok but 100% sure.
Attached Files
-
CameraTest.zip 108.81KB 10 downloads
#43182 Com2 on the plus 2
Posted by
ash
on 11 January 2013 - 04:49 PM
in
Netduino Plus 2 (and Netduino Plus 1)
i dont a small project which basically sets up the camera, takes a pic and returns the pic as a byte array and yes the same issue is there.
public byte[] GetImageData(int imagelength) { byte bdelay1 = 0x00; byte bdelay2 = 0x0A; byte bPos1 = 0x00; byte bPos2 = 0x00; // datalength of 496. Camera transfer maximum 512 bytes at a time. Each packet has 5 bytes at the start and 5 at the end // and the datalength must be a multiple of 8. So 496 is the biggest we can have byte bLen1 = 0x01; byte bLen2 = 0xF0; byte[] outbuff = new byte[] { 0x56, 0x00, 0x32, 0x0C, 0x00, 0x0A, 0x00, 0x00, bPos1, bPos2, 0x00, 0x00, bLen1, bLen2, bdelay1, bdelay2 }; int numPackets = imagelength / 496; if (imagelength > (numPackets * 496)) numPackets += 1; byte[] imageData = new byte[imagelength]; for (int i = 0; i < numPackets; i++) { int pos = i*496; // Ask for the next packet outbuff[8] = (byte)(pos >> 8); outbuff[9] = (byte)(pos & 0xFF); serialPort.Write(outbuff, 0, outbuff.Length); int bytesToRead = 506; if ((imagelength - pos) < 496) { bytesToRead = (imagelength - pos) + 10; } WaitForData(bytesToRead, 100, imageData, pos); } StopPic(); return imageData; }
as i step over the code the debug line dissapear when i do a serial.write and it looks like the system has crashed as there is nothing else i can do!
#43177 Com2 on the plus 2
Posted by
ash
on 11 January 2013 - 04:28 PM
in
Netduino Plus 2 (and Netduino Plus 1)
thanks mark but with we need more than 10 and need to get this working on the 2's as it will benefit everyone as there is an issue here. like i said it works fine the np1 and falls over on the np2.
#43156 Com2 on the plus 2
Posted by
ash
on 11 January 2013 - 03:15 PM
in
Netduino Plus 2 (and Netduino Plus 1)
byte[] outbuff = new byte[] { 0x56, 0x00, 0x32, 0x0C, 0x00, 0x0A, 0x00, 0x00, bPos1, bPos2, 0x00, 0x00, bLen1, bLen2, bdelay1, bdelay2 }; int numPackets = imagelength / 496; if (imagelength > (numPackets * 496)) numPackets += 1; byte[] imageData = new byte[imagelength]; for (int i = 0; i < numPackets; i++) { int pos = i*496; // Ask for the next packet outbuff[8] = (byte)(pos >> 8); outbuff[9] = (byte)(pos & 0xFF); serialPort.Write(outbuff, 0, outbuff.Length); int bytesToRead = 506;
as soon as you step over the last line, thats it! no more debugging and the program has crashed!
#43166 Com2 on the plus 2
Posted by
ash
on 11 January 2013 - 03:47 PM
in
Netduino Plus 2 (and Netduino Plus 1)
Adafruit was the place we got the plus 2's from because no where in the UK had enough stock and no stock of the plus 1's. We went for the Plus 2 thinking it would be a direct drop in replacement.
The funny thing is ive put my shield back on the plus 1 and its working as well as can be expected. Stick on the plus 2 the com2 and debugging is a nightmare.
Com 2 is set to 38400 initally until i set up the camera and the camera the baud rate to use is 115200. Then i close the port, change the baud rate and then re-open it. Any other comms after returns 0 bytes to read!
#43154 Com2 on the plus 2
Posted by
ash
on 11 January 2013 - 03:12 PM
in
Netduino Plus 2 (and Netduino Plus 1)
cant test on another com port as its a sheild. Works fine the plus 1 and there are a few deployed at our customers
One the plus 2 it seems the debugging is terrible. you step over while bugging and nothing happens!!! its hard to explain
I wish i never brought the plus 2 now but no where stocked the plus 1. im a tight dead line and these kind of hassles is not what i need right now!
#43151 Com2 on the plus 2
Posted by
ash
on 11 January 2013 - 02:08 PM
in
Netduino Plus 2 (and Netduino Plus 1)
compared to plus 1 the com port 2 is not behaving correctly. we got a serial camera attached and it does not get any data when we asked for it or when we write a buffer it just hangs!!! (Baud rate 115200)
#46769 Creating Log Files.
Posted by
ash
on 06 March 2013 - 04:39 PM
in
General Discussion
Dave thanks very much option b seems to the best and the most easy to implement
#46760 Creating Log Files.
Posted by
ash
on 06 March 2013 - 02:51 PM
in
General Discussion
I've a log file which i append to every so often. (Thats the easy bit)
What i want to do is if its gets above a certain size then delete the old 1 st line before add the latest line to the bottom of the file.
Is there a way of doing this? i cant exactly read the whole file as i will run out memory
#46613 Deployment without Visual Studio
Posted by
ash
on 04 March 2013 - 03:07 PM
in
General Discussion
Sorry if this has been discussed before but ive searched for a solution for this and was unable to come with a answer.
I've got a project in VS and i want to deploy across various target boards but i want to pass this task to another member of the team but i dont wish for him to have the source code.
Is there a way of the deploying the output binaries to the target device i.e. MFDeploy.
#46618 Deployment without Visual Studio
Posted by
ash
on 04 March 2013 - 04:41 PM
in
General Discussion
oh ok.
cool. i checked about last month for a solution.
It might be best to make it a sticky somewhere or part of a FAO.
#47977 detecting a AC voltage
Posted by
ash
on 03 April 2013 - 03:42 PM
in
General Discussion
I need to monitor a state of some 28VAC lines.
Hows the best way to do this?
I know i need a full bridge, some smoothing and a opto coupler but the bit inbetween the smoothing and opto im stuck on.
#48061 detecting a AC voltage
Posted by
ash
on 05 April 2013 - 08:56 AM
in
General Discussion
Thanks for the replies
Im aware of the 3700 but its expensive and im having to use components that if it becomes obsolete it can easily be replaced.
I've a circuit diagram which should do what i need
Attached Files
-
IO24OptoSCHV2..pdf 24.76KB 20 downloads
#48005 detecting a AC voltage
Posted by
ash
on 04 April 2013 - 08:19 AM
in
General Discussion
we are interfacing to some equipment so there are several inputs of 28VAC so using transformers and regulators is out of the question. The response needs to be pretty darn quick too. Basically its to detect a presence.
I know PLC's have AC/DC inputs, so i kinda need that input stage fitted to my NP2
#33017 dynamically loading assemblies
Posted by
ash
on 02 August 2012 - 12:12 PM
in
Netduino Plus 2 (and Netduino Plus 1)
#33014 dynamically loading assemblies
Posted by
ash
on 02 August 2012 - 11:14 AM
in
Netduino Plus 2 (and Netduino Plus 1)
byte[] assemblyData = GotSDCard ? File.ReadAllBytes(filename) : ServerHelper.DownloadFile(filename); if (assemblyData == null) throw new Exception("Assembly was empty"); try { Assembly assm = Assembly.Load(assemblyData); Debug.Print("loaded Assembly: " + filename);
it hangs on the Assembly.Load call.
In the output window i get
The debugging target runtime is loading the application assemblies and starting execution.
'Microsoft.SPOT.Debugger.CorDebug.dll' (Managed): Loaded 'C:\Program Files (x86)\Secret Labs\Netduino SDK\Assemblies\v4.2\le\SecretLabs.NETMF.Hardware.NetduinoPlus.dll', Symbols loaded.
How can i fix this or see whats going on?
#33024 dynamically loading assemblies
Posted by
ash
on 02 August 2012 - 03:58 PM
in
Netduino Plus 2 (and Netduino Plus 1)
#33022 dynamically loading assemblies
Posted by
ash
on 02 August 2012 - 01:22 PM
in
Netduino Plus 2 (and Netduino Plus 1)
![B)](http://forums.netduino.com/public/style_emoticons/default/cool.png)
#33020 dynamically loading assemblies
Posted by
ash
on 02 August 2012 - 12:43 PM
in
Netduino Plus 2 (and Netduino Plus 1)
![:(](http://forums.netduino.com/public/style_emoticons/default/sad.png)
- Netduino Forums
- → ash's Content
- Privacy Policy