File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -690,7 +690,9 @@ int ScienceKitCarrier::beginExternalTemperature(){
690690
691691void ScienceKitCarrier::updateExternalTemperature (){
692692 float temperature;
693+ pinMode (OW_PIN,INPUT);
693694 DSTherm drv (ow);
695+
694696 drv.convertTempAll (DSTherm::MAX_CONV_TIME, false );
695697
696698 static Placeholder<DSTherm::Scratchpad> scrpd;
@@ -715,6 +717,7 @@ void ScienceKitCarrier::updateExternalTemperature(){
715717 }
716718}
717719
720+
718721float ScienceKitCarrier::getExternalTemperature (){
719722 return external_temperature;
720723}
@@ -726,8 +729,9 @@ bool ScienceKitCarrier::getExternalTemperatureIsConnected(){
726729void ScienceKitCarrier::threadExternalTemperature (){
727730 beginExternalTemperature ();
728731 while (1 ){
729- updateAnalogInput (UPDATE_INPUT_A);
732+ // updateAnalogInput(UPDATE_INPUT_A);
730733 updateExternalTemperature ();
734+ updateAnalogInput (UPDATE_INPUT_A);
731735 rtos::ThisThread::sleep_for (1000 );
732736 }
733737}
Original file line number Diff line number Diff line change 3131#include " Arduino_BMI270_BMM150.h"
3232#include " Arduino_GroveI2C_Ultrasonic.h"
3333
34- #include " OneWireNg_CurrentPlatform.h"
34+ // #include "OneWireNg_CurrentPlatform.h"
35+ #include " ../../OneWireNg/src/platform/OneWireNg_PicoRP2040.h"
36+ #define OneWireNg_CurrentPlatform OneWireNg_PicoRP2040
3537#include " drivers/DSTherm.h"
3638#include " utils/Placeholder.h"
3739
You can’t perform that action at this time.
0 commit comments