Skip to content

Is it possible to run on edge device like STM32 #408

@kronee0516

Description

@kronee0516

Hi,

I saw an article in China said stm32 can run on STM32
but it didn't explain in details

is this possible?
which files should i move to compile?

i tried on another edge device but some of the code have defined for some kind of platform which do not include edge device like platform
and cause the error

like in this

void
ptmr_start(ptmr_t * tm)
{
#if (! defined(_WIN32)) || defined(GNUWINCE) || defined(__SYMBIAN32__)
    struct timeval e_start;     /* Elapsed time */

#if (! defined(_HPUX_SOURCE))  && (! defined(__SYMBIAN32__))
    struct rusage start;        /* CPU time */

the errors

./src/asr/src/util/profile.c: In function 'ptmr_start':
./src/asr/src/util/profile.c:186:19: error: storage size of 'start' isn't known
  186 |     struct rusage start;        /* CPU time */
      |                   ^~~~~
./src/asr/src/util/profile.c:189:5: warning: implicit declaration of function 'getrusage' [-Wimplicit-function-declaration]
  189 |     getrusage(RUSAGE_SELF, &start);
      |     ^~~~~~~~~
./src/asr/src/util/profile.c:189:15: error: 'RUSAGE_SELF' undeclared (first use in this function)
  189 |     getrusage(RUSAGE_SELF, &start);
      |               ^~~~~~~~~~~
./src/asr/src/util/profile.c:189:15: note: each undeclared identifier is reported only once for each function it appears in
./src/asr/src/util/profile.c:193:5: warning: implicit declaration of function 'gettimeofday' [-Wimplicit-function-declaration]
  193 |     gettimeofday(&e_start, 0);
      |     ^~~~~~~~~~~~

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions