Electronics > Beginners

MATLAB Support For Analog Discovery 2

<< < (3/4) > >>

rstofer:

--- Quote from: Crazy_Pete on October 28, 2018, 01:52:54 pm ---Hi Nominal Animal!

I am very interested in writing OScope Software because i think what's out there could be improved.  (I haven't the EE skills to talk about scope design ;-)   And i really like what i hear about the AD2.

However i realise there is a real potential problem.   These AD2 are built around an FPGA from Xilinx.   The folks at Digilent could just change a register or two on the FPGA just to break the cloned software.   Am i too paranoid?

Thanks
Crazy Pete

--- End quote ---

The AD2 is a highly subsidized educational tool and now that MATLAB is on board, there's no reason to make changes in the interface.  There used to be an API library for the original Analog Discovery (I don't know if it covered the AD2) but I can't seem to find it.  The intent was to allow users to create their own projects.

Somebody on this forum (maybe in Projects, maybe in Test Equipment) has created an AD2 app - you might try to search for it.  If they did, they used the API.

I don't see Digilent trying to screw up people's projects.  They have never operated that way.  But they might come out with an AD3 with a new interface and put the AD2 on life support.  That they do fairly often as FPGAs come and go.

Nominal Animal:
It looks like Analog Discovery 2, like the Saleae clones, does not store the firmware on the device, but on the computer host: the host is responsible for loading it every time the device is connected.

The Waveforms package includes the SDK, and the firmware files (in /usr/share/digilent/firmware in x86-64 Linux). The SDK itself is a single C++ library, libdwf.so, which itself depends on the libraries provided by Adept 2. The prevalence of Hungarian notation in the API headers, and using C++ in a low-level hardware abstraction layer library (making language bindings harder than they need be), makes me very suspicious.

I do not immediately see why the libraries are not open source. I don't really see how it could be a negative for Digilent or its parent, National Instruments, considering Digilents mission statement: "Digilent's mission is to make electrical engineering and design technologies understandable and accessible to all, by supplying educators and students with high-value, industry-relevant educational tools and curriculum."

It's just that if one were to go to the effort of creating a fully open source alternative (via reverse-engineering the USB comms), it would be annoying to be slapped by a cease-and-desist order/attempt -- or, for an academic user such as myself, to alienate/annoy Digilent in any significant way.

Crazy_Pete:
>I do not immediately see why the libraries are not open source. I don't really see how it could be a negative for Digilent.

>The prevalence of Hungarian notation in the API headers, and using C++ in a low-level hardware abstraction layer library

Using Hungarian Notation with C++ is another red flag they don't know what they are doing.  C++ is a polymorphic Language that combines strong compile time type checking with loose run time type checking.   Meaning the data types actually change with program flow of control rendering Hungarian Notation not only useless but literally causes it to provide false information.    Using Hungarian Notation basically shows that you don't understand C++ in the first place.   Of course given that the guy [the Digilent Software Engineer] can't write a 1 line shell script to call his own program kinda makes whether or not he understand the nuances of C++ a less than moot point.

Yes i tried to explain all of this to Digilent.    I even offered to do all of the work for them while trying to be as polite as possible.   I went back to my "you are a brain surgeon, i am a cleaning lady, i accept that you are 100x smarter than i am, but still you have to let the cleaning lady clean your surgery or your skills as a brain surgeon are useless as your patients will die of infection."  I  made clear that i only intended to help their sales.   I also made clear that i had no intention of "crossing their wishes" (my exact words.)   I never heard any reply.    (Which is why i mentioned about their breaking the software with a hardware change.)

As far as a cease and desist order, this is California, they are under court order to release violent felons because the prisons are so over crowded.   :-DD  I don't think a "cease and desist order" is going carry much weight.    However there is no point in trying to "help" people who don't want your help.   The Siglent reps AND the Saelig Rep bent over backwards to give as much information and open their Siglent Scopes as much as possible.    Again i really want to thank Ms. Amanda Harris at Saelig.   When she said "I will get the information you requested" i expected to hear from her in a day or two.   She responded within a few hours.   That sort of cooperation is all i can possibly expect and i am very grateful for it.  (Guess why i spent more and bought the Siglent 1104x instead of the AD2.)

Open source means different things to different people.   Even Linux is not completely open source because some of the firmware is binary only.    But the Digilent people acted first as an obstacle and then stopped responding.  It was even funnier when i asked Digilent to delete my account that i didn't want anything more to do with them.  I still continued to receive marketing spam and "You have an item left in your cart" emails from them.  Speaking of Cease and Desist orders, continuing to spam after they have been asked not to is a violation of US Federal Law as well and about as enforceable as a Cease and Desist Order. :-)

I do appreciate your pointing me in the "SCOPI" needs improvement direction, one of the Siglent reps pointed me in that direction as well when i explained to them what i was about.  I find it very reassuring that the Siglent Reps are telling me the same things (both good and bad) about their stuff and the software that interacts with it that you guys are telling me and that i am reading in the other forums.

This is a bit premature since i haven't even received the scope yet, but ANY improvements or suggestions you guys can suggest i am willing to try to make.

Although personally i prefer the way Dr. House puts in on TV   "Yes, i DO think i am higher than you.   However i am not one of those people who think because they have a college degree they know more than anyone else.   If any of you patients in this clinic have any drugs that you think are better and that you are willing to give me, i am willing to take them with an open mind!"    ;)


Thanks
Crazy Pete

Nominal Animal:

--- Quote from: Crazy_Pete on November 02, 2018, 04:04:48 am ---Yes i tried to explain all of this to Digilent.    I even offered to do all of the work for them while trying to be as polite as possible.
--- End quote ---
When Raspberry Pi was originally announced, I went to their forums, and posted that I'd be happy and willing to help with the kernel side and any Linux distribution work, if I could get one of those early ones in my mitts. (I know that stuff.) I was called names, and even banned from their forums.

I wondered what the heck had just happened, but after some digging, realized that Qualcomm hates Linux and GPL with a deep passion. It is in their corporate culture; if there is an option to comply with GPL or violate it, they will choose to violate it unless it is obvious that it will impact severely their business.

Some companies (and organizations) are like that.  They don't want to support free software or open source development, not even if it would make clear business sense.

In cases like AD2, the only thing needed is the details of the protocols on how to upload each firmware (part), and how to communicate with that firmware.  Nothing that cannot be observed from the USB comms -- and even perfectly legal when done for interoperability reasons in many jurisdictions.

Some companies just don't see beyond the current quartal and business plan. They don't see an opportunity even if it hits them in the face.  Others, even "old" companies, do get it, and will be more than happy to provide such protocol information if they have it.  (If they do not, sometimes a clean-room documentation effort under an NDA will work; pure reverse-engineering efforts tend to be just "tolerated/accepted", not "endorsed".)

(This is also why I recommend against using Raspberry Pi's, unless you use the camera option. Some of the other SBCs are much friendlier; I like Olimex and HardKernel, and have recently backed La Frite kickstarter, just in case it really runs on a mainline kernel. The typical issue with SBCs is that they use a forked kernel abortion that is only maintainable by their own team, so that when they move to new hardware, their users will have to eventually switch as well. Using a mainline kernel would fix that. Also, it'd make it really easy to create task-oriented "distros" for specific use cases, say based on ALFS.)


--- Quote from: Crazy_Pete on November 02, 2018, 04:04:48 am ---The Siglent reps AND the Saelig Rep bent over backwards to give as much information and open their Siglent Scopes as much as possible.    Again i really want to thank Ms. Amanda Harris at Saelig.
--- End quote ---
Yup.  It's not that the tool needs to be open just because; it's that if we can properly interface to the tool, we can make the best use out of it, which increases the value.  Siglent and Saelig apparently know this.  :)

In Linux, OpenGL support is easy, and especially for drawing the waveforms (not just one per screen update, but hundreds), there's a lot of low-level work that can make that really nice.  I mean, stuff like FFT is easy using known-good libraries like FFTW; the logic analyzer/protocol decoder support only needs a good data interface with large enough buffers (maybe pulse/space length oriented data format?) to make it really easy for devs to add new protocol support, and so on.  It is the core of the application suite, the low-level stuff, that has to be right, or the suite is crap.  (As I specialize in parallel and distributed molecular dynamics simulator development, I know how to create programs that keep the data flowing, extracting as much out of the CPU cores available as possible.  The trick with GUI programs is that you really need to design the application to be multithreaded from the ground up, so that each thread/CPU core can keep working hard and data flows all the time. Then you get a nice, slick, smooth, robust application.  The GUI toolkits, however, often require a specific threading model, so it all gets pretty complex spaghetti real quick; you need to design it properly from the get go to keep it from becoming an unmaintainable crashy pile of crap.)


--- Quote from: Crazy_Pete on November 02, 2018, 04:04:48 am ---Although personally i prefer the way Dr. House puts in on TV   "Yes, i DO think i am higher than you.
--- End quote ---
When I was younger, I tried the "I don't make a fuss about myself or my skills" approach.  It was how I was raised.  It did not work at all.  I just almost killed myself by trying to bore through hard skulls by concentrated effort alone.

Now, I know I nowadays probably sound like a self-centered asshole, but I'm not that, actually: based on what I've already done, I believe I do have the development skills to back up my claims.  What I do not have, because of still suffering from the post-burnout and recurrent depression, is the ability to handle stress at all, or people who should know better. (Idiots are easy. It's the ones who know better, but prefer to lie or not admit to their mistakes or errors, that grind my guts.  I like this forum a lot, because those seem to be very rare here.)

rstofer:

--- Quote from: Nominal Animal on November 02, 2018, 04:54:02 pm ---
In cases like AD2, the only thing needed is the details of the protocols on how to upload each firmware (part), and how to communicate with that firmware.  Nothing that cannot be observed from the USB comms -- and even perfectly legal when done for interoperability reasons in many jurisdictions.

Some companies just don't see beyond the current quartal and business plan. They don't see an opportunity even if it hits them in the face.  Others, even "old" companies, do get it, and will be more than happy to provide such protocol information if they have it.  (If they do not, sometimes a clean-room documentation effort under an NDA will work; pure reverse-engineering efforts tend to be just "tolerated/accepted", not "endorsed".)

--- End quote ---

Digilent has given us an SDK (I haven't used it) and documentation along with sample programs.  Why should they have to release their source?  I don't have source for Windows 10 and I use it every day.  Same with Waveforms, it works every time I use the AD2.

Less than 2% of desktops use Linux - I wonder why a company would even bother to support it.  More than 27 years later and, still, nobody cares.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

There was an error while thanking
Thanking...
Go to full version
Powered by SMFPacks Advanced Attachments Uploader Mod