I have written a bunch of code for FIR filtering using both C and assembly for the BF706, sample-by-sample method. If anyone is interested, let me know.
I'm into BF706 for 2 days, so every additional semicolon of example code will be highly appreciated
Here is Patrick's first project I found on the forums for efficient codec transmission loop-back in and out in polling mode to get started with BF706. I wrapped it up in CCES project for your quick access and enjoyment. Saves everyone some time porting this over faster and run it in the debugger on the latest version of the compiler. I have not debugged this yet, so hopefully someone will...I will also check it when I get home...Took me 20 mins in a coffee shop...I will post some FIR Filter projects later.
Glad you found the programs useful. We teach BF706 to our undergraduate students, with a series of simple assembly programs that they have to complete. I also provide lectures on the architecture and the language – just enough to make it clear and get them started. I find that the data sheets are very comprehensive but rather overwhelming for the beginner. So I produce material that takes the essence and allows them to develop their own code.
If you are interested in these, please let me know.
Check out the assembly programs section. I left you a little note and started migrating your pdf slowly into CrossCore. I learned heck of a lot from your examples compared to hardly no help from ADI. Particularly that there is an easier way to get the BF706 going than I initially thought! Your work is definitely very helpful teaching others the right way to do this in old school fast assembly. The other examples that I got from ADI have issues and either lock up throwing some errors after some period of time. I was puzzled by this, because I took your audio example with DMA and commented the filter section from UweS with the crossover filter and I can get that sample to run all day! So I'm glad there are good Samaritans on the forum! Throw my way anything educational. I am working on converting the rest of your samples to also run inside CrossCore. I got through the first three today. Hopefully given one week's time, I can have all of them up and running on your original page where you posted the pdf. Thanks so much for doing so...The most helpful material is from you and another guy UweS. By the way, I compiled your example above, which I called Fast_in_and_Out word for word and I cannot get it to work...If you can take a look at it, let me know if there is a typo in there. I found an assembly program, also and fixed that one. It had the GPIO 3 data register set to improper location. Easy one the figure out. It was your GPIO toggle sample. Can you run the GPIO faster than 8.33 MHz on the toggle ? That is what I see on my scope pulsing the LED. Without timer or interrupt what are your statistics ? Keep up the good work! Cheers, Mario
All of the assembly code programs I include in the pdf were actually developed as CCES projects, as you show in your posts. As you mention, one of the annoying things about the latest version is that you have to change the file extension to .asm before it will recognize it as an assembly program. Not really a big deal though.
All the code I posted used polling for the FIR and in/out, but UweS kindly supplied the DMA version. Which program is the one that doesn’t work? I will take a look at it.
I worked out why the GPIO only goes at 8.33 MHz, even with the fastest clock. Here is what I say in my lectures:
One of the consequences of systems operating using different clocks is unexpected behaviour due to multiple threads; with a standard monolithic Von Neumann architecture with a clock speed of 400 MHz, pulsing an output high and low in a loop should result in a clock of 400 MHz, i.e.
In fact, with the BF706 it generates a frequency of only 8.333 MHz. However, if we now introduce NOP delays in the loop, the frequency does not fall until there are 48 NOPs (since 8.33 x 48 = 400). The key point here is: the core ALU functions operate at 400 MHz, but not the other systems.
I attach a couple of lecture that I hope you find useful. We also do a full lab course.
Thanks for confirming that...I work on ARM platforms, so my impression there is that some of the PLL's that run the cores are much faster than the clock dividers that run the peripheral busses. On arm we have 50 MHz clock division running GPIO. I wonder what the clock tree looks like for Blackfins. I will get much deeper into it over time. Still studying your long list of assembly exercises for now. In a week or so I want to run an UART interpreter that passes in DSP commands with values for coefficients and virtual controls. I want to write my own algorithms for modulars, CV, GATES and other DSP related stuff. I'm also studying Pirkle's books to get sharper. He uses RackAFX and I want to do something DSP related via commands transmitted from my ARM GPU I wrote. I want to send commands via UART to the Blackfin from the Graphical GUI and rotary encoders, buttons, etc. I'm also learning, since I'm designing synthesizers on ARM and perhaps some wavetable synths and effects on Blackfin is not such a bad idea...Thanks for the literature documents. They are very good and written much better than the new docs that I don't find very appealing. You should write an assembly book with your material. I think it is very useful and educational.
what is the title and availability of mentioned book (chapter 11 and 12) ?
Do you mean the entire book or just chapters 11 and 12?
Book or just chapters 11 and 12?
I mean book.
SHARC architecture is probably too complicated for my students, at first step.
Thank you for fast response,
There are two books. One is “Foundations of Digital Signal Processing: Theory, algorithms and hardware design”, which is available from Amazon. The other book is my course notes (297 pages), which includes content for undergraduate and Masters’ level students.
That sounds like an impressive wish list; kind of thing that I like to do, but unfortunately I have so little time these days, being caught up in management meetings. So dull.
Here is my first real contribution on the BF706 building a simple UART port...Enjoy! Mario
BF706 UART Port
Yeah, do share...We can learn alot from you Patrick! Cheers, Mario
Yes, no problem. Really glad you found it useful.
Sine Wave Generator with Adjustable Frequency port for BF706-EZMINI
I'm new to blackfin and learn about how to implement the FIR filter. Could you please share the FIR code with me?
Code examples attached. These are assembly. If you want C, let me know.
Assembly code here
Thanks for the fast response. Can I have the FIR code in C also please?
On Fri, Aug 3, 2018 at 6:11 AM, PatrickG <
Two simple c programs – one for pass-through, the other for an FIR program. No additional resources required.
Retrieving data ...