Code Monkey home page Code Monkey logo

rak811-tracker's Introduction

Acknowledgements:

This code is possible thanks to the previous work done by @Ebiroll to program the RAK811 from Platformio. You can find his work here: https://github.com/Ebiroll/RAK811_BreakBoard

This code has been adapted to US915 band by @RussNelson https://github.com/RussNelson

This work is carried out within the project http://openmaker.eu/2018/02/05/fenps/ financed by the EU's HORIZON 2020 programme.

You can follow the instructions in the wiki page: https://github.com/jcaridadhdez/RAK811-tracker/wiki

rak811-tracker's People

Contributors

jcaridadhdez avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

rak811-tracker's Issues

KeyError: "Invalid board option 'upload.protocol'"

When following wiki instructions under Ubuntu 19.10, I got this error in Platform.io, which prevent any build.

nicolas@morgan:~/sources/RAK811-tracker$ pio run
Warning! Ignore unknown configuration option `lib_dir` in section [env:rak811]
Warning! Ignore unknown configuration option `src_dir` in section [env:rak811]
Processing rak811 (platform: ststm32; board: rak811; framework: cmsis)
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Error: Traceback (most recent call last):
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/platformio/__main__.py", line 102, in main
    cli()  # pylint: disable=no-value-for-parameter
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/click/core.py", line 764, in __call__
    return self.main(*args, **kwargs)
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/click/core.py", line 717, in main
    rv = self.invoke(ctx)
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/platformio/commands/__init__.py", line 44, in invoke
    return super(PlatformioCLI, self).invoke(ctx)
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/click/core.py", line 1137, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/click/core.py", line 956, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/click/core.py", line 555, in invoke
    return callback(*args, **kwargs)
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/click/decorators.py", line 17, in new_func
    return f(get_current_context(), *args, **kwargs)
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/platformio/commands/run/command.py", line 138, in cli
    is_test_running,
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/platformio/commands/run/command.py", line 170, in process_env
    result = {"env": name, "duration": time(), "succeeded": ep.process()}
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/platformio/commands/run/processor.py", line 80, in process
    result = p.run(build_vars, build_targets, self.silent, self.verbose, self.jobs)
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/platformio/managers/platform.py", line 383, in run
    self.configure_default_packages(options, targets)
  File "/home/nicolas/.platformio/platforms/ststm32/platform.py", line 34, in configure_default_packages
    "board")).get("upload.protocol") or ""
  File "/home/nicolas/.platformio/penv/lib/python3.7/site-packages/platformio/managers/platform.py", line 731, in get
    raise KeyError("Invalid board option '%s'" % path)
KeyError: "Invalid board option 'upload.protocol'"

An idea how to fix this? I'm not used to Platform.io, so that might be trivial...

Function UartMcuPutBuffer missing

UartMcuPutBuffer function is missing from the code, it is defined in uart_board.h but is not present in the .c file, thus some things can not be done, like writing to GPS

Code should be here:

uint8_t UartMcuPutChar( Uart_t *obj, uint8_t data )

I have tried adding the missing function, however I mange to hang the board by doing so:

uint8_t UartMcuPutBuffer( Uart_t *obj, uint8_t *buffer, uint16_t size )
{
    if( IsFifoFull( &obj->FifoTx ) == false )
    {
                BoardDisableIrq( );
        for(uint8_t i=0;i<size;i++){
            FifoPush( &obj->FifoTx, buffer[i]);
        }
                BoardEnableIrq( );
        // Trig UART Tx interrupt to start sending the FIFO contents.
        __HAL_UART_ENABLE_IT( &UartContext[UART_1].UartHandle, USART_IT_TXE );
        return 0; // OK
    }

    return 1; // Busy
}

HDOP is an int, not a double

In gps.c:

int8_t GpsGetLatestGpsHorizontalDilution (void)
{
    BoardDisableIrq( );
    if( HasFix == true )
    {    
        Hdop = atoi( NmeaGpsData.NmeaHorizontalDilution );
    }
    else
    {
        Hdop = 0xFFFF;
    }
    BoardEnableIrq( );

    return Hdop;

}

We should change this to
double GpsGetLatestGpsHorizontalDilution (void)
and parse a float, not an int
Hdop = atof( NmeaGpsData.NmeaHorizontalDilution );

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.