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.

inxtremo's Content

There have been 32 items by inxtremo (Search limited from 24-April 23)


By content type

See this member's


Sort by                Order  

#34356 Large Project - Kinect Tracking Nerf Launcher

Posted by inxtremo on 29 August 2012 - 06:27 AM in Netduino Plus 2 (and Netduino Plus 1)

Any thoughts of concerns about going this route?


Hey, i have the similar devices running here. No problems so far. They move a mechanical pant/tilt device with a camera connected. The power of the stepper are ok for that.

Greetings,
Daniel



#30306 My Netduino CNC Machine

Posted by inxtremo on 06 June 2012 - 11:52 AM in Project Showcase

Hi, great projects in this thread. Wish my own cnc in the future. One simple and fast question, Has anyone implemented acceleration and deceleration for the stepper motors. Tried it myself but it not really works great. Thanks a lot, Daniel



#26088 Serial communication with FTDI Breakout Reloaded V1.1

Posted by inxtremo on 29 March 2012 - 11:24 AM in Netduino Plus 2 (and Netduino Plus 1)

A little off topic but...

the following line of code was posted in the example...

string line = System.Text.Encoding.UTF8.GetString(bytes);

This method does not exist under NMF 4.2. Did they pull it?


Hey,

as far as i know the GetString method does not exist in .NET MF. Try instead the GetChars method.

The sample you seen does not run on the Netduino. It is a class who sends the message to the Netduino. The class works with the full .NET 4 Framework.

Here is a code example how i do it.

private static void serial_DataReceived(object sender, SerialDataReceivedEventArgs e)
        {
            // wait a bit for filling the buffer
            System.Threading.Thread.Sleep(100);

            // message string
            string msg = null;

            // allocate a byte array
            byte[] bytes = new byte[_serial.BytesToRead];

            // read bytes
            _serial.Read(bytes, 0, bytes.Length);

            // send bytes back for error checking
            _serial.Write(bytes, 0, bytes.Length);

            // encode bytes to a string message 
            msg = new string(System.Text.Encoding.UTF8.GetChars(bytes));

            // split message
            if (msg != null)
            {
                // split parameter
                splittedMsg = msg.Split(',');

                // allocate array for the parameters
                int[] param = new int[splittedMsg.Length];

                // write parameter to the array
                for (int i = 0; i < splittedMsg.Length; i++)
                {
                    param[i] = System.Int32.Parse(splittedMsg[i]);
                }

                // do something
                switch (param[0])
                {
                    case 0:
                       blaaa ....
                       break;
                    default:
                        break;
                }
            }
        }

Best regards,
Daniel



#25379 Powering EasyDriver Question

Posted by inxtremo on 11 March 2012 - 04:16 PM in General Discussion

Hay, i think i have the soultion. Changing the voltage from my power supply from 12V to 5V makes it moves fine. I don´t know why but i´m happy that it works now. Thanks or the great help. Best regards, Daniel



#25248 Powering EasyDriver Question

Posted by inxtremo on 08 March 2012 - 06:26 PM in General Discussion

Forgive the obvious. That power supply was delivered to you pre-assembled. You tested it after you built it right? You got a cordless drill battery laying around?


Both, the power supply and the "breadboard power supply" were pre-assembled. I tested the breadboard power supply a few weeks ago but there nothing worked.

Option 1:
I power both drivers with the "breadboard power supply" (5V) and drive two steppers with each 12V and 330mA. The external power supply is 12V and 1500mA. --> Both steppers moves but not really well. I think the 5V is too less.


Option 2:
I power both drivers with the "breadboard power supply" (5V) and drive two steppers with each 4V and 1200mA. The external power supply is 12V and 2500mA. --> Both steppers moves but not really well but better as with the 1500mA power supply.

Option 3:
I power both drivers with the "breadboard power supply" (5V) and drive two steppers with each 12V and 330mA. The external power supply is 12V and 1500mA. --> Both steppers stands still.

Option 4:
I power both drivers with the "breadboard power supply" (5V) and drive two steppers with each 4V and 1200mA. The external power supply is 12V and 2500mA. --> Both steppers stands still. But it seems they try to move.

Directly connection the external power supply bring no movement at all.

And suggestion. Maybe i have the wrong power supply? But i tried three different types now. the last from my ole notebook with 18,5V and 3,5A.

Update:

Try to connect an ATX-Power supply from an old PC. 12V max 30A. One driver moves a little bit.

Interestingly the steppers moves at the beginning of the test. Later there is often no more movement like in the beginning (10sec later or so). It seems like there is a rechargable becoming empty :huh:

Thanks



#25246 Powering EasyDriver Question

Posted by inxtremo on 08 March 2012 - 05:53 PM in General Discussion

Also, the link you show on outlet is 5v regulated. I can power one motor off 5v but not 2. You seriously got N+ to power 2 Nema 17's off the board?


Yes, that is right. But at this moment i making an interesting discovery.

When i connected this breadboard power supply, i can move sometimes move one of the stepper, sometimes both. I changed the power supply from 1,5A to 2,5A and both steppers moves better but with a poor torque.

If i drive only one stepper (4V), the stepper moves fine, but with poor torque too.

If i connect the power supply directly, nothing moves.



#25242 Powering EasyDriver Question

Posted by inxtremo on 08 March 2012 - 05:06 PM in General Discussion

The delay between my steps is Thread.Sleep(1), on default and the code works fine powering through the N+.

The main code is the following:

private void MoveStepper(int numberOfSteps, bool onFirst, int onTime, int offTime)
        {
            if (!Working)
            {
                Working = true;
                steps = numberOfSteps;

                if (onFirst)
                {
                    for (int x = 0; x < steps; x++)
                    {
                        this._StepPin.Write(true);
                        Thread.Sleep(onTime);
                        this._StepPin.Write(false);
                        Thread.Sleep(offTime);
                    }
                }
                else
                {
                    for (uint c = 0; c < steps; c++)
                    {
                        Thread.Sleep(onTime);
                        this._StepPin.Write(true);
                        Thread.Sleep(offTime);
                        this._StepPin.Write(false);
                    }
                }

                Working = false;
            }
        }

But i don´t understand why it works with Netduino-Power and not with the external power.

For information, i tried to power the steppers with an external power supply a few weeks ago too. At this time i connected two steppers with each 12V and 330mA. It didn´t work. Also i tried to use an breadboard power supply, the same as this one My link, this alos didn´t work. I thought the problem was the 5,5V output, but the N+ also delievers only 5V.

:(


Thanks.



#25239 Powering EasyDriver Question

Posted by inxtremo on 08 March 2012 - 04:50 PM in General Discussion

I have both motors and your wiring looks fine at a quick glance. I ended up buying an adjustable power supply to tinker with these. The smaller motor is a pain but the Nema 17 purrs when you adjust the current setting on the Easy Driver board. Have you played with that screw?


Hi,

yes i have played with that screw. Sometimes the stepper seems to move a little bit but not more. I can adjust my power supply too, but only from 3V - 12V.



#25236 Powering EasyDriver Question

Posted by inxtremo on 08 March 2012 - 04:09 PM in General Discussion

Hi
Just be aware that breadboards often have a break in contact along the power rails at mid point.

If that is not it then you will have to get the multimeter out.

I will give you a few suggestions, I am hoping one of them will lead you to the answer.

Measure the correct DC voltage onto the little driver boards. Are they correct?

Turn the power off and make sure you get DC continuity everywhere you expect it. especially GND and + 12.

Also the analogue ground pin is connected in your circuit but I wouldn't use it as the track width may not be enough.

Make sure the grounds between the 2 power supplies are well connected.

Dont connect 12v from two separate power supplies together. just connect their GNDs.

Your Gnd seems overly complicated. Each board should only need one gnd wire, I would try removing your ground wires that go with the Yellow and White wires.
Use a star topology for the Gnd. based around your breadboards somewhere. ie. All grounds connect from this breadboard row.


Hey,

i tried it several times now. Remove all wires an replace them, reorder my grounding and using an other power supply. Nothing works. One of the two steppers, the model with 4V moves a few steps, but only once.

Also i can hear a noise from my power supply. The noise get higher when i try to move a stepper. After stepping the noise retuns to a lower frequency.

Excactly the same setup works great if i power the shields through the 5V Pin on the N+. Also the steppers moves great.

Strange thing.



#25224 Powering EasyDriver Question

Posted by inxtremo on 08 March 2012 - 12:02 PM in General Discussion

Hi
I am looking at the circuit now, I just wanted to say brilliant documentation, your problem deserves to be solved. What did you use to do it in?

A few quick queries why does one motor say 12 volt 330 ma and the other say 4 volt 1200 mA? Are they separate power supplies or set to different current limits.

You haven't mixed up the step and direction pins have you ( probably not but it needs to be checked).

Have you tried disconnecting one motor entirely? No point really connecting two motors until you get one working.

Do you have a multimeter?


Hi, thanks a lot.

I used Fritzing, you can find a free copy here. There are several *.svg Files for many electronic stuff. They have an extra section for stuff from Sparkfun too.

I have just one power supply attached (12V and 1500mA). That what you mean are the steppers. I have one stepper with 4V and 1200mA for the heavier stuff and one smaller motor with 12V and 330mA.

The steppers works fine if i power the two EasyDrivers with the Gnd and 5V Pins from the N+. It just works not if i change the power to my external supply, so i think the wiring of the steppers are correct.

I also tried to power just one stepper instead of two, same result. Also powering both EasyDrivers separately with two power supplies didn´t work.

The big circuit at the end of my first post shows the working setup. It all works really fine. The only thing i want to change is powering the two EasyDrivers through external power.

I will try another power supply this evening, may the power supplies are wrong. Here is the specificationfor who is interested.

Yes, i have a multimeter.

Magpie, thanks for the answer.



#25207 Powering EasyDriver Question

Posted by inxtremo on 08 March 2012 - 08:02 AM in General Discussion

I thought you would have a ground there somewhere.

My Palm is really great, but its technology/software is around four years out of date now.
It gives up on web pages over 1MB, does not do java, and unfortunately (as in this case) won't open large images in the browser.
One day I 'll move on to an Android device...
I hope my Palm didn't see that.
Paul


:D

I don´t know the Palm in real, but i find it very hard to follow wires in a big image with such small screens. I see it on my Android device here. But hey, the new Android devices getting bigger and bigger. Last week i see a guy with a device on his ear, i first thought this was a tablet :)

Greetings



#25198 Powering EasyDriver Question

Posted by inxtremo on 08 March 2012 - 06:38 AM in General Discussion

What is the model of the stepper motors?


Hi Bendage,
sorry, i forgot to link them in the first post

Stepper1, Stepper 2

... does not show a ground connecting the Netduino to the shields. You will need a ground - otherwise the logic signals won't drive the shield properly.
Paul


Hi Paul,

i grounded the shield with the N+. In the first two images i reduced the wiring only for set the focus on the power supply. At the end of my first post i linked a image (as an URL) where you can see my complete setup. There i grounded the stuff. But i´m sure its hard to see with an Palm :-)

The setup shown in the last image works fine. The stepper running. But it is no good idea to drive the steppers through the N+. May the N+ will burn if i do this.


Thanks for the answers and best regards,
Daniel



#25179 Powering EasyDriver Question

Posted by inxtremo on 07 March 2012 - 07:23 AM in General Discussion

Hi,

i have a question about powering an EasyDriverStepper Motor Shield.

I want to drive two different steppers. My current assembly looks like this:
Posted Image

I powered the two EasyDrivers through the N+. But i know that this setup is not the best. So i try to power the two EasyDriver Shields with an external power supply like here:
Posted Image

But this setup don´t work. If i try to drive a stepper, the stepper buzzes very short for the first time and then do nothing. Both steppers stand still.

I know i´m not in the right forum for this question, but hope somebody can give me an answer for this.

For further information, here is a link to an image of my complete setup.

Thanks and best regards,
Daniel



#25178 Smooth acceleration and deceleration of a stepper motor

Posted by inxtremo on 07 March 2012 - 06:45 AM in General Discussion

Hi there,

I am used to working on DSP designs where it is sometimes necessary to step through an array of values at a fractional rate.
For example, generating a sine wave with an arbitrary frequency using a 256 point sine wave lookup table that is stored in an array. To do this you need an integer index to access the table, but the index needs to increment (or decrement) in non-integer steps :blink:

This sounds like a similar problem as you are trying to solve.

The solution for generating a sine wave is to store the floating point increment in a variable and add it to a running floating point counter when each sample period comes round.
To fetch a value from the array, we simply use the integer part of the counter.
In the background the fractional parts will eventually add up to an extra step every so often and this gives the impression that the table is being stepped through at a non-integer rate.

How does this help you? Stepping though an array at a fractional rate is similar to stepping through time at a fractional rate.

Create a floating point millisecond counter variable.
Each time you need to implement a delay between steps, take your desired floating point millisecond delay value and add it to the counter.
Then, take the integer part of the counter and use it for the next millisecond delay.
Deduct that integer value from the counter.

Doing this will average out the fractional parts that you can't express in a delay of integer milliseconds, and the result should be a smooth stepper movement.

Hope this helps - Paul


Wow, thanks a lot.

I think at weekend i have the time to think about your answer in more detail. I´ll post my results.

So far, i re-implemented a method for trapezoidal acceleration i seen for the Arduino. Works fine but i´m sure there are lot of space to improve this.

Thanks and best regards,
Daniel



#24948 EasyDriver Class for Stepper Motors

Posted by inxtremo on 02 March 2012 - 06:47 AM in General Discussion

Hay, working with the class for a couple of days and all working fine. I opened an other thread because of acceleration of the stepper motor. Any chance this this will included in the class in future? Thanks for the great work. Regards, Daniel



#24851 Smooth acceleration and deceleration of a stepper motor

Posted by inxtremo on 29 February 2012 - 07:15 AM in General Discussion

Good morning, after successfully communicate with my stepper motors via N+, FTDI Breakout Board and a WPF application i wonder how to accelerate and decelerate my steppers in a smooth way. On YouTube exists several examples, most on the Arduino plattform. I found a class for Arduino too, "AccelStepper", which make such things possible. But how to do that on a Netduino? Should i port an Arduino code snippet to C#? Most snippets i see using float numbers for the delay between 2 pulses, but on C# i can only use Thread.Sleep(int). Any suggestions on this? Thanks and best regards, Daniel



#24642 EasyDriver Class for Stepper Motors

Posted by inxtremo on 24 February 2012 - 10:50 AM in General Discussion

EasyDriver StepperMotor = new EasyDriver(Pins.GPIO_PIN_D12, Pins.GPIO_PIN_D13);             while (true)             {                 StepperMotor.SetDirection(true);                 StepperMotor.RotateDegrees(360.0);                                  StepperMotor.SetDirection(false);                 StepperMotor.RotateDegrees(90.0);             }



Hey, try it without
while(true){ blaa blaa}

I don´t know this code but i will try it this weekend. So the tip above may not work. But as far as i seen is in this code
private void Activate(int NumberOfSteps)
        {
            if (!Working)
            {
                Working = true;
                Steps = NumberOfSteps;
                for (int x = 0; x < Steps; x++)
                {
                    _StepPin.Write(true);
                    Thread.Sleep(1);
                    _StepPin.Write(false);
                }

                Working = false;
            }
        }

the logic to drive the stepper. So you won´t need an extra loop.

Hope this is right.

Greetings.



#24251 Serial communication with FTDI Breakout Reloaded V1.1

Posted by inxtremo on 15 February 2012 - 10:34 AM in Netduino Plus 2 (and Netduino Plus 1)

:huh: :angry: It was the code. :angry: Now all is working fine here. I try to find the wrong stuff in my code. If i find something i will post it here as help for others. @dave & @hanzibal Many many thanks for your awesome help. I learned much. :) Best regards, Daniel



#24250 Serial communication with FTDI Breakout Reloaded V1.1

Posted by inxtremo on 15 February 2012 - 08:25 AM in Netduino Plus 2 (and Netduino Plus 1)

I think i will test the FTDI-Board like the N+ with bridging the ports.


Very interesting. Bridging the ports on the FTDI works too. :blink:

Maybe it is really the wrong FTDI Board for the N+.



#24248 Serial communication with FTDI Breakout Reloaded V1.1

Posted by inxtremo on 15 February 2012 - 08:08 AM in Netduino Plus 2 (and Netduino Plus 1)

Good morning,

things i tried:

  • Installing the Driver for the FTDI Board -> Don´t work
  • Installing the setup on an other PC -> Don´t work
  • Bridge the Ports on the N+ and send commands -> Works

So the N+ is ok. I think the FTDI is broken, may i can send it back. Hope the USB BUB from Netherlands arrives soon, so i can test it. Hope this time it will work.

I think i will test the FTDI-Board like the N+ with bridging the ports.

Greetings and thanks for the good help,
Daniel



#24229 Serial communication with FTDI Breakout Reloaded V1.1

Posted by inxtremo on 14 February 2012 - 01:36 PM in Netduino Plus 2 (and Netduino Plus 1)

EDIT: If you mean to test the UART in particular, you can always run a loopback test. To do this, simply bridge the tx and rx pins of the intended UART on your N+, then write an application that creates a serial port, sends a few bytes and verifies that the exact same bytes are also received ok.


Thanks for the tip, i´ll try it later. Blinky and other applications working fine.


Another silly question, but when you plug the FTDI board into your PC, does it show up in device manager and what does it show up as? I am just remembering that I had to install drivers on the PC because I was getting the same results as you in the beginning. I am using this breakout board and they had the drivers on the page for download. FDTI Basic Breakout

The FTDI show up as an USB/Serial-Device as far as i know. Have to look at home. On the original product page are no drivers for download but on the product page for the earlier release of this board. Thanks for the answer, i´ll give it a try. Incidentally, in Germany exisiter a proverb. "There are no silly questions, only stupid answers." So thank you very much for your help.



#24222 Serial communication with FTDI Breakout Reloaded V1.1

Posted by inxtremo on 14 February 2012 - 08:01 AM in Netduino Plus 2 (and Netduino Plus 1)

Do you now get a response when pinging the device from MFDeploy? This is a reguirement for anything else to work.


Good Morning,

no i didn´t test the ping yesterday after the firmware upgrade. I will test it today after work. I saw this cable earlier but it seems that there are only a few shops in Germany that sell such stuff. I ordered the USB BUB in Netherlands.

Is there a possibility to test my netduino if it is broken? As earlier mentioned, i am not that electronic guy and fairly new onto this. As i unboxed the netduino i connected two stepper shields and two stepper motors. Maybe i broke something because of wrong wiring? The two steppers works fine.



#24220 Serial communication with FTDI Breakout Reloaded V1.1

Posted by inxtremo on 14 February 2012 - 07:04 AM in Netduino Plus 2 (and Netduino Plus 1)

Good Morning,

here is the status quo.

I upgraded my firmware this evening with the new beta firmware Version: 4.2.0 RELEASE CANDIDATE (version 4.2.0.0 RC4)from here. There was a exciting 1 hour procedure but finally the firmware works :rolleyes:

The problem with the serial connection is the same. I can send via COM3 to the FTDI, the "TX"-LED on the FTDI blinks if i send a message but there is no reaction from the netduino.

I ordered a "USB BUB" this evening. This FTDI must work.

The next step, i´d like to connect the FTDI and the netduino on a other PC and try it there.



#24188 Serial communication with FTDI Breakout Reloaded V1.1

Posted by inxtremo on 13 February 2012 - 07:19 PM in Netduino Plus 2 (and Netduino Plus 1)

When I started I was using 4.1.1 b1 because of another issue and I know it worked with that. I'm not sure if it worked with 4.1.0.6.

Here is a crazy question, do you have the FTDI's ground connected to Netduino ground?


Ok, i´ll try an beta firmware, may it work.

Yes, i grounded the ftfi. I connected the stuff like here.



#24182 Serial communication with FTDI Breakout Reloaded V1.1

Posted by inxtremo on 13 February 2012 - 04:16 PM in Netduino Plus 2 (and Netduino Plus 1)

:unsure: no way. I tried an working code but the netduino don´t respond. Also if i pinging the netduino (serial) over the MFDeploy Tool, "Error: no response from device" Should i upgrade the firmware? Actual Firmware version on my netduino is 4.1.0.6 Maybe my netduino or the ftdi is broken but both are nearly new. Greetings, Daniel




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.