Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Robo-Tank Web App - Development
#84
Well today was emotional.   K05163

Didn't get a lot done on software last week, was busy but it was also nice to clear the head of code a little longer. Now I'm ready for a good week on the app.

On Thursday night I happened to notice the dosing reservoirs on app were empty which shouldn't have been. So I hit the refill button and next day they were empty again, oh no!!!!!!! It seemed to be running fine for a few days.

I first thought it was an issue with the custom rules as it was still running the ones in the video. So I dig in, code looks fine sending me in circles then I realize the Pi was sensing a change on the GPIO pin for one of the floats on GPIO 27 so the custom rule was doing what it should have. Each pin is read about 200 per second so I slowed things down, it happened much less but still happened. Then I put controller on bench to see if something is up with the hardware causing a quick LOW HIGH pulse on the GPIO as that's what was happening but on it's own randomly. Sure enough I could see it on the scope.

It was a big change in voltage so I didn't think it could be related to hardware and felt it was more likely something fundamentally wrong with my app but what. I'm using wiringPi library to read and control the GPIO pins, when I started on the Pi I put a good effort into controlling GPIO's directly without a library but wasn't able to figure it out, wasn't as easy as I expected. The original author of wiringPi quit a couple years ago and it seems to be a dead project so I fear one day the Pi would update and it might stop working as it has limited support for Pi 4. I thought it was slim the library was at fault but because it needed changing some point I decided to do another search to control them directly and bam I actually figured it out, now I don't need to be dependent on the library, feeling good about this at least.

Then I setup a sketch to read GPIO 27 directly but I'm unable to, it reports an error saying system is busy. I could read other pins that I randomly tried. So I start searching and come across someone in a forum saying you can't read GPIO 27 directly because it's connected to the LED on the board and something needed to be uninstalled to get direct access to that pin. He also stated pins 0,6,14,15 and 29 couldn't be read directly so I test those and they all read expect 14. Well this didn't make sense as wiringPi has no issues with them and kind of throws a wrench into removing the wiringPi library as nothing I was trying worked. 

Because I read that pin is connected to the LED I started thinking the worst, all these controller out there and this is likely happening, the only silver lining I could think was reef-pi isn't monitoring them real time so good chance it would never know that happened as it would be instant, I only discovered this now because I only started monitoring sensors in real time, if a pin changes states within 5 milliseconds the rules will detect it.

So now what, not feeling so great at this moment. K05106

I decided I guess I need to go down the rabbit hole of uninstalling this particle feature the poster briefly mentioned. Eventually I found myself in the config.txt file and what do I see, GPIO 27 and 14 were assigned as a 1-wire bus for DS18B20 temp sensors. I completely forgot I added those Thursday as I was doing one last test one everything for the new controller. I was verifying again the sensor ports would work for them so I had to configure them as such. This is why it was working.

K05164 K05164  No more issues.  K05164 K05164

Ah the joys...  K05163

For today I'm leaving the wiringPi library, I'll switch over first thing after initial release. All this pain was worth it though, one less library to work with.

Next update should be more exciting.  K05178
[-] The following 2 users Like Rob F's post:
  • albinochicken89, Brooks
Reply to top


Messages In This Thread
Robo-Tank Web App - Development - by Rob F - 04-18-2021, 12:41 AM
RE: Robo-Tank Web App - by tutuss21 - 04-18-2021, 01:26 AM
RE: Robo-Tank Web App - by JFReyes - 04-18-2021, 04:31 AM
RE: Robo-Tank Web App - by Jerry W - 04-18-2021, 11:00 AM
RE: Robo-Tank Web App - by Dom59 - 04-18-2021, 03:07 PM
RE: Robo-Tank Web App - by Rob F - 04-18-2021, 03:07 PM
RE: Robo-Tank Web App - by fred73 - 04-19-2021, 05:16 PM
RE: Robo-Tank Web App - by rott - 04-23-2021, 07:51 AM
RE: Robo-Tank Web App - by Dom59 - 04-23-2021, 10:31 AM
RE: Robo-Tank Web App - by Rob F - 04-23-2021, 11:11 AM
RE: Robo-Tank Web App - by loksik.lubos - 04-25-2021, 02:03 PM
RE: Robo-Tank Web App - by Rob F - 04-25-2021, 08:47 PM
RE: Robo-Tank Web App - by Rob F - 05-23-2021, 12:50 AM
RE: Robo-Tank Web App - by albinochicken89 - 06-13-2021, 12:30 PM
RE: Robo-Tank Web App - by Rob F - 06-13-2021, 06:54 PM
RE: Robo-Tank Web App - by rott - 06-19-2021, 07:38 PM
RE: Robo-Tank Web App - by Rob F - 06-19-2021, 07:41 PM
RE: Robo-Tank Web App - by rott - 06-20-2021, 03:05 PM
RE: Robo-Tank Web App - by Weasel1960 - 06-23-2021, 04:13 AM
RE: Robo-Tank Web App - by Rob F - 06-23-2021, 04:46 PM
RE: Robo-Tank Web App - by Rob F - 07-08-2021, 11:40 PM
RE: Robo-Tank Web App - by Weasel1960 - 07-11-2021, 04:59 PM
RE: Robo-Tank Web App - by Dom59 - 07-09-2021, 09:34 AM
RE: Robo-Tank Web App - by Rob F - 07-09-2021, 05:48 PM
RE: Robo-Tank Web App - by Rob F - 07-11-2021, 08:54 PM
RE: Robo-Tank Web App - by Rob F - 07-16-2021, 10:10 PM
RE: Robo-Tank Web App - by Weasel1960 - 07-22-2021, 09:07 PM
RE: Robo-Tank Web App - by Rob F - 07-22-2021, 09:58 PM
RE: Robo-Tank Web App - by Rob F - 07-29-2021, 12:37 AM
RE: Robo-Tank Web App - by Brooks - 07-29-2021, 12:56 PM
RE: Robo-Tank Web App - by albinochicken89 - 07-29-2021, 01:02 PM
RE: Robo-Tank Web App - by Rob F - 07-29-2021, 01:38 PM
RE: Robo-Tank Web App - by Rob F - 08-10-2021, 09:35 PM
RE: Robo-Tank Web App - by Rob F - 08-11-2021, 12:13 AM
RE: Robo-Tank Web App - by Brooks - 08-11-2021, 10:21 AM
RE: Robo-Tank Web App - by albinochicken89 - 08-11-2021, 02:24 PM
RE: Robo-Tank Web App - by Rob F - 08-11-2021, 04:36 PM
RE: Robo-Tank Web App - by deeproot - 08-11-2021, 09:24 PM
RE: Robo-Tank Web App - by Rob F - 08-11-2021, 10:30 PM
RE: Robo-Tank Web App - by deeproot - 08-11-2021, 10:41 PM
RE: Robo-Tank Web App - by Rob F - 08-11-2021, 11:11 PM
RE: Robo-Tank Web App - by zee_zout - 08-12-2021, 08:16 AM
RE: Robo-Tank Web App - by Rob F - 08-12-2021, 03:36 PM
RE: Robo-Tank Web App - by Rob F - 08-12-2021, 04:49 PM
RE: Robo-Tank Web App - by Weasel1960 - 08-13-2021, 07:25 AM
RE: Robo-Tank Web App - by Rob F - 08-13-2021, 01:55 PM
RE: Robo-Tank Web App - by Rob F - 08-17-2021, 12:15 AM
RE: Robo-Tank Web App - by Brooks - 08-25-2021, 04:01 AM
RE: Robo-Tank Web App - by Rob F - 08-25-2021, 08:19 PM
RE: Robo-Tank Web App - by deeproot - 08-25-2021, 11:05 PM
RE: Robo-Tank Web App - by Rob F - 08-26-2021, 01:05 AM
RE: Robo-Tank Web App - by Brooks - 08-26-2021, 10:53 AM
RE: Robo-Tank Web App - by Rob F - 08-29-2021, 12:20 AM
RE: Robo-Tank Web App - by Rob F - 08-30-2021, 10:47 PM
RE: Robo-Tank Web App - by deeproot - 08-30-2021, 11:08 PM
RE: Robo-Tank Web App - by Rob F - 08-30-2021, 11:16 PM
RE: Robo-Tank Web App - by deeproot - 08-30-2021, 11:32 PM
RE: Robo-Tank Web App - by Rob F - 08-30-2021, 11:58 PM
RE: Robo-Tank Web App - by Weasel1960 - 09-04-2021, 11:40 PM
RE: Robo-Tank Web App - by JFReyes - 08-31-2021, 06:00 AM
RE: Robo-Tank Web App - by Rob F - 08-31-2021, 09:48 AM
RE: Robo-Tank Web App - by coaxman - 08-31-2021, 01:25 PM
RE: Robo-Tank Web App - by Rob F - 08-31-2021, 03:48 PM
RE: Robo-Tank Web App - by deeproot - 08-31-2021, 11:42 PM
RE: Robo-Tank Web App - by Rob F - 09-01-2021, 06:58 AM
RE: Robo-Tank Web App - by Rob F - 09-05-2021, 09:06 AM
RE: Robo-Tank Web App - by Rob F - 09-09-2021, 09:20 PM
RE: Robo-Tank Web App - by Rob F - 09-09-2021, 10:06 PM
RE: Robo-Tank Web App - by coaxman - 09-10-2021, 06:07 PM
RE: Robo-Tank Web App - by Rob F - 09-10-2021, 07:54 PM
RE: Robo-Tank Web App - by Rob F - 09-10-2021, 08:13 PM
RE: Robo-Tank Web App - by Rob F - 09-11-2021, 07:41 PM
RE: Robo-Tank Web App - by Weasel1960 - 09-11-2021, 08:30 PM
RE: Robo-Tank Web App - by Rob F - 09-11-2021, 09:05 PM
RE: Robo-Tank Web App - by Rob F - 09-13-2021, 03:21 PM
RE: Robo-Tank Web App - by albinochicken89 - 09-13-2021, 04:17 PM
RE: Robo-Tank Web App - by Rob F - 09-13-2021, 04:51 PM
RE: Robo-Tank Web App - by pwest - 09-18-2021, 03:10 PM
RE: Robo-Tank Web App - by Rob F - 09-18-2021, 03:35 PM
RE: Robo-Tank Web App - by Rob F - 09-19-2021, 11:40 PM
RE: Robo-Tank Web App - by Brooks - 09-20-2021, 05:15 AM
RE: Robo-Tank Web App - by Dom59 - 09-20-2021, 10:59 AM
RE: Robo-Tank Web App - by Rob F - 09-20-2021, 03:13 PM
RE: Robo-Tank Web App - by Rob F - 09-27-2021, 01:23 AM
RE: Robo-Tank Web App - by Rob F - 09-29-2021, 09:14 PM
RE: Robo-Tank Web App - by fietsenrex - 10-01-2021, 07:18 AM
RE: Robo-Tank Web App - by Brooks - 10-01-2021, 07:22 AM
RE: Robo-Tank Web App - by Rob F - 10-01-2021, 09:40 AM
RE: Robo-Tank Web App - by Rob F - 10-01-2021, 10:29 AM
RE: Robo-Tank Web App - by fietsenrex - 10-01-2021, 10:49 AM
RE: Robo-Tank Web App - by Rob F - 10-01-2021, 11:49 AM
RE: Robo-Tank Web App - by fietsenrex - 10-01-2021, 01:03 PM
RE: Robo-Tank Web App - by Rob F - 10-01-2021, 07:27 PM
RE: Robo-Tank Web App - by Rob F - 10-08-2021, 10:48 AM
RE: Robo-Tank Web App - by albinochicken89 - 10-08-2021, 10:56 AM
RE: Robo-Tank Web App - by Rob F - 10-08-2021, 11:04 AM
RE: Robo-Tank Web App - by Dom59 - 10-08-2021, 12:01 PM
RE: Robo-Tank Web App - Development - by Rob F - 10-09-2021, 12:42 PM
RE: Robo-Tank Web App - Development - by Dom59 - 10-15-2021, 12:26 PM
RE: Robo-Tank Web App - Development - by Rob F - 10-15-2021, 12:33 PM
RE: Robo-Tank Web App - Development - by Dom59 - 10-15-2021, 12:39 PM
RE: Robo-Tank Web App - Development - by Rob F - 10-15-2021, 01:34 PM
RE: Robo-Tank Web App - Development - by Rob F - 12-18-2021, 02:32 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  How to Install Robo-Tank App Rob F 8 2,641 02-04-2024, 06:44 PM
Last Post: Rob F

Forum Jump:

Current time: 04-28-2024, 04:40 AM