Hi
Sorry, I'm a bit out of the loop due to travel. A couple of months ago I was playing with one of these and got good repeatable results (all hail Martin) with a PIC. I think Martin also assisted with an ESP32 too.
Not had a chance to get back into my evil lab yet, but I think I still have my test setup that supported the sensor still assembled. I have both Uno and ESP32 so can try them when I get a chance. Not sure when that will be though but hopefully soon.
Regards
HC-SR04 not working with ""Pic"" Anymore
-
- Valued Contributor
- Posts: 1685
- http://meble-kuchenne.info.pl
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 374 times
- Been thanked: 583 times
-
- Posts: 74
- Joined: Thu Jun 16, 2022 6:16 pm
- Has thanked: 118 times
- Been thanked: 13 times
Re: HC-SR04 not working with ""Pic"" Anymore
Hi
lain and Jorgen
I am having problem with the Map Function, it's not working, but before the summer it uses to work.
May be its the type of Chip am using
I only use my laptop just for FC v10 ONLY
I don't want to think this way.
but I am starting to wonder if something is wrong with my new win 11, I DONT USE FLASH DRIVE IN IT. wondering if it contracts some sort of virus Sunday gone. it was showing values in the morning. Then it just Stop.
I went back to my old program it works. but not working with the Latest one.
AM going to try back the esp32 and the wats the result.
regards
ryan
lain and Jorgen
I am having problem with the Map Function, it's not working, but before the summer it uses to work.
May be its the type of Chip am using
I only use my laptop just for FC v10 ONLY
I don't want to think this way.
but I am starting to wonder if something is wrong with my new win 11, I DONT USE FLASH DRIVE IN IT. wondering if it contracts some sort of virus Sunday gone. it was showing values in the morning. Then it just Stop.
I went back to my old program it works. but not working with the Latest one.
AM going to try back the esp32 and the wats the result.
regards
ryan
-
- Valued Contributor
- Posts: 1685
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 374 times
- Been thanked: 583 times
Re: HC-SR04 not working with ""Pic"" Anymore
Hi Ryan
Many free Anti-Virus solutions out there including Windows Defender so it is worth installing something.
Unlikely that the FC issues are related though.
You can test the Map functionality by just assigning variables in a calculation and viewing the results in Simulation Debugger or on a display.
Regards
Many free Anti-Virus solutions out there including Windows Defender so it is worth installing something.
Unlikely that the FC issues are related though.
You can test the Map functionality by just assigning variables in a calculation and viewing the results in Simulation Debugger or on a display.
Regards
-
- Posts: 74
- Joined: Thu Jun 16, 2022 6:16 pm
- Has thanked: 118 times
- Been thanked: 13 times
Re: HC-SR04 not working with ""Pic"" Anymore
Hi
I did Scan it with Win Defender, there's nothing there. it shouldn't be any virus thou.
>>I had no luck with the esp32
I simulated the OLD Project with the "MAP FUNCTION" and it work using the Pic16F877A.
I had an old example with the Map function using PWM as well and it responded too
Just confirm to I created a NEW Project with the HC-SR04, and Pic16f877a It work, showing its value, IMPRESSIVE READINGs
>> Still not showing values with the smaller uC "Pic18f1320" anymore Not sure why thou.
>> also trying using the "Map function" with the new project I just created. Map function Didn't response.
regards
I did Scan it with Win Defender, there's nothing there. it shouldn't be any virus thou.
>>I had no luck with the esp32
I simulated the OLD Project with the "MAP FUNCTION" and it work using the Pic16F877A.
I had an old example with the Map function using PWM as well and it responded too
Just confirm to I created a NEW Project with the HC-SR04, and Pic16f877a It work, showing its value, IMPRESSIVE READINGs
>> Still not showing values with the smaller uC "Pic18f1320" anymore Not sure why thou.
>> also trying using the "Map function" with the new project I just created. Map function Didn't response.
regards
- Attachments
-
- v10 877A.jpg (164.37 KiB) Viewed 4811 times
-
- Posts: 74
- Joined: Thu Jun 16, 2022 6:16 pm
- Has thanked: 118 times
- Been thanked: 13 times
Re: HC-SR04 Return 9999
Hi
Can anyone check and tell me if the Sr04 components Is Working?
Mine is returning 9999 Now.
Thanks again.
regards
Can anyone check and tell me if the Sr04 components Is Working?
Mine is returning 9999 Now.
Thanks again.
regards
- Attachments
-
- 20241004_104333.jpg (63.08 KiB) Viewed 3425 times
-
- Valued Contributor
- Posts: 1685
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 374 times
- Been thanked: 583 times
Re: HC-SR04 not working with ""Pic"" Anymore
Hi
A few months back I did some experimentation with these with good results.
Not sure if anything changed component wise since then.
If you could share your chart we can look and see if anything is astray.
Sorry, can't access hardware to check things but can maybe assist otherwise.
Regards
A few months back I did some experimentation with these with good results.
Not sure if anything changed component wise since then.
If you could share your chart we can look and see if anything is astray.
Sorry, can't access hardware to check things but can maybe assist otherwise.
Regards
-
- Posts: 74
- Joined: Thu Jun 16, 2022 6:16 pm
- Has thanked: 118 times
- Been thanked: 13 times
Re: HC-SR04 not working with ""Pic"" Anymore
Hi
It's the same one. That I have been using earlier when it used to work.
Now am back to it and its returns 9999
regards
It's the same one. That I have been using earlier when it used to work.
Now am back to it and its returns 9999
regards
- Attachments
-
- Pic18f1320_SR04.fcfx
- (12.05 KiB) Downloaded 151 times
-
- Valued Contributor
- Posts: 1685
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 374 times
- Been thanked: 583 times
-
- Posts: 21
- Joined: Thu Nov 02, 2023 8:11 am
Re: HC-SR04 not working with ""Pic"" Anymore
There is a problem. The HC-SR04 is completely problem-free in V8. There have been problems with the V10. Does not work in proteus simulation.
-
- Valued Contributor
- Posts: 1685
- Joined: Thu Dec 03, 2020 10:57 am
- Has thanked: 374 times
- Been thanked: 583 times
Re: HC-SR04 not working with ""Pic"" Anymore
Hi
The component seems to work OK in hardware on many different chips, as per forum posts with FCv10 creating the code. If Proteus has an issue would it not be better to ask Proteus why they cannot handle the code? Perhaps send them the C/Hex files you created for them to analyse why they can't simulate?
Regards
The component seems to work OK in hardware on many different chips, as per forum posts with FCv10 creating the code. If Proteus has an issue would it not be better to ask Proteus why they cannot handle the code? Perhaps send them the C/Hex files you created for them to analyse why they can't simulate?
Regards