Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cc2531 USB dongle support #18

Closed
wants to merge 16 commits into from

Conversation

g-oikonomou
Copy link
Contributor

This patch set adds native USB support for the TI cc2531 USB dongle. This is an important enhancement (read as: we want this upstream pronto)

First things first, credit where credit's due. This work is based on the USB framework in cpu/arm/common/usb. Thanks to Philippe Rétornaz @ EPFL for making the necessary adjustments to the arm usb framework and for writing the low level usb driver for the dongle (among his other very significant contributions).

The result of using this framework is that we've inherited a couple of issues:

  • Licensing: Many files don't have a license header. Do they have a maintainer currently? Does anyone have direct contact with the original contributor (Simon Berg?)?
  • The code style leaves a lot to be desired. I've made plenty of fixes but more are still needed (e.g. some variables not in all lowercase). Because i) this is important and ii) I've got a bigger patch lined up with code style cleanup for all 8051-based platforms, I've decided to open this with the code in its current state. Hope that's OK with everyone else.

Philippe Rétornaz and others added 16 commits November 1, 2012 00:22
Change to have a real usb VID/PID and better fit the capabilities
of the CC2531 hardware (enpoint size, location).

Compile only if the cdc-acm class is requested.
The P2 Interrupt is shared across many periferal (I2C, USB, GPIO).
This adds a generic interrupt handler on which the differents drivers
can register a handler.
This is mainly a naming convention thing, we want to have 'isr'
as part of the name, instead of 'int'. We also want port_2 instead
of p2 because we already had port_1
We keep the ISR in its own file and move everything else
to a different one, so that we only have to keep the ISR
in HOME
- usb cdc-acm:
  * implement get line coding
  * use printf only when debugging
  * Add events

- usb-core: do not force debugging
- Fixed DMA irq flag clearing
- Added a dma_reset helper
This is based on a usb-test example by Philippe Retornaz. It has
been moved to platform and modified accordingly. With this in place:

- putchar() can work over USB. So we can use things like
  printf, slip output
- USB input can be redirected to slip or serial input

The example itself is no longer needed in the source tree
@adamdunkels
Copy link
Member

I haven't heard from Simon in a few years I think.

Regarding code style: since this is deep in a platform/ dir, and because you've got a fix upcoming anyway, I say go for it: +1

g-oikonomou pushed a commit that referenced this pull request Nov 1, 2012
g-oikonomou pushed a commit that referenced this pull request Nov 1, 2012
Change to have a real usb VID/PID and better fit the capabilities
of the CC2531 hardware (enpoint size, location).

Compile only if the cdc-acm class is requested.

See Pull Request #18
g-oikonomou pushed a commit that referenced this pull request Nov 1, 2012
The P2 Interrupt is shared across many periferal (I2C, USB, GPIO).
This adds a generic interrupt handler on which the differents drivers
can register a handler.

See Pull Request #18
g-oikonomou pushed a commit that referenced this pull request Nov 1, 2012
See Pull Request #18
g-oikonomou pushed a commit that referenced this pull request Nov 1, 2012
g-oikonomou added a commit that referenced this pull request Nov 1, 2012
g-oikonomou added a commit that referenced this pull request Nov 1, 2012
This is mainly a naming convention thing, we want to have 'isr'
as part of the name, instead of 'int'. We also want port_2 instead
of p2 because we already had port_1

See Pull Request #18
g-oikonomou added a commit that referenced this pull request Nov 1, 2012
We keep the ISR in its own file and move everything else
to a different one, so that we only have to keep the ISR
in HOME

See Pull Request #18
g-oikonomou added a commit that referenced this pull request Nov 1, 2012
g-oikonomou pushed a commit that referenced this pull request Nov 1, 2012
- usb cdc-acm:
  * implement get line coding
  * use printf only when debugging
  * Add events

- usb-core: do not force debugging

See Pull Request #18
g-oikonomou pushed a commit that referenced this pull request Nov 1, 2012
g-oikonomou pushed a commit that referenced this pull request Nov 1, 2012
- Fixed DMA irq flag clearing
- Added a dma_reset helper

See Pull Request #18
g-oikonomou added a commit that referenced this pull request Nov 1, 2012
This is based on a usb-test example by Philippe Retornaz. It has
been moved to platform and modified accordingly. With this in place:

- putchar() can work over USB. So we can use things like
  printf, slip output
- USB input can be redirected to slip or serial input

The example itself is no longer needed in the source tree

See Pull Request #18
g-oikonomou added a commit that referenced this pull request Nov 1, 2012
g-oikonomou added a commit that referenced this pull request Nov 1, 2012
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
Change to have a real usb VID/PID and better fit the capabilities
of the CC2531 hardware (enpoint size, location).

Compile only if the cdc-acm class is requested.

See Pull Request contiki-os#18
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
The P2 Interrupt is shared across many periferal (I2C, USB, GPIO).
This adds a generic interrupt handler on which the differents drivers
can register a handler.

See Pull Request contiki-os#18
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
This is mainly a naming convention thing, we want to have 'isr'
as part of the name, instead of 'int'. We also want port_2 instead
of p2 because we already had port_1

See Pull Request contiki-os#18
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
We keep the ISR in its own file and move everything else
to a different one, so that we only have to keep the ISR
in HOME

See Pull Request contiki-os#18
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
- usb cdc-acm:
  * implement get line coding
  * use printf only when debugging
  * Add events

- usb-core: do not force debugging

See Pull Request contiki-os#18
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
- Fixed DMA irq flag clearing
- Added a dma_reset helper

See Pull Request contiki-os#18
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
This is based on a usb-test example by Philippe Retornaz. It has
been moved to platform and modified accordingly. With this in place:

- putchar() can work over USB. So we can use things like
  printf, slip output
- USB input can be redirected to slip or serial input

The example itself is no longer needed in the source tree

See Pull Request contiki-os#18
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
EarthLord pushed a commit to EarthLord/contiki that referenced this pull request Jun 18, 2014
simonduq referenced this pull request in simonduq/contiki Jul 2, 2014
ejoerns pushed a commit to ejoerns/contiki-inga that referenced this pull request Oct 11, 2014
[inga] apps/settings_set: make sure, the settings_set app uses the defin...
mtusnio referenced this pull request in CreatorDev/contiki Oct 21, 2016
platform/mikro-e/dev: add motion click driver and update relay click driver
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants