GithubHelp home page GithubHelp logo

embedded-office / canopen-stm32f7xx Goto Github PK

View Code? Open in Web Editor NEW
6.0 1.0 3.0 417 KB

CANopen quickstart application for the STM32F769 to illustrate how the free CANopen Stack is used in your project.

Home Page: https://canopen-stack.org/latest/start/quickstart/

License: Apache License 2.0

CMake 2.73% C 74.24% Assembly 23.03%
canopen example quickstart stm32f769

canopen-stm32f7xx's People

Contributors

michael-hillmann avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

canopen-stm32f7xx's Issues

implement the EMCY demonstration

The quickstart example describes a tiny EMCY use-case: EEPROM is unplugged will rise a 5000h EMCY code (and error register bit 0).

Improving driver organization - opened for discussion

For the long term, we need to establish a naming and storage location convention to get most out of existing and maybe new developed drivers.

One idea is:

+- src
|  +- driver                                            : the group of drivers for CANopen
|  |  +- <device-hal-name>                              : extern component from chip manufacturer
|  |  |  +- drv-(can|nvm|timer)-<hw-unit-name(s)>.c/h   : the hardware units we use

and with the exported interface structures:

const CO_IF_(CAN|NVM|TIMER)_DRV <device>_<hw-unit-name(s)_(Can|Nvm|Timer)Driver;

For example for existing driver in this repo:

src/driver/stm32f7xx-hal/drv-can-can1.c/h
src/driver/stm32f7xx-hal/drv-nvm-i2c1-at24c256.c/h
src/driver/stm32f7xx-hal/drv-timer-tim2.c/h

and

const CO_IF_CAN_DRV   STM32F7xx_CAN1_CanDriver;
const CO_IF_NVM_DRV   STM32F7xx_I2C1_AT24C256_NvmDriver;
const CO_IF_TIMER_DRV STM32F7xx_TIM2_TimerDriver;

Some notes:

  • stm32f7xx-hal - it seems to be suitable to address a chip series, because a driver within a chip series is 99% identical. We need to allow some configuration (e.g. for pin mappings or clock frequencies).
  • i2c1-at24c356 - this means external component at24c256 connected to the internal i2c1.
  • Rather than writing complex configurable single driver files, I prefer multiple simple driver files where we decide essential configuration options by choosing the right driver file.

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.