ffp | iCE40 FPGA , SPI flash , and CMSIS-DAP SWD programmer

 by   adamgreig Rust Version: v1.3.2 License: Non-SPDX

kandi X-RAY | ffp Summary

kandi X-RAY | ffp Summary

ffp is a Rust library typically used in Internet of Things (IoT) applications. ffp has no bugs, it has no vulnerabilities and it has low support. However ffp has a Non-SPDX License. You can download it from GitHub.

FFP is a dead-simple USB to bidirectional SPI bridge for programming iCE40 FPGAs and SPI flashes. The hardware is an STM32F042 and not much else. Firmware and host software is written in Rust. The firmware additionally supports SWD via the CMSIS-DAP v1 and v2 protocols, so many debuggers such as probe-rs, OpenOCD, and pyOCD are able to use an FFP to debug and program Cortex-M and other microcontrollers. See software/ for the host-side software, firmware/ for the embedded device firmware, and hardware/ for the hardware design files.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              ffp has a low active ecosystem.
              It has 48 star(s) with 5 fork(s). There are 11 watchers for this library.
              OutlinedDot
              It had no major release in the last 12 months.
              There are 7 open issues and 10 have been closed. On average issues are closed in 60 days. There are no pull requests.
              It has a neutral sentiment in the developer community.
              The latest version of ffp is v1.3.2

            kandi-Quality Quality

              ffp has no bugs reported.

            kandi-Security Security

              ffp has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.

            kandi-License License

              ffp has a Non-SPDX License.
              Non-SPDX licenses can be open source with a non SPDX compliant license, or non open source licenses, and you need to review them closely before use.

            kandi-Reuse Reuse

              ffp releases are available to install and integrate.
              Installation instructions are not available. Examples and code snippets are available.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of ffp
            Get all kandi verified functions for this library.

            ffp Key Features

            No Key Features are available at this moment for ffp.

            ffp Examples and Code Snippets

            FFP: Flash/FPGA Programmer,Pinout
            Rustdot img1Lines of Code : 8dot img1License : Non-SPDX (NOASSERTION)
            copy iconCopy
                      ______
                3v3 --|1  2|-- FLASH DI / FPGA DO / SWDIO
                GND --|3  4|-- CLK / SWCLK
                GND --|5  6|-- CS / SWO
                    x-|7  8|-- FPGA nRST
                GND --|9 10|-- FLASH DO / FPGA DI / nRESET
                      ------
            
              

            Community Discussions

            QUESTION

            QNAN passed into C standard library functions (ex. llrintf): not clear whether FP exceptions are raised or not
            Asked 2021-Mar-31 at 18:30

            The macro NAN from math.h is quiet NAN:

            ISO/IEC 9899:2011 (E) (emphasis added):

            The macro

            NAN

            is defined if and only if the implementation supports quiet NaNs for the float type. It expands to a constant expression of type float representing a quiet NaN.

            Quiet NaNs usually do not lead to raising of FP exceptions. Examples:

            1. ISO/IEC 9899:2011 (E) (emphasis added):

            5.2.4.2.2 Characteristics of floating types

            3    A quiet NaN propagates through almost every arithmetic operation without raising a floating-point exception; a signaling NaN generally raises a floating-point exception when occurring as an arithmetic operand.

            1. IEEE 754-2008 (emphasis added):

            5.11 Details of comparison predicates Programs that explicitly take account of the possibility of quiet NaN operands may use the unordered-quiet predicates in Table 5.3 which do not signal such an invalid operation exception.

            However:

            1. llrintf() is neither arithmetic operation, nor unordered-quiet predicates in Table 5.3. Hence, 5.2.4.2.2.3 and 5.11 are not applicable.
            2. 7.12.9.5 The lrint and llrint functions (for example) says nothing about whether FP exceptions are raised or not in case if input is quiet NaN.

            Preliminary conclusion: Because of the general practice "quiet NaN does not lead to raising FP exceptions" it can be concluded that the lrint and llrint functions should not lead to raising FP exceptions if input is quiet NaN.

            Practice:

            Code (t125.c):

            ...

            ANSWER

            Answered 2021-Mar-30 at 16:13

            The OP was under impression that term conversion implies only implicit conversion and explicit conversion (cast operation) (see C11 6.3 Conversions). Meaning that OP was under impression that term function is not a conversion.

            However, C11 F.3 Operators and functions (emphasis added) explicitly states that:

            The lrint and llrint functions in provide the IEC 60559 conversions.

            Hence, yes, C11 F.4 Floating to integer conversion (emphasis added) answers the question:

            F.4 Floating to integer conversion

            1    ... Otherwise, if the floating value is infinite or NaN or if the integral part of the floating value exceeds the range of the integer type, then the ‘‘invalid’’ floating-point exception is raised and the resulting value is unspecified. ...

            Source https://stackoverflow.com/questions/66816612

            QUESTION

            floating point rounding giving different results for 80-bit register and 64-bit double: ill-formed code or gcc/clang bug?
            Asked 2020-Dec-04 at 21:39

            The code given below shows different results, depending on -O or -fno-inline flags. Same (strange) results for g++ 10.1 and 10.2 and clang++ 10 on x86. Is this because the code is ill-formed or is this a genuine bug?

            The "invalid" flag in Nakshatra constructor should be set whenever it's nakshatra (double) field is >= 27.0. But, when initialized via Nakshatra(Nirayana_Longitude{360.0}), the flag is not set, even though the the value after scaling becomes exactly 27.0. I assume that the reason is that the argument of 360.0 after scaling becomes 26.9999999999999990008 (raw 0x4003d7fffffffffffdc0) in 80-bit internal register, which is < 27.0, but, being stored as 64-bit double, becomes 27.0. Still, this behavior looks weird: the same nakshatra seems to be simultaneously <27.0 and >= 27.0. Is it the way it's supposed to be?

            Is it the expected behaviour because my code contains UB or otherwise ill-formed? Or is it a compiler bug?

            Minimal code to reproduce (two .cpp files + one header, could not reproduce with less):

            main.cpp:

            ...

            ANSWER

            Answered 2020-Dec-04 at 21:39

            Without -ffloat-store, GCC targeting x87 does violate the standard: it keeps values un-rounded even across statements. (-mfpmath=387 is the default for -m32). Assignment like double x = y; is supposed to round to actual double in ISO C++, and probably also passing a function arg.

            So I think your code is safe for ISO C++ rules, even with the FLT_EVAL_METHOD == 2 that GCC claims to be doing. (https://en.cppreference.com/w/cpp/types/climits/FLT_EVAL_METHOD)

            See also https://randomascii.wordpress.com/2012/03/21/intermediate-floating-point-precision/ for more about the real-world issues, with actual compilers for x86.

            https://gcc.gnu.org/wiki/x87note doesn't really mention the difference between when GCC rounds vs. when ISO C++ requires rounding, just describes GCC's actual behaviour.

            Source https://stackoverflow.com/questions/65150649

            QUESTION

            darknet make error : gcc: command not found, Makefile: recipe for target failed
            Asked 2020-Nov-30 at 18:34

            My intention is to do preparation of sound wave file, arrange train process, and test process via sound.c. ran into error during compiling darknet. need your help!

            make: gcc: command not found Makefile: 175: recipe for target 'obj/sound.o' failed make: *** [obj/sound.o] Error 127 UBUNTU LTS 18.04 CUDA 11.1

            @wbcalex-desktop:~$ sudo apt install gcc [sudo] password for wbcalex: Reading package lists... Done Building dependency tree
            Reading state information... Done gcc is already the newest version (4:7.4.0-1ubuntu2.3). The following package was automatically installed and is no longer required: linux-hwe-5.4-headers-5.4.0-47 Use 'sudo apt autoremove' to remove it. 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. desktop:~$ cd darknet_tmp desktop:~/darknet_tmp$ make gcc -Iinclude/ -I3rdparty/stb/include -DGPU -I/usr/local/cuda/include/ -DCUDNN -Wall -Wfatal-errors -Wno-unused-result -Wno-unknown-pragmas -fPIC -Ofast -DGPU -DCUDNN -I/usr/local/cudnn/include -fPIC -c ./src/sound.c -o obj/sound.o make: gcc: Command not found Makefile:175: recipe for target 'obj/sound.o' failed make: *** [obj/sound.o] Error 127

            ...

            ANSWER

            Answered 2020-Nov-30 at 18:34

            PATH variable isn't updated correctly, $PATH is not makefile syntax. Fix:

            Source https://stackoverflow.com/questions/65076842

            QUESTION

            Build a list with a while loop using DataFrame
            Asked 2020-Nov-30 at 16:39

            Say we're Amazon, and we receive a customer order in the form of this nested dict down here 👇

            ...

            ANSWER

            Answered 2020-Nov-30 at 16:39

            Not sure why you use pandas - you can do this using simple python with no imports whatsoever:

            Source https://stackoverflow.com/questions/65076953

            QUESTION

            Writing 'Image.Image.paste()' to new file
            Asked 2020-Nov-16 at 19:12

            I need to paste first picture on second and save new picture as new file. How I can do it? My not-working code in the bottom.

            ...

            ANSWER

            Answered 2020-Nov-16 at 19:12

            I didn't see anything wrong but I think you can save the image without using the open method. Also, you can paste on your mat image and save it as another image with save

            Source https://stackoverflow.com/questions/64864028

            QUESTION

            How to write fast c++ lazy evaluation code in Fastor or Xtensor?
            Asked 2020-Oct-11 at 10:40

            I am a newbie in c++, and heard that libraries like eigen, blaze, Fastor and Xtensor with lazy-evaluation and simd are fast for vectorized operation.

            I measured the time collapsed in some doing basic numeric operation by the following function:

            (Fastor)

            ...

            ANSWER

            Answered 2020-Oct-11 at 10:40

            The reason the Numpy implementation is much faster is that it does not compute the same thing as the two others.

            Indeed, the python version does not read z in the expression np.sin(x) * np.cos(x). As a result, the Numba JIT is clever enough to execute the loop only once justifying a factor of 100 between Fastor and Numba. You can check that by replacing range(100) by range(10000000000) and observing the same timings.

            Finally, XTensor is faster than Fastor in this benchmark as it seems to use its own fast SIMD implementation of exp/sin/cos while Fastor seems to use a scalar implementation from libm justifying the factor of 2 between XTensor and Fastor.

            Answer to the update:

            Fastor/Xtensor performs really bad in exp, sin, cos, which was surprising.

            No. We cannot conclude that from the benchmark. What you are comparing is the ability of compilers to optimize your code. In this case, Numba is better than plain C++ compilers as it deals with a high-level SIMD-aware code while C++ compilers have to deals with a huge low-level template-based code coming from the Fastor/Xtensor libraries. Theoretically, I think that it should be possible for a C++ compiler to apply the same kind of high-level optimization than Numba, but it is just harder. Moreover, note that Numpy tends to create/allocate temporary arrays while Fastor/Xtensor should not.

            In practice, Numba is faster because u is a constant and so is exp(u), sin(u) and cos(u). Thus, Numba precompute the expression (computed only once) and still perform the sum in the loop. The following code give the same timing:

            Source https://stackoverflow.com/questions/64293139

            QUESTION

            How can I change my code to print only x amount of graphs?
            Asked 2020-Sep-08 at 06:58

            Below is my code:

            ...

            ANSWER

            Answered 2020-Jul-20 at 11:44

            you have to change these 3 lines.

            Source https://stackoverflow.com/questions/62994080

            QUESTION

            How can i create an input for choosing different files to access?
            Asked 2020-Aug-11 at 03:53

            I am quite new to python so please bear with me.

            Currently, this is my code:

            ...

            ANSWER

            Answered 2020-Aug-11 at 03:53

            Why not use an if-statement at the beginning? Try this:

            instead of:

            Source https://stackoverflow.com/questions/63351159

            QUESTION

            What does ValueError: x, y, and format string must not be None mean?
            Asked 2020-Jul-27 at 13:46

            Here is my code so far:

            ...

            ANSWER

            Answered 2020-Jul-27 at 13:46

            QUESTION

            How to measure time it takes for the graph to print
            Asked 2020-Jul-27 at 06:46

            Please bear with me as i am quite new to python.

            Currently, this is my code:

            ...

            ANSWER

            Answered 2020-Jul-27 at 06:46

            You can use plt.show(block=False) which makes show return immediately after the window is shown.

            Source https://stackoverflow.com/questions/63108473

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install ffp

            You can download it from GitHub.
            Rust is installed and managed by the rustup tool. Rust has a 6-week rapid release process and supports a great number of platforms, so there are many builds of Rust available at any time. Please refer rust-lang.org for more information.

            Support

            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/adamgreig/ffp.git

          • CLI

            gh repo clone adamgreig/ffp

          • sshUrl

            git@github.com:adamgreig/ffp.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link