Giter VIP home page Giter VIP logo

project_generator_definitions's People

Contributors

0xc0170 avatar adbridge avatar bcc6 avatar bcostm avatar c1728p9 avatar ccli8 avatar cristianguemes avatar dotnfc avatar elektor-labs avatar findlayfeng avatar fvincenzo avatar heezes avatar iclite avatar jamike avatar jaustin avatar kgills avatar mbrossard avatar mikexiaoshi avatar mmahadevan108 avatar ohagendorf avatar patater avatar sg- avatar stevew817 avatar svastm avatar toyowata avatar ychsu-tf avatar ytsuboi avatar zgoda avatar zjli-2019 avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

project_generator_definitions's Issues

Git remote - set to this repo in case old remote was used

As we changed pdef remote (from my repo to this one), we haven't updated remote. Therefore we should a check that remote origin is set to this repository in the default location, if not, set it there.

I am currently keeping my fork up to the date ๐Ÿ˜†

cc @sg-

Move from Travis to elsewhere

Their recent plans made it unavailable for open source projects like this one to run some free jobs. The credit system is one time thing that needs to be requested and takes some time to be granted. Not ideal, so I'll look at how to migrate it elsewhere where we can run our simple checks.

Loader yaml: fix load function

Already fixed in project_generator, same fix needed here, line 28 in the definitions script file

I'll send a fix within a day

uVision - device - legacy or new device packs

The current pgen version (v0.6) uses legacy devices (as named in uvision 5). Which is fine as it will work after downloading legacy support to uVision 5 (http://www2.keil.com/mdk5/legacy/).

We might find soon enough a device which is only supported via device packs. I'll find out what it needs to be compatible with device packs, for us to switch to use a new device packs.

Pypi: add readme

At least basic description what this module does, so it's not empty on pypi

python 3 compatibility

Let's move to py3 by default.

I tried quickly today to scrape definitions with uvisions and there are some easy to fix python errors like

project_generator_definitions\tools.py", line 67, in get_mcu_definition
    uvproj_dic = xmltodict.parse(file(project_file), dict_constructor=dict)
NameError: name 'file' is not defined

FPU option not set in exported IAR project files for several platforms

I'm using:
IAR EWARM 7.40.7
mbed-os-5.1.0-rc4
project-generator (0.9.8)
project-generator-definitions (0.2.27)

Exporting to the following targets and trying to build in IAR IDE results in an error that the device doesn't have VFP registers. The project files need to have the FPU option set to VFPv4 single precision.
NUCLEO_F411RE
NUCLEO_F401RE
DISCO_F429ZI
FRDM-K64F
FRDM-K22F

Create tags

Hi,

I'm working to package this up for Arch Linux and am curious if you can create tags to the releases so I can build the packages based on tags.

Thanks!

uvision4 template - uvision - traceback

When progendef create to be used on uvision4_nucleo_f746zg.uvproj.tmpl, this is the traceback

progendef create -f uvision4_nucleo_f746zg.uvproj.tmpl -m
 -t uvision5
Traceback (most recent call last):
  File "C:\Python27\Scripts\progendef-script.py", line 9, in <module>
    load_entry_point('project-generator-definitions', 'console_scripts', 'progendef')()
  File "c:\code\git_repo\github\project_generator_definitions\project_generator_definitions\main.py", line 54, in main
    return args.func(args)
  File "c:\code\git_repo\github\project_generator_definitions\project_generator_definitions\create_command.py", line 23
 in run
    if ProGenDef(args.tool).mcu_create(args.mcu, args.file) == False:
  File "c:\code\git_repo\github\project_generator_definitions\project_generator_definitions\definitions.py", line 152,
n mcu_create
    data = self.definitions.get_mcu_definition(template_file)
  File "c:\code\git_repo\github\project_generator_definitions\project_generator_definitions\tools.py", line 74, in get_
cu_definition
    'DeviceId' : [int(uvproj_dic['Project']['Targets']['Target']['TargetOption']['TargetCommonOption']['DeviceId'])],
TypeError: int() argument must be a string or a number, not 'NoneType'

with uvision4, it fails as well but with INFO.

Tests to verify mcu and targets yaml files

We should add simple CI tests to at least verify syntax in the yaml files.

Core should be valid, target should have mcu, and mcu should be valid and present. All tool specific should be there. For example this can be normal mistake for user adding a new target:

    iar:
    OGChipSelectEditMenu:
      state:
      - STM32F401xE ST STM32F401xE
    OGCoreOrChip:
      state:
      - 1

The tests would be run by Travis, so each PR would be tested before it gets landed

Class MCU

We provide API to get target definition, but not mcu.

Target is useful for a user writing own yaml files, but for other frameworks, mcu might be better option. For instance, there's a framework which calls its target freedom-k64f, this one has an mcu on it. It could use frdm-k64f progen target, or rather mcu MK64Fxxxxx and get mcu definition right away.

uvision - on chip memories fields

We should get ROM/RAM details which are known by uvision. They are under <OnChipMemories>

They are not active if you use scatter file.

uvision4 vs uvision 5 - new packs mcu

We should distinguish between legacy mcu and the new mcu. For instance, mcu k64f could define uvision (as it is now) for uvision4 - legacy, uvision5 would be using the new packs mcu (there should be new fields in the mcu).

This should be non-breaking change.

Fix uvision settings

Related to some latest cleaning for v0.6, we should define uvision syntax better. TargetOption is not exactly what's inside xml file.

For example for flash driver dll - Targets-Target-targetOption-TargetCommonOption-Device

  <Targets>
    <Target>
      <TargetName>{{name}}</TargetName>
      <ToolsetNumber>0x4</ToolsetNumber>
      <ToolsetName>ARM-ADS</ToolsetName>
      <TargetOption>
        <TargetCommonOption>
        <Device>{{uvision_settings['Device']}}</Device>
          <Vendor>{{uvision_settings['Vendor']}}</Vendor>
          <Cpu>{{uvision_settings['Cpu']}}</Cpu>
          <FlashUtilSpec></FlashUtilSpec>
          <StartupFile></StartupFile>
          <FlashDriverDll></FlashDriverDll>

Core - IAR does not accept core only

We should provide the same as for uvision, for only core (no device). This currently results in the traceback.

Our cores have support only for uvision, thus we have not seen the error.

Targets yaml file replacement

Each target needs a separate yaml file where is just a path to mcu yaml file. This could be simplified with a dictionary (or a class if there is any API there):

PROGENDEF_TARGETS = {
    'frdm-k64f': 'mcu/freescale/mk64f.yaml',
    'my-new-platofrm': 'mcu/freescale/mk64f.yaml',
    'mbed-lpc1768': 'mcu/nxp/lpc1768.yaml',
}

Docs - tools version of definitions

We should state what versions we use and our parsers supports. For instance the latest master contains fixes for IAR >7.40.2 that introduced FPU2 settings for MCU.

uvision parser - check for uv4/5 validity

We currently don't do any validity check. If I have uv4 project, and use uv5 parser, it parsers it without any errors, just the mcu definition might not be correct.

We should add additional checks for uv4 not to try to parse uv5 project file (with software packs).

ProGen definitions v1

Followup for #18. I am preparing definitions v0.0.1 for ProGen v0.8.x, which is going to be python module. I already got branch for this devel: https://github.com/project-generator/project_generator_definitions/tree/dev_v1. I am going to publish v0.0.1 this weekend, so we can start testing this how it works. I'll send PR to progen v0.8 branch to start using this python module.

The module will contain yaml files, ProGenDef class providing API for definitions. We should write tests - each yaml definition is tested to contain valid syntax, all data which are required. I ported so far simple test case just to get travis working and structure for tests.

Any ideas for this upcoming version, speak now!

Support uvision5 for cortex-mXX

Add MCU Cortex-Mxx support for uvision5

Currently supports only uvision (should be compatible), but fails if -t uvision5 is used

Semantic versioning for this repo

This would be better to follow semver, as we might have some breaking changes in syntax , mcu definitions or newer versions of ides, etc..

Currently project generator tracks master. For the upcoming v0.8, I am thinking about turning this into python module, and use semver. If we do this, I might go back to older versions and create a patch for v0.5-v0.7, which would start using python module.

STM32/IAR: make UseFlashLoader option enabled by default

Hi
When I export MBED test for a NUCLEO_STM32 targets and IAR,
I always need to change project option within the IDE to use flash loader in the Debugger/Download options.

Maybe it can be automatic by changing yaml files ?

Thx

MCU - shall contain fpu settings

The MCU settings in many IDE has own FPU settings which should be defined by a target.

I'll have to look at those settings, how we can capture them in definitions and use in the progen.

GCC + Make support

Do you want it?
Would you be okay with a beefed up version of the mbed-os template?
I can get it done in about a day, so I'll be working on it tomorrow, let me know if It's not what you want.

uvision5 for NUCLEO_F746ZG: flasholoader not set

Hello,
When I export a project for NUCLEO_F746ZG it does not contain the correct information for flash
mbed export -i uvision5 -m NUCLEO_F746ZG --source=mbed-os/TESTS/mbed_drivers/c_strings
The correct value seems to be in the .uvoptx file

          <Number>0</Number>
          <Key>UL2CM3</Key>
          <Name>UL2CM3(-S0 -C0 -P0 -FD20010000 -FC1000 -FN1 -FF0STM32F7x_1024 -FS08000000 -FL0100000 -FP0($$Device:STM32F746ZG$CMSIS\Flash\STM32F7x_1024.FLM))</Name>

Could you fix it, please ?
Cheers

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.