Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
Collapse
Brand Logo

ModalAI Forum

Alexandre PabouctsidisA

Alexandre Pabouctsidis

@Alexandre Pabouctsidis
Unfollow Follow
About
Posts
2
Topics
1
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Baremetal peripheral interaction via the SDSP
    Alexandre PabouctsidisA Alexandre Pabouctsidis

    Thanks for responding. Is this proprietary code the Qualcom Hexagon SDK?

    I'm already building the DSP code with QuRT, but it's unclear how to do the system calls in order to interact with the devices.

    For example, i've tried this to blink a LED:

    int fd; 
    fd = open("/sys/class/gpio/gpio1182/value", O_WRONLY);
    if (fd == -1) {
        FARF(ALWAYS,"Unable to open /sys/class/gpio/gpio1182/value");
        qurt_thread_exit(QURT_EOK);
    }
    
    // Toggle LED 50 ms on, 50ms off, 100 times (10 seconds)
    
    for (int i = 0; i < 100; i++) {
        if (write(fd, "1", 1) != 1) {
            FARF(ALWAYS,"Error writing to /sys/class/gpio/gpio1182/value");
            qurt_thread_exit(QURT_EOK);
        }
        qurt_timer_sleep(50000);
    
        if (write(fd, "0", 1) != 1) {
            FARF(ALWAYS,"Error writing to /sys/class/gpio/gpio1182/value");
            qurt_thread_exit(QURT_EOK);
        }
        qurt_timer_sleep(50000);
    }
    
    close(fd);
    

    It builds and runs but nothing happens.

    as for the SPI, the hexagon system libraries don't contain headers for <sys/ioctrl.h>. I noticed in the PX4, the headers are defined in the DSPAL, and the implementation is in dspal_imp.c (https://gitlab.com/voxl-public/flight-core-px4/px4-firmware-ci/-/blob/v1.4.20-modalai-rb5-flight-beta/platforms/qurt/src/px4/common/dspal_impl.c), but are just stubs?

    Software Development

  • Baremetal peripheral interaction via the SDSP
    Alexandre PabouctsidisA Alexandre Pabouctsidis

    Hello,

    In order to get a better grasp of the voxl2 module, i'm trying to develop a very basic test code from scratch, starting from the qualcom demo code + inspiration from the PX4 cmake, etc.

    I've reached the stage where I can build the ARM app + DSP lib, load it on the DSP and run it.

    I'm now trying to interact with the SPI+USART+GPIO(?) peripherals. I've spent countless hours digging through the px4 code base, dspal, etc. but I'm having trouble finding the absolute low level code which actually interacts with the peripheral/HW.

    Could someone show me where in the code base is the actual implementation of the SPI or USART transfer (and not just one of the many, many hardware abstractions 😛 )

    After following the chain, the lowest i got is that the spi/usart functions are passed to the _muorb__slpi module, which are initialized through "px4muorb_orb_initialize", which should be called by the apps processor? but i can't find any instance of where it's done. etc.

    The first goal is to read the whoami register of the icm, without any of the HALs (dspal, etc.)

    Thanks for the help!
    Alex

    Software Development
  • Login

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups