Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion nanoFramework.M5Core2/M5Core2.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Licensed to the .NET Foundation under one or more agreements.
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using Iot.Device.Axp192;
Expand Down Expand Up @@ -333,6 +333,12 @@ public static AdcChannel GetAdcGpio(int gpioNumber)

switch (gpioNumber)
{
case 35:
Configuration.SetPinFunction(11, DeviceFunction.ADC1_CH7);
return _adc.OpenChannel(7);
case 36:
Configuration.SetPinFunction(5, DeviceFunction.ADC1_CH0);
return _adc.OpenChannel(0);
case 32:
Configuration.SetPinFunction(32, DeviceFunction.ADC1_CH4);
return _adc.OpenChannel(4);
Expand Down