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.

Kermit's Content

There have been 78 items by Kermit (Search limited from 25-April 23)


By content type

See this member's


Sort by                Order  

#29279 General Utilities

Posted by Kermit on 16 May 2012 - 05:43 PM in General Discussion

Hi to everybody. You know I'm a software guy, so, after having been helped so many times here, I try to give something back, even if I know I don't have the electronics expertize to be sure that I'm going in the right direction. So I invite you to read the readme, and, if you want, take a look at the code: I would like to receive some feedback by the experts, to understand if I'm going on the right direction, or if I'm missing something important, like performance, memory size, and I don't know what else... Andrea

Attached Files




#29049 TLC5940

Posted by Kermit on 14 May 2012 - 09:15 PM in General Discussion

Hi Mark (Nevyn? :-)). As usual, you are right, even to be convinced I had to read the datasheet three more times! :-) It's so strange that I'm used to software, but electronics is still so hard to grasp, for me! :-( Anyway, if the DC registers are random, it's so strange that in the current chip they are all at 100% minus one (at least for what I can say, looking the leds...) Other things to test... I will never see the end of this!!! :-))) Andrea P.S.: I could use this pwms to control three L293Ds with attached motors, and at least this part flowed really smooth! Motors go up and down without any problem!



#29024 TLC5940

Posted by Kermit on 14 May 2012 - 03:31 PM in General Discussion

QUICK UPDATE: I changed the chip (I got 6 of them :-)), and all the outputs (minus one!) are uniform and smooth, so the code, for what I can see, is perfect. One output is kind of flickering, something like 10 20 times a second, but never going completely off, for what I see. The strange thing is that if I move the wires, in some position the flickering goes away. Can it be some sort of interference? Andrea



#29022 TLC5940

Posted by Kermit on 14 May 2012 - 03:20 PM in General Discussion

Hi, Nzc, nice to hear from you again, thanks! No, of course I'm not looking for a power output, maybe I already said I'm to use the outputs to feed some L293Ds to control DC motors, so a few milliAmpere are more than enough. But on my side, if I feed (an external and stabilized) 5V I get erratic behaviour from the TLC5940, while with 3.3V (and coming from the Netduino!!!) it's all really perfect and smooth. Dot correction: in the datasheet it's said that to override it I have to give a more than 20VDC, and I'm pretty sure that I don't have such a supply! :-) So each time I turn on the chip, it should have just the factory set (1.0). In your code you don't set the values, so it should be all normal. ...I'm going on with my tests... A



#29012 TLC5940

Posted by Kermit on 14 May 2012 - 02:19 PM in General Discussion

