Issues:
The update is also posted to my blog: http://www.theembeddedkitchen.net/gsoc2014/beaglelogic-week-1-building-the-pru-firmware/
Kumar Abhishek
Issues:
Issues:
Cheers
Abhishek
Link to the firmware:PRU Firmware directory (GitHub)
Link to the kernel driver: BeagleLogic kernel module
In the coming week, I will be implementing sigrok bindings for BeagleLogic. There's also a lightweight "libbeaglelogic" (essentially a syscall wrapper in userspace) for '/dev/beaglelogic' in the queue. As of now I am preparing the patch for Pantelis' pru_rproc driver which enables the BeagleLogic kernel driver to operate the PRUs and receive IRQs from them, the beaglelogic module is independent and communicates with the pru_rproc driver with the patch code.
I will publish the READMEs very soon
"The maximum speed on the input pins [P8_27 to P8_30; P8_39 to P8_46] depends upon the signal integrity of the signals to the Bone. Sampling is possible with the software at 100 MHz, but it will only be as good as the quality of signals at the inputs"
In Progress
Issues
On of the patches in the patchset [on pru_rproc.c] can be handed over Deepak to add BeagleLogic hooks into the BotSpeak driver [which is based on pru_rproc.c], and then the BeagleLogic module [beaglelogic.ko] can be run along with it, with the correct firmware and pinmux settings being loaded into it.
Expect sigrok bindings to be ready and sent upstream by this week-end.
Once this is done, I will begin work on the HTML5 frontend and Node.JS backend of the web interface to BeagleLogic. The backend may also be a combination of C code and Node.JS code, specifications of which will be available after work on the sigrok bindings is stable.
Regards
Hi everyone,
I write this mail to announce the specifications of the core of BeagleLogic.
In my presentation I had highlighted that the sample rate would be "best effort". Here's what has been achieved from implementing suitable kernel module and PRU firmware now:
- Sample Rates: (100 / N) MHz : N = 1, 2, .... [100MHz(highest supported, would need proper signal conditioning) & 100kHz (lowest supported)]
- Sample Formats: 8-bit and 16-bit uncompressed per sample [maximum 12/14 bits supported by hardware (eMMC/uSD)]
- Sample Depth: As much RAM is available on the system. I have successfully filled buffers worth 320 MB on the BeagleBone Black (but possible to fill more), leaving sufficient space for processing applications to run
- Streaming support (experimental) at lower sample rates [ < 50 MHz ], assuming data can be moved out fast enough out of the BeagleBone Black. RAM bandwidth is good enough for streaming (buffer copy speeds in RAM ~200 MHz) [At 50 MHz & 100 MHz it is recommended to run in pre-allocated large buffers]. The ARM processor should be capable of compressing the stream in real time using a fast compression algorithm like LZO or LZ4, I am yet to do more tests with this.
- Absence of Hardware Triggers [not implemented yet]. This is traded for large buffer depth. 320 MB = 3 seconds worth data @100 MHz, 8bits, which should be enough to analyze and use software triggers on the captured data
- [software triggers are being developed in sigrok]
- PRU firmware can be modified for trigger support, e.g. capturing a live video stream in which the VSYNC signal can act as the trigger.
Link to the firmware:PRU Firmware directory (GitHub)
Link to the kernel driver: BeagleLogic kernel module
In the coming week, I will be implementing sigrok bindings for BeagleLogic. There's also a lightweight "libbeaglelogic" (essentially a syscall wrapper in userspace) for '/dev/beaglelogic' in the queue. As of now I am preparing the patch for Pantelis' pru_rproc driver which enables the BeagleLogic kernel driver to operate the PRUs and receive IRQs from them, the beaglelogic module is independent and communicates with the pru_rproc driver with the patch code.
I will publish the READMEs very soon
--
Issues:
TODO:
BeagleLogic Hangout
A Hangout is scheduled on Thursday, 4:00am WIB [2 pm Pacific Time, 5pm Eastern, 11:00pm CEST] with Bert Vermuelen from sigrok having agreed to join in the discussions with me, Jason and Matt.
The blog post would be live in a few moments from now at BeagleLogic and sigrok: The beginning
Update 7 [Week 6]
Achieved:
- Working libsigrok bindings for BeagleLogic. See the screenshot above.
- Non-blocking I/O bug fixed in the kernel driver
- mmap() functionality validated using a test application which compared the buffer read back using read() and the mmap()'ed buffer.
- Test userspace application that tests both blocking and non-blocking I/O functionality
- I also tested the protocol decoder functionality within libsigrokdecode by firing up my self-built audio playback board and decoding a 6 second captured wave audio file directly from the BBB
Issues:
- Speed. sigrok-cli is *extremely slow* on the BeagleBone Black. As can be seen in the screenshot, it took me more than 30 minutes [1600 seconds] to save a 256 MB logic dump.
- Decoding a wave file took 10 minutes to process 64MB of dump into a 6sec wave file on the BBB. These values are quite low. Improvement is expected in future versions of sigrok.
- This was quite surprising to me, considering I've captured 1 GB of a logic dump while compressing it with LZO using just dd if=/dev/beaglelogic | lzop.
TODO:
- Build a sigrok-based C application to exchange data with a Node.JS backend via pipes / Explore node-ffi [High priority]
- Add software triggers supported by libsigrok to the BeagleLogic driver [not urgent]
- Send patch to the sigrok-list.
BeagleLogic Hangout
A Hangout is scheduled on Thursday, 4:00am WIB [2 pm Pacific Time, 5pm Eastern, 11:00pm CEST] with Bert Vermuelen from sigrok having agreed to join in the discussions with me, Jason and Matt.
The blog post would be live in a few moments from now at BeagleLogic and sigrok: The beginning
--
Issues
TODO
I encourage the community to try out sigrok-cli and the kernel drivers with the latest bone60 kernel.
Regards
This is an awesome project!One thing that would be super duper useful would to add an input buffer with variable logic thresholds; on my current logic analyzer I'm often switching between projects running at 1v8, 3v3 and 5v, and it's essential to have programmable levels.It appears quite a simple interface cape would do the trick, e.g.:SN74LVC16T245 - 16 channel buffer with separate in/out power rails, runs from 1.6v to 5v (so probably good for even 1v2 logic!)AD5320 rail-to-rail DAC, powered off 5V, supplying one power rail to the buffer. The other buffer power rail would be 3v3 for the beagle side.Should work up to 100Mhz ok (buffer timing varies a little with the voltage chosen)
Conveniently this could work bidirectionally so as a programmable-output-voltage 16-bit bus, although one would have to be careful not to draw too much power on the output pins (as it's powered by the DAC).For a couple of bucks more one could have a separate SN74LVC8T245 for output, (perhaps with a two-channel DAC) and have simultaneous in+out at programmable voltage levels, e.g. for a chip tester or whatever; various bells+whistles are imaginable.
Great work, will be following this project.
Update 8 [Week 7]
Achieved:
- Completed sigrok bindings for BeagleLogic, with software triggering capabilities too.
- Modified the first patchset based on reviews from the sigrok developers and sent another patchset addressing a few points raised. It is in the queue for a spin by the sigrok developers.
- Release v1.1 patchset (non-blocking I/O) to the BeagleBoard kernel [Merged]
- Kernels bone60 onwards, and the next system image should bundle BeagleLogic kernel components out-of-the-box.
- ABI freeze [except for bugfixes] for the kernel-userspace part until BeagleLogic is refactored for mainline.
- Building a framework for the web application using Express. These are the libraries that are confirmed so far and are in queue for benchmarking:
Issues
- Benchmarking these libraries to evaluate the performance and suitability for real-time over web-browser. I am not able to bring in numbers today as I was busy with some other work, but will provide very soon.
- Also to evaluate suitability of WaveDrom as a rendering agent. The first version of the web app will allow binary files to be downloaded over to the desktop directly and can be processed with sigrok on the desktop
- Profiling sigrok-cli for the slowness is deferred as we will be dealing with short capture sizes at first.
TODO
- Build first iteration of a non-interactive webapp
- Bring the mock-up as posted in my proposal live (with a UI library) for design feedback.
I encourage the community to try out sigrok-cli and the kernel drivers with the latest bone60 kernel.
Regards
Issues: I had to travel back to India to my university as vacations had ended. There were also logistical issues due to relocation; work was disturbed for almost 3-4 days. So there couldn't be a status update last week.
These non-technical issues have been settled and I have been catching up over the past few days; I expect to be able to show a screenshot in a day or two, and push the initial web interface structure on GitHub very soon.
TODO:
Regards
P.S. BeagleLogic has been featured on HackADay . Thank You Jason! :)
I invite everyone to test the web interface and rate its usability (as-is in its current form) on a scale of 1 to 5 and request feedback on the UI and features.
Issues:
Possible Solutions:
Next Steps:
Regards
Here's an example parsed and rendered logic dump.
Issues:
TODO:
For updates on the project in the future, keep visiting http://beaglelogic.net .
It has been a great journey so far, and I would be very happy to see BeagleLogic live its purpose of use as a learning tool to understand logic protocols, and a powerful yet-cost effective alternative to the plethora of inexpensive LAs and hope it will serve the community the fullest.
Cheers!
Abhishek
Issues:
I will make a last pass on the first two issues by this Friday. The resulting package will be submitted (along with the systemd files) for inclusion in the system image this weekend.
The final report (video) will be uploaded this weekend.