Page 1 of 1
Can you work with WS2812 LEDs in Flowcode v4 AVR
Posted: Wed Feb 05, 2014 5:39 pm
by theoneandonly2002
Hi,
I have seen this software and it looks pretty simple. I have the cahnce to get a used version of flowcode v4 AVR on ebay and I am thinking to buy it.
I would like to program a microcontroller and driving some ws2812 LEDs.
I havent found anything, if flowcode is able to work with WS2812 LEDs. I just found out that a nanosecond delay that is needed to drive these LEDs is not possible with flowcode.
Is there another way driving the WS2812 LEDs with flowcode?
I just want to make sure before I buy this version.
Thanks
Re: Can you work with WS2812 LEDs in Flowcode v4 AVR
Posted: Wed Feb 05, 2014 9:22 pm
by JohnCrow
Hi
I've moved your post to a more suitable section.
Tips and tricks section is for posting programming tips only, not for general questions.
If you are looking at buying a used copy, I suggest you make sure it is a genuine copy otherwise you may not be able to activate it. Matrix staff will advise on the legality of buying used software.
Im not familiar with the component you want to use, but have you tried downloading the free version of FC to get a feel for it and see if it will drive the LED.
Re: Can you work with WS2812 LEDs in Flowcode v4 AVR
Posted: Sat Feb 15, 2014 6:04 pm
by Spanish_dude
It all depends on what oscillator your AVR will run. You can always write your own delay functions.
I just made a flowcode program using ASM to drive a WS2812 LED from a PIC microcontroller (16F876) running at 5MIPS/20MHz.
I didn't need a nanosecond delay function because the PIC runs just fast enough that adding a NOP here and there while toggling the I/O makes the desired communication protocol.
(see french section of this forum)
- Nicolas
Re: Can you work with WS2812 LEDs in Flowcode v4 AVR
Posted: Sat Feb 22, 2014 8:28 am
by theoneandonly2002
Spanish_dude wrote:It all depends on what oscillator your AVR will run. You can always write your own delay functions.
I just made a flowcode program using ASM to drive a WS2812 LED from a PIC microcontroller (16F876) running at 5MIPS/20MHz.
I didn't need a nanosecond delay function because the PIC runs just fast enough that adding a NOP here and there while toggling the I/O makes the desired communication protocol.
(see french section of this forum)
- Nicolas
What exactly is a NOP???
Can you add a picture of the "flow chart" (print screen) of you programm?
Thanks
Re: Can you work with WS2812 LEDs in Flowcode v4 AVR
Posted: Sat Feb 22, 2014 1:05 pm
by Spanish_dude
NOP is an instruction where the microcontroller does nothing for 1 clock cycle.
There's nothing to see in my flowchart but 3 functions written in inline assembly and a C box in my main loop, which contains inline assemble too.
You should check out AVR libraries for driving WS2812 LEDs. Get the C code out of it and try to implement it in flowcode.
My code won't work on an AVR because it's written in ASM for PICs, which is not compatible with AVR.
I've attached the flowcode file and C code.
- Nicolas
Re: Can you work with WS2812 LEDs in Flowcode v4 AVR
Posted: Fri Feb 28, 2014 1:07 am
by Alberta2012
I really wish someone would come up with a "core program" based on an AVR....
I've looked at the WS2812 and I have no clue how to get started. I'm not good in 'C' , so that does not help !
Would be nice if Matrix, instead of coming up with mecanical simulation for V6 (IMHO), would have created blocks that would have that code embedded for us !
they could have built blocks for other stuff like X-10, DMX-512, etc .... something that you simply drop and configure...
just a thought...
Jasmin
Re: Can you work with WS2812 LEDs in Flowcode v4 AVR
Posted: Mon Mar 03, 2014 10:54 pm
by Spanish_dude
Not sure what you mean by core program, but don't expect people to just do everything for you, that's not how it works.
I'm sorry it didn't help, but maybe you're starting with something too difficult for you to do with the knowledge you have right now about programming AVRs.
Start with something easy then go bigger and bigger.
Matrix makes flowcode components for their e-blocks.
You can make your own components/functions with flowcode too.
I think the mechanical simulation in V6 is pretty amazing. I don't know what the capabilities of it are, but making a 3D printer or CNC or even a robot and then be able to simulate it is awesome.
Re: Can you work with WS2812 LEDs in Flowcode v4 AVR
Posted: Tue Mar 04, 2014 12:42 pm
by Benj
Hello,
Would be nice if Matrix, instead of coming up with mecanical simulation for V6 (IMHO), would have created blocks that would have that code embedded for us !
they could have built blocks for other stuff like X-10, DMX-512, etc .... something that you simply drop and configure...
We have done hardware and software for X10 before and it just didn't sell, especially in the UK so we dropped it.
DMX can be controlled via MIDI.
v6 is not about mechanical simulation, it's about allowing you to create your own components. The fact we can now do mechanical simulation is a bonus.
Spanish dude's comments are good, maybe start with something simpler and work your way up.
Re: Can you work with WS2812 LEDs in Flowcode v4 AVR
Posted: Sat Nov 22, 2014 4:35 am
by MALLED
Can the flowcode work for this easy
diy ws2812b matrix? they are designed in vertical circuit.