Ok, since I didn't give up, and made again all the steps suggested in this, as in other, thread, I finally found (I must have made something wrong on the first trial) what the problem really is: NEVYN was totally right, in the high level limit for the 5VDC used as Vcc. The datasheet is clear, even if I didn't pay too much attention on this: the high level limit is 0.8 * Vcc, so Netduino pins cannot drive the signal high (Nevyn says 0.7, but I think he hadn't the datasheet just in front). When powered by a 3.3 signal, all is smooth and good, under any condition, so I think this is the right solution to have. My only remaining problem is now that some of the pins are always off, some are partially powered, and so on. Now, there are two alternatives... one is that the source code I'm using (by NZC) still has some bug :-))) (no critics, here: you've done a wonderful work!) OR there is some dot correction on the chip (but this looks a little improbable... I never gave it the 20more VCC to write it! Some other test will solve (I hope) the situation! :-) I'll prepare a Fritzing commented diagram for the solution... Andrea



#28941 TLC5940

Posted by Kermit on 12 May 2012 - 10:08 PM in General Discussion

No, it's really stranger than what I said: if I use directly led+resistor, all is smooth and soft... when using the TLC5940 all changes... :-((( Mario was right, when he said that this is a very strange chip... :-((( I don't know what to do: I changed the breadboard, the wires, and the netduino is perfect, using for example a motor with an L293D, but when I use the TLC, I have to touch the wires, and not always it behaves well... :-( I have three of them, and all show this behaviour! Bewitched chip... I'm sure... :-) Andrea



#28858 TLC5940

Posted by Kermit on 11 May 2012 - 09:42 PM in General Discussion

Ok, it looks I have to excuse myself (again!) for the trouble I caused in this thread! :-( I finally found the *REAL* problem I'm having. One of the connectors of my Netduino is faulty ! :-((((((( The block from D8 to Aref is loose, in the sense that I put the wires inside, but it makes a strange contact (I suppose). I don't know how to explain it well in English, but if I put a finger on the wires, not on the connector itself, and push them left (or right, it's the same thing) the contact becomes perfect, and everything is ok (LEDs fade on and off really smoothly!). If only I relax the push (without even taking out the finger completely) and all becomes flashy and flickering. What do I have to do, in a case like this? First option is of course to throw it away, and buy another... but is there anything else to do? I don't think that desoldering it can be the right thing to do... Andrea



#28851 TLC5940

Posted by Kermit on 11 May 2012 - 07:17 PM in General Discussion

@nzc: I tried commenting and uncommenting, but the problem still remains... led is flashing, as I said, even with the program stopped in the debugger. Andrea



#28848 TLC5940

Posted by Kermit on 11 May 2012 - 06:29 PM in General Discussion

I made another test: I took an ATX PSU from a computer I don't use, opened it and taken +5VDC and ground. Moreover, before using this power, I put a big big capacitor (100uF, 400VDC), to be sure the voltage is really stabilized. I don't have an oscilloscope, but with a voltmeter I measure 5.01 VDC (constant, for what I can see). Led is still flashing very very quickly (I tried to lower SPI frequency too). The strange thing is that if I check again between VCC and one of the pin, when set to 4000 (fixed, the program stopped at a breakpoint), voltage is floating between about 2.00 and 2.50 (and this explains maybe why the led is flashing). So it looks like (again) it's not a software problem, but an electric problem. I clarify that I'm not pinning VPRG and DCPRG to anything (they are free to float): could this be a problem? Andrea



#28831 TLC5940

Posted by Kermit on 11 May 2012 - 03:55 PM in General Discussion

Brilliant idea: it made me think. But, when I tried, I got no output on the leds: even on pins that should be high, voltage difference was very close to zero... Nzc: can you confirm you go on external 5VDC? Andrea



#28815 TLC5940

Posted by Kermit on 11 May 2012 - 12:33 PM in General Discussion

Sorry, I didn't write the right thing, of course I have the LEDs, and I checked with the voltmeter, between Vcc and signal.



#28805 TLC5940

Posted by Kermit on 11 May 2012 - 10:10 AM in General Discussion

Ok, it looks my problem is just on the electric side of things... :-( To give a +5VDC to the TLC5940 I use and old power supply (variable) that gives a NON stabilized output: so I put a big capacitor between + and - before feeding an L7805 to get the right output. If I check with the voltmeter the positive where I wire a LED and the ground, I see a strange (at least for me) phenomenon: the voltage is something between 4.8 and 5.02, with a period of 10/15 seconds (the program is running, fading on and off a couple of leds). Is it normal, or really I have to find another source of input voltage? Leds are fading with a visible flickering... Andrea



#28785 TLC5940

Posted by Kermit on 10 May 2012 - 08:45 PM in General Discussion

No, I don't have an oscilloscope: with my friend, we are thinking to buy one half and half, just to have it available, but not at the moment. Tonight I'm busy, but thanks for your suggestions: I'll try them tomorrow morning, and yes, I would follow Texas flowchart as strictly as I can. Andrea



#28780 TLC5940

Posted by Kermit on 10 May 2012 - 05:55 PM in General Discussion

Each time that a duty changes, small or big increment, it looks like there is a black hole, where the led doesn't receive current. If I make a cycle stepping by 1 very quickly, it's really flickering on and off. I didn't have the time to test it thoroughly, I'm sorry: I try to step into the code (and the datasheet) when I have some time for me... :-( Andrea



#28770 TLC5940

Posted by Kermit on 10 May 2012 - 11:37 AM in General Discussion

@Nzc: I'm using your code, but in my case I see a great flicker, when changing values. I'm stepping inside to understand if I can improve it, or at least understand where is the problem, on my side. Andrea



#28759 TLC5940

Posted by Kermit on 09 May 2012 - 09:28 PM in General Discussion

Not that I know of... :-( Good night, and thank you again! Andrea



#28756 TLC5940

Posted by Kermit on 09 May 2012 - 09:09 PM in General Discussion

@NZC I thank you really much, because at last I found my problem: one of the wires I use on my breadboard was partially broken, or better, could not make a right contact on the netduino. Since I saw that the led pulsed erratically, I started to change the wires one by one, and I found the faulty one. Once I changed it, everything was ok!!! :-(((((((((( If you didn't gave me all the indications to have a functioning solution (thanks to the schematic on sparkfun too!) I could never think to a faulty wire! :-) Andrea



#28748 TLC5940

Posted by Kermit on 09 May 2012 - 08:22 PM in General Discussion

@nzc: why did you say vprg is not wired out? From the pictures and the schematic, it looks just right there! Andrea



#28747 TLC5940

Posted by Kermit on 09 May 2012 - 08:16 PM in General Discussion

I've now seen the schematic (at last I could find a sharp reference! :-)): there are TWO resistor, so the formula is different. You can read it directly, and correctly, on that schematic. Wonderful, I try to replicate that schematic right now! :-) Andrea



#28745 TLC5940

Posted by Kermit on 09 May 2012 - 08:14 PM in General Discussion

Goedenavond ;)
According to the schematic, it's not such a difficult set-up.
The 2k2 resistors are, according to the description "to make this board suitable for use with servos".


This is really strange: at the end of page 14 of the datasheet (http://www.ti.com/li...ink/tlc5940.pdf) there is the formula to use for the resistor.

Iout = 39.06 / R (simplified)

with the range of 5mA and 120mA.
I use a 100 Ohm resistor (but I could never light any led!) giving an output of 39mA, with your resistor you should have 0.017mA, way under the lower limit.

Are you sure there are no other components wired to Iref?
Andrea



#28738 TLC5940

Posted by Kermit on 09 May 2012 - 07:16 PM in General Discussion

I'm going home, I'll give it a try as soon as I can, but I fear that I don't have the right passive components around the chip, and I'm not able to derive them from the datasheet :-( Andrea



#28734 TLC5940

Posted by Kermit on 09 May 2012 - 06:55 PM in General Discussion

Ops... I see you are using a breakout board: so maybe there is some component inside that I cannot be able to replicate... :-( Andrea



#28733 TLC5940

Posted by Kermit on 09 May 2012 - 06:54 PM in General Discussion

Ok, let's start with that. I think the driver will need some work still. I'll post code and pictures when I get back home tonight.


I hope to find you online... in which timezone are you? What do you mean by 'tonight'? :-)
Andrea



#28712 Modbus-TCP is now for Windows Phone too

Posted by Kermit on 09 May 2012 - 12:04 PM in Project Showcase

I'm really sorry to change cards again... :-) I tried to do my homework, during lunch :-), so I googled to try to understand what you could mean, and I find out that I can buy a complete arduino solution for as little as 6 euros (ATMega328 + spare parts), so, if this is programmable in C/C++ and has characteristics similar, more or less, to the netduino, this can be interesting for other eventual ideas where cost is an essential factor. So, now... ehm... if the satellites for the trains can be done using this solution, it would be even better; but now one IMPORTANT question comes to my mind: it's true that C#, visual studio, debugger, etc. etc., but what happens to my projects if ALSO the main unit becomes an arduino? Is it sort of a heretic question here??? :-) I feel that I can ask this here, since I've been many times certified professional with microsoft, certified partner with my (small) consulting firm, and grown up with Microsoft C/C++ 6.0 in DOS: is there (still) anyone remembering this last one? I kept its manuals in my library even now! :-))) Andrea



#28710 TLC5940

Posted by Kermit on 09 May 2012 - 11:29 AM in General Discussion

I'm working on a driver for the Tlc5940 for Netduino. I use the PWM ports from the Netduino to control the BLANK and GSCLK cycles, and the output looks pretty smooth to me, no flicker whatsoever. I have a GSCLK period of 2 microseconds, BLANK on 4096 times that, so roughly 10 ms per PWM cycle. Communication on the SPI port runs at about 40 MHz (if I can believe the documentation ;) ), I don't see any noticable interruptions when switching the signals.

I use a shield from Sparkfun, not all pins are exposed there (notably VPRG), but for now it'll do. I actually wanted to ask if there is anyone interested in code like this. Maybe I should just put it on Sourceforge?


...mmmmmmm... why do you think I could be interested? :-))))))))))
Apart from jokes, I already thank you so much, moreover, I hope you can share the schematic too, I'm only a software guy, and I found a lot of problems to wire cables and components correctly...
I'm *really* waiting for you! :-)
Thanks again
Andrea
P.S. You can also attach files just here... :-)




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.