×

INDI Library v2.0.6 is Released (02 Feb 2024)

Bi-monthly release with minor bug fixes and improvements

Building the induino MeteoStation with 3d printed housing

  • Posts: 2247
  • Thank you received: 223
ok I think it's cable related, had the same issue there github.com/dokeeffe/indi-aldiroof/issues/4
6 years 6 months ago #19538

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
back to basic tests.
loaded up the meteoTEST code, then connected to the arduino to the laptop, then use screen /dev/ttyACM0 9600
I can see the output, no issues there.
6 years 6 months ago #19540

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
I have switched over to a different Arduino board, from a Pro Micro to a Nano v3.0
I can now see the raw data in Ekos, seems to be working-ish...



Last edit: 6 years 6 months ago by Gonzothegreat.
6 years 6 months ago #19546
Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 271
  • Thank you received: 72
Nice to see progress :)

Whats the 'working-ish' part? The raw sensors looks like having valid data, how is the METEO tab looking?
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
6 years 6 months ago #19549

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
raw data works fine as expected, the Meteo tab... not so much. oh I see I did not upload the right screenshot. hold on.
6 years 6 months ago #19550

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
I have edited the post with the right screenshot, also corrected the wrong pin for the irradiance (now working fine).
In the meteo tab, the Celsius, SkytT and Cloud are reporting 0.
6 years 6 months ago #19551

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
I got it !!!! I have to modify the xml file for the meteotab. I've just fixed the Celsius value.
6 years 6 months ago #19553

Please Log in or Create an account to join the conversation.

  • Posts: 271
  • Thank you received: 72
On the right track then!

Only thing is that i'm not sure you should need to modify the skeleton file.

I was under the impression that changing the pin in the firmware should do the trick. The sensors is reported over 'virtual' pins defined in firmata part of the firmware. Ideally you should just change it there and be good to go.

Did you check out the partial tutorial?
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
6 years 6 months ago #19560

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
I have checked the partial tutorial, great work.
In the xml file, I had to match the virtual pins from the Meteo tab to the raw data tab.
One last one to fix is the Cloud in the meteo tab, more reading in the code for this one.

I also need to understand the different between the Nano V3.0 and the Pro Micro Arduino.
6 years 6 months ago #19561

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
Here's a diff of the original skeleton file and my version, only certain pin numbers changed.

root@ubuntu:/usr/share/indi# diff meteostation_sk.xml meteostation_sk.xml2
5c5
< <indiduino pin="17" type="input" mul="0.05" add="-273"/>
---
> <indiduino pin="24" type="input" mul="0.05" add="-273"/>
27c27
< <indiduino pin="14" type="input" mul="0.05" add="-273"/>
---
> <indiduino pin="23" type="input" mul="0.05" add="-273"/>
124c124
< <indiduino pin="9"/>
---
> <indiduino pin="7"/>
128c128
< <indiduino pin="7"/>
---
> <indiduino pin="8"/>
root@ubuntu:/usr/share/indi#
6 years 6 months ago #19563

Please Log in or Create an account to join the conversation.

  • Posts: 271
  • Thank you received: 72
Ok. looks like its under control.

Here is the two functions that map the pins with data for the driver
// Changes the values from kelvin to c and such before writing to analog pins.
int mapAndSendAnalog(int pin) {
 
//some scalation are use. Don't change without changing also skeleton file
  int value=0;
  int result=0;
 
  switch(pin) {
      //PIN 14->A0, 24->A10
       case 0:
               result=(IR+273)*20;
               break;
       case 1:
               result=(Tir+273)*20;
               break;
       case 2:
               result=(P/10);
               break;
       case 3:
               result=(Tp+273)*20;
               break;
       case 4:
               result=HR*100;
               break;
       case 5:
               result=(Thr+273)*20;
               break;
       case 6:
               result=(Dew+273)*20;
               break;
       case 7:
               result=Light;
               break;
       case 8:
               result=Clouds;
               break;
       case 9:
               result=(skyT+273)*20;
               break;
       case 10:
               result=(T+273)*20;
               break;
 
 
       default:
             result=value;
             break;
  }
  Firmata.sendAnalog(pin,result);
}
 
// Writes the alerts when condition met
void checkMeteo() {
 
    if (cloudy==1) {
       digitalWrite(PIN_TO_DIGITAL(3), HIGH); // enable internal pull-ups
    } else {
       digitalWrite(PIN_TO_DIGITAL(3), LOW); // disable internal pull-ups
    }
 
    if (dewing==1) {
       digitalWrite(PIN_TO_DIGITAL(4), HIGH); // enable internal pull-ups
    } else {
       digitalWrite(PIN_TO_DIGITAL(4), LOW); // disable internal pull-ups
    }
 
    if (frezzing == 1) {
       digitalWrite(PIN_TO_DIGITAL(5), HIGH); // enable internal pull-ups
    } else {
       digitalWrite(PIN_TO_DIGITAL(5), LOW); // disable internal pull-ups
    }
 
    if (Light>MINIMUM_DAYLIGHT) {
       digitalWrite(PIN_TO_DIGITAL(6), HIGH); // enable internal pull-ups
    } else {
       digitalWrite(PIN_TO_DIGITAL(6), LOW); // disable internal pull-ups
    }
 
}

Also
- digiPin 7 IR sensor fail
- digiPin 8 Humidity sensor fail
- digiPin 9 Pressure sensor fail

I just dont know why you should have to change this. I have not updated any of this here or in the skeleton file, so sould just work?
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
6 years 6 months ago #19565

Please Log in or Create an account to join the conversation.

  • Posts: 2247
  • Thank you received: 223
I'm currently testing the web part, a few things aren't working as expected. I shall let you know once I get it working.
6 years 6 months ago #19566

Please Log in or Create an account to join the conversation.

Time to create page: 0.402 seconds