Git Product home page Git Product logo

esp-parking-assistant's People

Contributors

resinchem avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

esp-parking-assistant's Issues

Network SSID with special characters won't connect

Ran into issue, network name is NETWORK-2.4G and fails to connect. Using network SSID NETWORK-GUEST and it connects.

I suspect there is a problem handling the "." character in the network name. With tons of devices, changing the network SSID is not possible. Thanks for looking into this

Parking Asst drops wifi

I recently noticed a strange ESP-xxxxxxx hotspot being broadcast, so I connected to it and was surprised to discover it was my Parking Assistant. It's been working fine all along, so I wasn't aware anything was amiss. Nothing I did could connect it back to my IOT wireless network.

I reset all settings and it started broadcasting ESP-ParkAssist. I joined that and reconnected it to my IOT wireless network. It then came up correctly. I added the config (distances/colors) and saved, it's working fine again. I rebooted it a couple times, still good to go.

However, I also want this connected to my Home Assistant, so I input my MQTT broker (IP address, port, username, password, devicename (no special characters just 'parkmazda')) and when it saved/rebooted it dropped off my IOT wireless network again, and started broadcasting the ESP-xxxxxxx hotspot again. When I connect to that hotspot, all the settings are configured, it just will not connect to my IOT wireless network.

I reset all settings again and set it back up without MQTT configured. Not sure if there's a problem with the MQTT or not. I would really like to use the MQTT topics for Home Assistant, so I'm hoping there's something that can help. Not sure if there are logs or anything I can grab to investigate. To be fair, it's never connected to MQTT since I originally built the project, I had given up on it and was reminded again when I noticed it broadcasting the new SSID.

I am running v.44, This is on a D1-Mini (ESP8266).

ESP in AP mode

Why is the esp in AP open wifi mode all the time? Anyone can connect and hack this.

Compille Issue Caused By pixeltypes.h:7,controller.h:9,FastLED.h:57, & noise.cpp:6:

Not sure if it's just me, but I get these compile errors on my Firebeetle 2.

I read something online where people talk about downgrading the board to v2.X because v3.X broke the FastLED compatibility, but curious if anyone else has this issue and/or knows how to fix it.

I tried to just comment out all the FastLED code to see if i could proceed but it's pretty ingrained in this amazing project so I dont want to butcher it

