Skip to content

kinetis: Allow per-board config of ADC ref#8560

Merged
smlng merged 1 commit intoRIOT-OS:masterfrom
jnohlgard:pr/kinetis-adc-ref
Feb 16, 2018
Merged

kinetis: Allow per-board config of ADC ref#8560
smlng merged 1 commit intoRIOT-OS:masterfrom
jnohlgard:pr/kinetis-adc-ref

Conversation

@jnohlgard
Copy link
Copy Markdown
Member

Contribution description

ADC reference can be external pin or internal VREF module on most Kinetis CPUs. The CPU reference manual has a description of the valid values for each CPU, but I have added a short summary of the options in each of the existing periph_conf.h headers for reference.
This was previously hard-coded to always use reference setting 0, but for the FRDM-KW41Z board we need to use setting 1 to get valid ADC readings without always having VREF enabled (which would increase power consumption)

Issues/PRs references

Required by #6995

ADC reference can be external pin or internal VREF module on most
Kinetis CPUs.
@jnohlgard jnohlgard added Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation Platform: ARM Platform: This PR/issue effects ARM-based platforms CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR labels Feb 14, 2018
@jnohlgard jnohlgard added this to the Release 2018.04 milestone Feb 14, 2018
Copy link
Copy Markdown
Member

@smlng smlng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK, no (big) magic happening here, still successfully tested ADC with pba-01-kw2x -> works.

We might consider to put allowed values into to the respective cpu.conf and set a reasonable default per board, thereby omitting the magic 0 and duplicated documentation above here.

@smlng smlng merged commit 966d83d into RIOT-OS:master Feb 16, 2018
@jnohlgard jnohlgard deleted the pr/kinetis-adc-ref branch February 16, 2018 14:10
@jnohlgard
Copy link
Copy Markdown
Member Author

Thank you @smlng

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Platform: ARM Platform: This PR/issue effects ARM-based platforms Type: enhancement The issue suggests enhanceable parts / The PR enhances parts of the codebase / documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants