Date   

Re: Problems after implementing weater functions

Laurent HOUSSAYE
 

Sorry I was wrong in my last post : the Basic configuration that is OK and perfectly stable is with OCS version 2.1c. I did'nt update it because it is operating perfectly.


Re: Problems after implementing weater functions

Laurent HOUSSAYE
 

Update of 18th of April 2021:
Starting point : OCS version 2.31.
  • Basic configuration : Roof control function + Power relays control function. Operates perfectly in particular the relays operate perfectly. That would eliminate the suspicion of a hardware problem (8 relays module powered indepedently of the MEGA).
  • Upgraded configuration (Basic plus Weather function - all sensors excepted SQM) : Weather data are correctly displayed on the overview panel but the Weather and Sky plots are displayed completely empty : the frames are displayed but nothing inside. See pictures in my previous post. The system turns unstable in this configuration.
- Unstable (no more than 1 minute Up Time) if I activate the power relays.
- Even if I do not activate the power relays, the system hangs and reboots, but it takes more time (Up Time reset during my lunch time, then reset in less than 10 minutes now that I am attending).
I tried to put WATCHDOG OFF as you suggested and it is worse : The OCS web page freezes and can no longer be opened. I returned to WATCHDOG ON_CC. I suppose that Up Time counter lets me know the time since the last hang-up and reboot.
I have copied exactly the arduino codes for the weather sensors that you have profided in the file named "Functions" under "Weather.ino examples".
Is there a way of debugging all this ?
Next thing I will do is connect an original TSL2591 sensor from Adafruit and try to get correct SQM data but I am getting short of ideas to solve this issue of instability.
Any help would be appreciated.
Best Regards,
Laurent


commands sqm and temperature not working ore present

koal01
 

Hi Howard
Is it possible for you to check why i can't get the temperature through the command :G1#
I'm using the Adafruit si7021 and the weather is displaid on the weather panel but impossible through the monitor 
Also concerning SQM there's no command, is it possible to add it to the command list so i can get the mpsas record.
Thanks so much in advance
Koal01


Re: Problems after implementing weater functions

Laurent HOUSSAYE
 

Some update after further testing :
I tried to put SQM OFF in config.h : no success : frequent reboots whatever the status of the 2 power relays (On or Off). No visible sign of these reboots when the relays are OFF (they remain OFF) except that the Up Time stays at 00000 min.
I tried to put all the I2C bus sensors OFF in config.h :
  • with the SDA and SCL wires still connected, same instabilities (in less than 1 minute)
  • With the SDA and SCL wires unplugged : stable ! No reboot at all, the 12V power relay stays ON at least up to 10 minutes "Up Time" ! Rain sensor and wind speed are correctly displayed however the weather log charts remain empty...
I need to try disconnecting only the SQM sensor to see if it is the culprit on the I2C bus !
What remains a bit strange to me yet is the fact that when I returned to my initial set up with no weather function activated (only ROR panel and Power relays panel), the system was stable even with the I2C SDA and SCL wires plugged in...
Is there a mix of software and hardware causes ?
I will let you aware of the future outcomes.
Regards,
Laurent


Re: Problems after implementing weater functions

Laurent HOUSSAYE
 

Good morning Howard
the problem is that if I turn off the Watchdog the OCS web page fails and freezes...
I had no relay problem at all with my previous configuration and the same relay wiring (8xrelays card is powered separately and not by the MEGA 5V).
I have used the SQM code that you provided in the Weather Functions file for the TSL2591, exactly copied. Remark: It is the clone version of the Adafruit chip. 

I will attempt to use an original Adafruit chip, after first disconnecting this sensor and see if the problem is still present.
it would already be nice if it worked with all the other sensors !!!
Clear skies !
Laurent


Re: Extracting XML flow from Ocs possible ?

koal01
 

All commands to get weather information work fine except temperature...


Re: Extracting XML flow from Ocs possible ?

koal01
 

That's exactly what i need, thanks Howard !
I'm going to test these commands  and let you know
In one post you talked about a project of builiging an OCS on an ESP32, is it for a distant future ? :);


Re: Extracting XML flow from Ocs possible ?

Howard Dutton
 

The OCS doesn't do XML :)

What it does have is an LX200 like protocol with :xxxx# framed commands and # terminated responses.  You can see the available commands in Command.ino, they include commands to return the temperature and humidity.
The command processor works with the Arduino Serial port but also with Ethernet.  For Ethernet you open the port, send the command, get the response, then close the port.  This allows multiple clients to talk to a single port at the "same" time (9999 and 9998 are active.)

There is only one serial port active in the OCS, just Arduino's "Serial" (where the USB/serial is) but adding others (Serial1 and Serial2 for example) is trivial.


Re: Problems after implementing weater functions

Howard Dutton
 

On Tue, Apr 6, 2021 at 05:33 AM, Laurent HOUSSAYE wrote:

I have used OCS up to now with success with the Roof and Power functions only. I was able to activate 2 relays for the 12 V power supply of the telescope mount and accessories, and for the 220 V power supply (not wired yet at the relay output).

The roof commands are operating perfectly.

Recently I have included all the weather sensors allowed by the Weather code, using the examples you provided.

The code compiles and loads perfectly in the Arduino card after having included all the libraries required. I have put the file Charts.min.js in the SD card (renamed Charts.js) and inserted the SD card in the Ethernet shield as required.

But I have some problems : When I activate the 12 V power relay (ON), the Arduino reboots frequently (A Watchdog ON)

I'd turn the watchdog off, the feature is there but it working properly depends on Mega2560 firmware support that isn't always present.

and that causes interruptions of this crucial power supply ! That's not acceptable as it is. When only the 220 V power supply relay is activated, no problem ! Very strange !


Sounds like a hardware problem.  There are a wide range of effects with power supply sag, back EMF from the relay coils, RFI noise from the relay contacts, HV traveling on the surface of PCB's.

The weather sensors data are correctly displayed with the exception of the Sky Quality Meter that shows "Invalid" (However I have checked that TSL2591 responds at the correct address of 0x29 - checked with an I2C scan). See screen capture attached.

I provided an example that works for myself and others.  If you can get the SQM function working properly with other software do so then integrate that software.


Last problem : the Weather charts are all empty. See pictures attached.

Not sure why that'd be, obviously it works for others.  Perhaps give it time to write the next days log file, all these crashes could be causing an issue.

Sorry but implementing an OCS with all features is a complex thing with many ways for things to go wrong.


Problems after implementing weater functions

Laurent HOUSSAYE
 

Hello,

I have used OCS up to now with success with the Roof and Power functions only. I was able to activate 2 relays for the 12 V power supply of the telescope mount and accessories, and for the 220 V power supply (not wired yet at the relay output).

The roof commands are operating perfectly.

Recently I have included all the weather sensors allowed by the Weather code, using the examples you provided.

The code compiles and loads perfectly in the Arduino card after having included all the libraries required. I have put the file Charts.min.js in the SD card (renamed Charts.js) and inserted the SD card in the Ethernet shield as required.

But I have some problems : When I activate the 12 V power relay (ON), the Arduino reboots frequently (A
Watchdog ON) and that causes interruptions of this crucial power supply ! That's not acceptable as it is. When only the 220 V power supply relay is activated, no problem ! Very strange !

 

The weather sensors data are correctly displayed with the exception of the Sky Quality Meter that shows "Invalid" (However I have checked that TSL2591 responds at the correct address of 0x29 - checked with an I2C scan). See screen capture attached.

Last problem : the Weather charts are all empty. See pictures attached.

I would appreciate your help to be able to upgrade OCS with all its wonderful functions in a stable manner !

Best regards,

 

Laurent HOUSSAYE

 


Extracting XML flow from Ocs possible ?

koal01
 

Hi Howard,
I’m building an Allsky just next to OCS, from time to time the camera under the dome will need some heating when humidity and temperature reach a certain level. An idea has crossed my mind that would be the possibility with OCS to give the sensor values to avoid installing new sensors. As OCS is a webserver i thought it would be possible to generate an xml output when a request is sent from a client. I really don’t know the effort  that would be necessary to make this but the idea seems interesting to me. I know how to program a small board (nano, micro) with a simple web client page, collect parameters from a webserver with actions to launch.
It is not a demand but a question as I know you are very busy with Onstep environment we are all enjoying.

Thanks in advance for your answer 
koal01


Re: relay outputs

Laurent HOUSSAYE
 

I have made the modification and it works as I wish now.
Thanks


Re: wifi integration evolution ?

koal01
 

Running full OCS on a ESP32 would be terrific, this MCU is cheap and fast.
Would you intend to build a PCB based on the ESP32, the 38 pin version i suppose,  with selected features (as the Mini in your OnStep project) or would this ESP32 cover all the current features in OCS ?
Any way i'll follow this project and it will be a pleasure to test, i'm avalaible.

Thank you
Koal01


Re: wifi integration evolution ?

Howard Dutton
 

On Fri, Feb 26, 2021 at 07:21 AM, koal01 wrote:
In the future is there any wifi integration in your roadmap on OCS ?
I'm building a second OCS wich would be a nomad version mainly to get the weather webpage.
I was wondering if using few pins, a portable version on a teensy would be possible ?
No plans for the Teensy but adding the capability to run the OCS on the ESP32 has crossed my mind.
The Ethernet webserver in the OCS is a mirror of the ESP8266/ESP32 WiFi, not exactly the same, but close.


Re: wifi integration evolution ?

Howard Dutton
 

On Fri, Feb 26, 2021 at 07:21 AM, koal01 wrote:
By the way my sedentary OCS is very solid, months without any crash, great !
That's what I want to hear.


Re: relay outputs

Howard Dutton
 
Edited

Yes that capability is in the OCS.ino file...

Probably should make it something you setup in Config.h since the need to do so comes up quite often.


Re: relay outputs

Laurent HOUSSAYE
 

Sorry I should have looked first at the this forum where this issue was already reported and answered...


relay outputs

Laurent HOUSSAYE
 

Hello,
All my relay outputs are high when not activated, and turn low when activated. Is it normal? Can it be set the other way round?


wifi integration evolution ?

koal01
 

Hi Howard,
In the future is there any wifi integration in your roadmap on OCS ?
I'm building a second OCS wich would be a nomad version mainly to get the weather webpage.
I was wondering if using few pins, a portable version on a teensy would be possible ?

By the way my sedentary OCS is very solid, months without any crash, great !


Thank you
Koal01


Re: New OCS developments

Howard Dutton
 

On Thu, Dec 24, 2020 at 02:09 PM, Zoltán Pásztor wrote:
Is there any chance in the future any slave mode or connecting to the OnStep?
I'm thinking about close the roof after parking, and open before unpark. And parking on a safety closing.
Is this an ASCOM function, or other?
I will given adding this feature consideration at some point.

181 - 200 of 538