Users/leo/Documents/Arduino/libraries/FastLED/src/noise.cpp: In function 'void fill_raw_2dnoise8(uint8_t*, int, int, uint8_t, q44, fract8, int, uint16_t, int, uint16_t, int, uint16_t)': /Users/leo/Documents/Arduino/libraries/FastLED/src/noise.cpp:623:100: error: ambiguous overload for 'operator*' (operand types are 'q44' {aka 'q<unsigned char, 4, 4>'} and 'int') 623 | fill_raw_2dnoise8(pData, width, height, octaves-1, freq44, amplitude, skip+1, x*freq44, freq44 * scalex, y*freq44, freq44 * scaley, time); | ~~~~~~ ^ ~~~~~~ | | | | | int | q44 {aka q<unsigned char, 4, 4>} In file included from /Users/leo/Documents/Arduino/libraries/FastLED/src/pixeltypes.h:7, from /Users/leo/Documents/Arduino/libraries/FastLED/src/controller.h:9, from /Users/leo/Documents/Arduino/libraries/FastLED/src/FastLED.h:57, from /Users/leo/Documents/Arduino/libraries/FastLED/src/noise.cpp:6: /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:909:14: note: candidate: 'uint32_t q<T, F, I>::operator*(uint32_t) [with T = unsigned char; int F = 4; int I = 4; uint32_t = long unsigned int]' 909 | uint32_t operator*(uint32_t v) { return (v*i) + ((v*f)>>F); } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:911:14: note: candidate: 'uint16_t q<T, F, I>::operator*(uint16_t) [with T = unsigned char; int F = 4; int I = 4; uint16_t = short unsigned int]' 911 | uint16_t operator*(uint16_t v) { return (v*i) + ((v*f)>>F); } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:913:13: note: candidate: 'int32_t q<T, F, I>::operator*(int32_t) [with T = unsigned char; int F = 4; int I = 4; int32_t = long int]' 913 | int32_t operator*(int32_t v) { return (v*i) + ((v*f)>>F); } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:915:13: note: candidate: 'int16_t q<T, F, I>::operator*(int16_t) [with T = unsigned char; int F = 4; int I = 4; int16_t = short int]' 915 | int16_t operator*(int16_t v) { return (v*i) + ((v*f)>>F); } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/noise.cpp:623:127: error: ambiguous overload for 'operator*' (operand types are 'q44' {aka 'q<unsigned char, 4, 4>'} and 'int') 623 | fill_raw_2dnoise8(pData, width, height, octaves-1, freq44, amplitude, skip+1, x*freq44, freq44 * scalex, y*freq44, freq44 * scaley, time); | ~~~~~~ ^ ~~~~~~ | | | | | int | q44 {aka q<unsigned char, 4, 4>} /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:909:14: note: candidate: 'uint32_t q<T, F, I>::operator*(uint32_t) [with T = unsigned char; int F = 4; int I = 4; uint32_t = long unsigned int]' 909 | uint32_t operator*(uint32_t v) { return (v*i) + ((v*f)>>F); } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:911:14: note: candidate: 'uint16_t q<T, F, I>::operator*(uint16_t) [with T = unsigned char; int F = 4; int I = 4; uint16_t = short unsigned int]' 911 | uint16_t operator*(uint16_t v) { return (v*i) + ((v*f)>>F); } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:913:13: note: candidate: 'int32_t q<T, F, I>::operator*(int32_t) [with T = unsigned char; int F = 4; int I = 4; int32_t = long int]' 913 | int32_t operator*(int32_t v) { return (v*i) + ((v*f)>>F); } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:915:13: note: candidate: 'int16_t q<T, F, I>::operator*(int16_t) [with T = unsigned char; int F = 4; int I = 4; int16_t = short int]' 915 | int16_t operator*(int16_t v) { return (v*i) + ((v*f)>>F); } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/noise.cpp: In function 'void fill_raw_2dnoise16(uint16_t*, int, int, uint8_t, q88, fract16, int, uint32_t, int, uint32_t, int, uint32_t)': /Users/leo/Documents/Arduino/libraries/FastLED/src/noise.cpp:661:101: error: ambiguous overload for 'operator*' (operand types are 'int' and 'q88' {aka 'q<short unsigned int, 8, 8>'}) 661 | fill_raw_2dnoise16(pData, width, height, octaves-1, freq88, amplitude, skip, x *freq88 , scalex *freq88, y * freq88, scaley * freq88, time); | ~~~~~~ ^~~~~~~ | | | | int q88 {aka q<short unsigned int, 8, 8>} /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:922:49: note: candidate: 'uint32_t operator*(uint32_t, q<T, F, I>&) [with T = short unsigned int; int F = 8; int I = 8; uint32_t = long unsigned int]' 922 | template<class T, int F, int I> static uint32_t operator*(uint32_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:923:49: note: candidate: 'uint16_t operator*(uint16_t, q<T, F, I>&) [with T = short unsigned int; int F = 8; int I = 8; uint16_t = short unsigned int]' 923 | template<class T, int F, int I> static uint16_t operator*(uint16_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:924:48: note: candidate: 'int32_t operator*(int32_t, q<T, F, I>&) [with T = short unsigned int; int F = 8; int I = 8; int32_t = long int]' 924 | template<class T, int F, int I> static int32_t operator*(int32_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:925:48: note: candidate: 'int16_t operator*(int16_t, q<T, F, I>&) [with T = short unsigned int; int F = 8; int I = 8; int16_t = short int]' 925 | template<class T, int F, int I> static int16_t operator*(int16_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/noise.cpp:661:129: error: ambiguous overload for 'operator*' (operand types are 'int' and 'q88' {aka 'q<short unsigned int, 8, 8>'}) 661 | fill_raw_2dnoise16(pData, width, height, octaves-1, freq88, amplitude, skip, x *freq88 , scalex *freq88, y * freq88, scaley * freq88, time); | ~~~~~~ ^ ~~~~~~ | | | | int q88 {aka q<short unsigned int, 8, 8>} /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:922:49: note: candidate: 'uint32_t operator*(uint32_t, q<T, F, I>&) [with T = short unsigned int; int F = 8; int I = 8; uint32_t = long unsigned int]' 922 | template<class T, int F, int I> static uint32_t operator*(uint32_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:923:49: note: candidate: 'uint16_t operator*(uint16_t, q<T, F, I>&) [with T = short unsigned int; int F = 8; int I = 8; uint16_t = short unsigned int]' 923 | template<class T, int F, int I> static uint16_t operator*(uint16_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:924:48: note: candidate: 'int32_t operator*(int32_t, q<T, F, I>&) [with T = short unsigned int; int F = 8; int I = 8; int32_t = long int]' 924 | template<class T, int F, int I> static int32_t operator*(int32_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:925:48: note: candidate: 'int16_t operator*(int16_t, q<T, F, I>&) [with T = short unsigned int; int F = 8; int I = 8; int16_t = short int]' 925 | template<class T, int F, int I> static int16_t operator*(int16_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/noise.cpp: In function 'void fill_raw_2dnoise16into8(uint8_t*, int, int, uint8_t, q44, fract8, int, uint32_t, int, uint32_t, int, uint32_t)': /Users/leo/Documents/Arduino/libraries/FastLED/src/noise.cpp:699:106: error: ambiguous overload for 'operator*' (operand types are 'int' and 'q44' {aka 'q<unsigned char, 4, 4>'}) 699 | fill_raw_2dnoise16into8(pData, width, height, octaves-1, freq44, amplitude, skip+1, x*freq44, scalex *freq44, y*freq44, scaley * freq44, time); | ~~~~~~ ^~~~~~~ | | | | int q44 {aka q<unsigned char, 4, 4>} /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:922:49: note: candidate: 'uint32_t operator*(uint32_t, q<T, F, I>&) [with T = unsigned char; int F = 4; int I = 4; uint32_t = long unsigned int]' 922 | template<class T, int F, int I> static uint32_t operator*(uint32_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:923:49: note: candidate: 'uint16_t operator*(uint16_t, q<T, F, I>&) [with T = unsigned char; int F = 4; int I = 4; uint16_t = short unsigned int]' 923 | template<class T, int F, int I> static uint16_t operator*(uint16_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:924:48: note: candidate: 'int32_t operator*(int32_t, q<T, F, I>&) [with T = unsigned char; int F = 4; int I = 4; int32_t = long int]' 924 | template<class T, int F, int I> static int32_t operator*(int32_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:925:48: note: candidate: 'int16_t operator*(int16_t, q<T, F, I>&) [with T = unsigned char; int F = 4; int I = 4; int16_t = short int]' 925 | template<class T, int F, int I> static int16_t operator*(int16_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/noise.cpp:699:132: error: ambiguous overload for 'operator*' (operand types are 'int' and 'q44' {aka 'q<unsigned char, 4, 4>'}) 699 | fill_raw_2dnoise16into8(pData, width, height, octaves-1, freq44, amplitude, skip+1, x*freq44, scalex *freq44, y*freq44, scaley * freq44, time); | ~~~~~~ ^ ~~~~~~ | | | | int q44 {aka q<unsigned char, 4, 4>} /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:922:49: note: candidate: 'uint32_t operator*(uint32_t, q<T, F, I>&) [with T = unsigned char; int F = 4; int I = 4; uint32_t = long unsigned int]' 922 | template<class T, int F, int I> static uint32_t operator*(uint32_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:923:49: note: candidate: 'uint16_t operator*(uint16_t, q<T, F, I>&) [with T = unsigned char; int F = 4; int I = 4; uint16_t = short unsigned int]' 923 | template<class T, int F, int I> static uint16_t operator*(uint16_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:924:48: note: candidate: 'int32_t operator*(int32_t, q<T, F, I>&) [with T = unsigned char; int F = 4; int I = 4; int32_t = long int]' 924 | template<class T, int F, int I> static int32_t operator*(int32_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/lib8tion.h:925:48: note: candidate: 'int16_t operator*(int16_t, q<T, F, I>&) [with T = unsigned char; int F = 4; int I = 4; int16_t = short int]' 925 | template<class T, int F, int I> static int16_t operator*(int16_t v, q<T,F,I> & q) { return q * v; } | ^~~~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/platforms/esp/32/clockless_rmt_esp32.cpp: In member function 'void ESP32RMTController::startOnChannel(int)': /Users/leo/Documents/Arduino/libraries/FastLED/src/platforms/esp/32/clockless_rmt_esp32.cpp:266:29: error: 'RMTMEM' was not declared in this scope 266 | mRMT_mem_start = & (RMTMEM.chan[mRMT_channel].data32[0].val); | ^~~~~~ /Users/leo/Documents/Arduino/libraries/FastLED/src/platforms/esp/32/clockless_rmt_esp32.cpp: In static member function 'static void ESP32RMTController::doneOnChannel(rmt_channel_t, void*)': /Users/leo/Documents/Arduino/libraries/FastLED/src/platforms/esp/32/clockless_rmt_esp32.cpp:347:5: error: 'gpio_matrix_out' was not declared in this scope; did you mean 'gpio_iomux_out'? 347 | gpio_matrix_out(pController->mPin, 0x100, 0, 0); | ^~~~~~~~~~~~~~~ | gpio_iomux_out

Potential Boot Loop

I flashed the firmware on an ESP8266 D1 mini and an ESP8266 NodeMCU. I was able to access the web UI, but after entering my wifi information and LED numbers the device never allows me to access the web UI again. Nmap showed port 80 open and when I power cycle the device the flashing blue light never stops. Below is the output from the device:

[08:03:00] ets Jan  8 2013,rst cause:1, boot mode:(3,0)
[08:03:00]
[08:03:00]load 0x4010f000, len 3584, room 16 
[08:03:00]tail 0
[08:03:00]chksum 0xb0
[08:03:00]csum 0xb0
[08:03:00]v2843a5ac
[08:03:00]~ld
[08:03:00]
[08:03:00] ets Jan  8 2013,rst cause:1, boot mode:(3,0)
[08:03:00]
[08:03:00]load 0x4010f000, len 3584, room 16 
[08:03:00]tail 0
[08:03:00]chksum 0xb0
[08:03:00]csum 0xb0
[08:03:00]v2843a5ac
[08:03:00]~ld
[08:03:00]
[08:03:00] ets Jan  8 2013,rst cause:1, boot mode:(3,0)
[08:03:00]
[08:03:00]load 0x4010f000, len 3584, room 16 
[08:03:00]tail 0
[08:03:00]chksum 0xb0
[08:03:00]csum 0xb0
[08:03:00]v2843a5ac
[08:03:00]~ld
[08:03:01]
[08:03:01] ets Jan  8 2013,rst cause:1, boot mode:(3,0)
[08:03:01]
[08:03:01]load 0x4010f000, len 3584, room 16 
[08:03:01]tail 0
[08:03:01]chksum 0xb0
[08:03:01]csum 0xb0
[08:03:01]v2843a5ac
[08:03:01]~ld
[08:03:01]
[08:03:01] ets Jan  8 2013,rst cause:1, boot mode:(3,0)
[08:03:01]
[08:03:01]load 0x4010f000, len 3584, room 16 
[08:03:01]tail 0
[08:03:01]chksum 0xb0
[08:03:01]csum 0xb0
[08:03:01]v2843a5ac
[08:03:01]~ld

no distance measurement

Hi thank you for your great project. I have a test build with a wemos d1 mini but the led strip is not leaving stand by mode. I tested changing the parking distances but no difference. In mqtt there is always "cardetected = 0", "parkdistance = 5080.0" . I tested my tfmini-s with another esp32 and that code (https://github.com/ibrahimqazi/TFmini-S-interfacing-with-ESP32) and I get good readings. How can I debug it and check if the tfmini is detected?

[Feature Request] Side to Side Indicator

I’d like to be able to add an additional sensor on the side of the garage so that in a two-car garage. This makes sure the vehicle doesn't take up the other car's space and is not too close to the wall where it's difficult to open the door.

I think it should have an animation with multiple segments going in the direction that you want the vehicle to move in, would be ideal, kind of like the gif below. Once the vehicle is in the correct x-axis position, it resumes the regular distance indication.

4BAD0E9C-35A4-4ABD-A4B6-084C7F07CE20

LEDs will not respond

So I followed @Resinchem video, instructions used the items from his list to build the board, Board powers, may not be an issue but the board led only flashes once on boot and does not remain on, but the software flashed fine, I can see the tf mini is powered as I see the red lights inside it, I am connected to my wifi even though the SSID is long ( im-under-your-bed) I see the parkasst on my network, I can go to the set up page and get no errors when saving options, I have tested and they are getting 5v. But not matter what I do I can not get any leds ( Im using 30 leds) to work? Any clue what may be going on and or any help is appreciated. Iattached pic of the board if that helps
PXL_20230102_195942915
PXL_20230102_200020800

MQTT User and Password Fields Limited to 30 characters each

I think the MQTT password field may be truncating my password. I don't see anything in the code that would indicate that, and I know Arduino code can handle this length password (64 chars, letters & numbers only, no special chars). I have another device early in my days of home automation where I built a temperature sensor that was pure MQTT, with the same password and it connects fine and still actively reports.

The Home Assistant MQTT Broker (Mosquitto) is reporting parkasst is not authorized. I have double checked the password (it's copy/pasted so I know there's no typos. It is a pretty long password, so maybe the textbox is truncating it?

2023-11-17 14:17:13: New connection from 10.42.100.113:52214 on port 1883.
2023-11-17 14:17:13: Client parkasst disconnected, not authorised.

Pins for HC-SR04 without logic level shifter

I have a D1 Mini, LED strip and HC-SR04. I want to make sure I am using the correct pins on the D1 Mini. What pins would you recommend without the logic level shifter? Will everything still work without it?

More than one device publishes to the same MQTT topic

Due to the hardcoded MQTT topic in the code, installing more than one instance of the parking assistant with MQTT enabled will cause the two devices to overwrite each other in MQTT.

Currently the only fix for this issue if two or more devices are going to enable and use MQTT is to edit the source .ino file and update this line: #define MQTT_TOPIC_PUB "stat/parkasst" giving each device a unique topic (such as /parkasst1 and /partasst2).

If you are not using MQTT or only have MQTT enabled for one device, this does not impact normal operations.

Code does not work with newest version of TFMini-s

Others have reported, and I now have confirmed, that a newer version of the TFMini is being sold. Currently, the code does not work correctly with the newer sensor.

TFMini_Vers_Annotated

If your TFMini-s lists v1.8.1 on the back as shown above, you can build the system as described. Hook up the new TFMini and you can access the web app and the controller will go through the normal boot sequence (all blue lights, followed by red & green lights), but then goes into standby mode and does not respond to objects in front of the sensor.

I am working on a fix and will release a new version of the firmware that works with the newer sensor as soon I have developed and tested it. If you have the older v1.7 TFMini, the current code should function normally and as expected.

Power problem with my build

1st off Thanks for this build lesson. This is my 1st Arduino project and it has been a nice project with great instructions.

I have built the unit just like you said with the parts you suggested. I am having one problem and haven't figured out what is causing it. When I boot it up on the power supply it generally does not do anything, I checked voltages on both sides and they right in line. After testing numerous times it came on and worked fine but after disconnecting power and trying again I couldn't get it to work again. The light blinks but occasionally and random amounts from what I can tell. I looked the board over with a scope and don't see any issues but not sure what is causing the problem. Then when I was testing trying to figure it out I disconnected the power supply and connected it to a battery pack with a micro USB and it came on and worked, every time I tried it? I then tried back and forth between the 2 different power sources and one more time it worked on the power supply after about a minute or so but most of the time it doesn't. I checked voltages on both rails on both power supplies and they are very similar 3.3 and 5, I also took voltage readings on the logic level shifter and most seemed good but on LU4 when on the battery source I get 0.25 to 0.65 V and when on the wall power supply it gives me about 3.3 V, I tried many times and it is basically the same. When the unit did work on the wall power supply the voltage was low like on the battery. I tried moving things around and looking deeper with the digital scope but can't fine the problem. Any help is appreciated and being new I am sure some of this could have been said better. I will attach pictures of the board connections. Thanks, Tim
20240206_202206
20240206_202146

Upgrade from .42 to .43 lost all settings

This is mostly just for a heads up. I upgraded from .42 (original install) to .43 and all settings were lost. I had to re-set up the wifi access, LED count, distances, etc.

Not sure if there were any other similar reported issues. I wanted to log this because the notes said I should not have lost my settings.

Troubleshooting

Are there any troubleshooting or debugging logs? I'm having trouble getting this to work. I had it set up and working on a breadboard, but after assembling, it no longer works. I have triple checked everything, voltages all read correct, however the LEDs are not illuminating. LEDs have power down to the end of the strip, I have tested them on a WLED controller and the LEDs are fine.

I also noticed the logic level shifter outputs 3.3v on the data line when the LEDs are connected and 5v when the LEDs are not connected.

I know I need to disconnect the TFmini to read data out of the USB port, but the serial monitor in the Arduino IDE just shows gibberish:
09:51:23.612 -> �rll�r�$��n � l� b|������r�b� b��nn�lnn2b b�p�$b�lrlp�n�� � l �� b n�n�l� �b��nn'l��l����nn l���nr���n b�l��r��n b�l��b �l�lr�`���nb

Incompatibility with some NodeMCU boards

There seems to be incompatibilities with some NodeMCU boards. While some appear to work fine, others do not. Some boards will broadcast the hotspot and appear to onboard, but then fail to respond. Other boards simply do nothing, while others function normally (based on received reports). The latest release (v0.42) attempts to improve functionality with generic ESP8266 boards, but acquiring and testing every board out there simply isn't feasible.

For now, it is highly recommended to use a Wemos D1 Mini board for the best results and compatibility. The firmware was developed and fully tested on this board and multiple people have reported success using this board.

While I will do my best to assist, I may simply be unable to help with errors on boards other than the D1 Mini. The code compiles fine for generic ESP8266 and the D1 Mini at this point.

If anyone is willing to assist and find anything in the code that is resulting in incompatibility issues, I would welcome the help in making the code available to a wider range of ESP8266 boards.

MQTT

Hello,
thanks for this great idea and development.

I want to know if its possible to get more datapoints on mqtt? I need the state of the leds and the distance. So it would be possible to generate an "live" view.

Would it be possible to update the firmware with wifi?

Thank you very much!

Board may boot loop if restarted before settings are saved

In some cases, if you reboot the controller after onboarding to wifi, but before going to the web app and saving settings as new boot default, it can cause the board to enter a boot loop. If this occurs, it will be necessary to re-flash the firmware via USB. A fix is in currently in progress.

In the meantime, just assure that immediately after onboarding your device to wifi you go to the web app and enter some starting values and check the box to save the settings as boot defaults and update.

image

This will create the initial configuration file and prevent the boot loop from possibly occurring. You can return to the web app and make as many additional changes as you like... just as long as an initial file is created before the first reboot of the device.

Problems Flashing

Hi, thanks so much for your write up and code. However I am having issues flashing my D1 mini with the .ino you have. Would you have the .bin file?

I tried to flash my board in NodeMCU Flasher but it doesn't seem to flash the board properly:
Auto-detected Flash size: 4MB
Erasing flash (this may take a while)...
Chip erase completed successfully in 2.2s
Warning: Image file at 0x0 doesn't look like an image file, so not changing any flash settings.
Compressed 54360 bytes to 13659...
Wrote 54360 bytes (13659 compressed) at 0x00000000 in 1.3 seconds (effective 328.2 kbit/s)...
Hash of data verified.

Leaving...
Staying in bootloader.

Firmware successfully flashed. Unplug/replug or reset device
to switch back to normal boot mode.

and then I tried to flash in ESPHOME Flasher but that wont flash at all, it gives me errors.

Thank you again

Firmware does not work with newer D1-Mini v4 with USB-C

It has been confirmed that the current firmware does not function properly with the newer v4 D1-mini with the USB-C connection:

image

The v4 board will broadcast the ESP-ParkAsst hotspot, successfully join wifi and the LEDs will show a normal boot sequence. The web settings page will be accessible and can be updated with new settings. But the system will go into sleep mode and will not respond to changes or distance measurements from the sensor.

Until this issue is addressed and a new firmware version released, you must use the D1-Mini v3 with the micro USB connection for the system to function.

Support HC-SR04

I understand that this sensor is worse. But I would still really like to see support for this module in your firmware.
Thanks.

MQTT message after LED change

Hi, thanks for the great project. Its working great, but now to my issue. I bought an old traffic light and wanted to sync it with the parking assistant. I changed the code for my needs but when I compile the esp8266 (d1 mini) is behaving very slow with slow led and website response, even when I test compile with the original source code. Tried with different arduino ide and library versions but had no luck. Setting MQTT off for testing doesn't change the behavior. The precompiled version is working normal.
I changed only the Update LEDs part and inserted a new global variable.

// Global variable
String prevLEDStatus = "";

// Update LEDs
if ((carDetected) && (isAwake)) {
    String currentLEDStatus = "";  // Variable to store the current LED status

    if (tf_dist <= backupDistance) {
        // Beyond minimum distance - flash backup!
        blinkLEDs(ledColorBackup);
        currentLEDStatus = "backup";

    } else if (tf_dist <= parkDistance) {  
        // In desired parked distance
        fill_solid(LEDs, numLEDs, ledColorParked);
        currentLEDStatus = "parked";

    } else if ((tf_dist > startDistance) && (tf_dist <= wakeDistance)) {
        // Beyond start distance but within wake distance
        fill_solid(LEDs, numLEDs, ledColorWake);
        currentLEDStatus = "wake";

    } else if ((tf_dist <= startDistance) && (tf_dist > parkDistance)) {
        // Update based on selected effect
        if (ledEffect_m1 == "Out-In") {
            updateOutIn(tf_dist);
        } else if (ledEffect_m1 == "In-Out") {
            updateInOut(tf_dist);
        } else if (ledEffect_m1 == "Full-Strip") {
            updateFullStrip(tf_dist);
        } else if (ledEffect_m1 == "Full-Strip-Inv") {
            updateFullStripInv(tf_dist);
        } else if (ledEffect_m1 == "Solid") {
            updateSolid(tf_dist);
        }
        currentLEDStatus = "start";
    }

    // Check if the LED status has changed
    if (currentLEDStatus != prevLEDStatus) {
        // If the MQTT client is connected, publish the LED status
        if (client.connected()) {
            String topic = "parkingAssistant/" + mqttTopicPub + "/led_status";
            client.publish(topic.c_str(), currentLEDStatus.c_str());
        }
        // Update the previous LED status with the current status
        prevLEDStatus = currentLEDStatus;
    }
}

Has anyone else faced a similar issue or have any insights on what might be causing the slowdown? Any help would be greatly appreciated.

Thank you!

Installing multiple devices on same network may cause issues

Attempting to install a second (or third) parking assistant on the same network may cause unforeseen issues. This is due to some hardcoded information related to wifi, OTA updates and MQTT. For example, a second device will attempt to join your wifi network using the same hostname. This may or may not cause issues depending upon your particular setup.

In addition, multiple devices with the same MQTT name and topic will overwrite each other's data if MQTT is enabled on more than one device. Until a fix is released, you may use the following workaround for additional devices. You will need to download and modify the existing parking_assistant.ino and edit with the Arduino IDE or other compatible editor for this fix.

You must make these changes and upload to the controller before the first-time onboarding process! Some of these values are used during the initial process where you onboard the controller to your wifi. If you have already onboarded your controller, you will need to perform a full reset and then load the firmware with the changes listed below.

You do not need to reset or make these changes to your initial or first parking assistant! These changes ONLY need to be made to any subsequent controllers added after the first one.

At the top of the source code file, locate the following #define statements:

#define WIFIHOSTNAME "ESP_ParkAsst"         // Host name for WiFi/Router
#define MQTTCLIENT "parkasst"               // MQTT Client Name
#define OTA_HOSTNAME "ParkAssistOTA"        // Hostname to broadcast as port in the IDE of OTA Updates
#define MQTT_TOPIC_SUB "cmnd/parkasst"      // Default MQTT subscribe topic
#define MQTT_TOPIC_PUB "stat/parkasst"      // Default MQTT publish topic

Edit each line to make each value unique. For example, just add a numeric value for each new device:

#define WIFIHOSTNAME "ESP_ParkAsst2"         // Host name for WiFi/Router
#define MQTTCLIENT "parkasst2"               // MQTT Client Name
#define OTA_HOSTNAME "ParkAssistOTA2"        // Hostname to broadcast as port in the IDE of OTA Updates
#define MQTT_TOPIC_SUB "cmnd/parkasst2"      // Default MQTT subscribe topic
#define MQTT_TOPIC_PUB "stat/parkasst2"      // Default MQTT publish topic

Save the changes. You may then either create a new .bin file and upload to the controller following the wiki information Initial Installation or uploaded directly from the Arduino IDE via USB cable.

Note that if a new firmware version is released before one containing a fix for this issue, you will need to complete the above steps again using the new .ino version. It is hoped a fix for this issue will be released soon.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.