Quantcast
Channel: MCS Electronics Forum
Viewing all articles
Browse latest Browse all 20558

BASCOM-AVR : Chip Hangs : NEWTOPIC

$
0
0
Hello, I have made about 200 boards with some code communicating via rs485 to another board and generally never had any of my atmega32 freeze. Just in the last 3 days 3 units froze on me. There was a code change that I am sort of focusing on since nothing else in my system really changed. The code I added was to obtain a water depth to 1 decimal point, so I am dividing a number which should have a decimal place in it, and then trimming it down to 1 decimal place precision. The code I added if I cut the rest out was: Depth_single = Depth / 10 'convert 10cm increments of depth to meters with one decimal place. Depth_string = Fusing(depth_single , "#.#") I should note that I remember when I added this I didn't start with the fusing line since I thought the math would not allow any more then one decimal, but when the values were computed they were more then one decimal. The variable Depth come via rs485 from the other chip and is an integer value between -5 and 1000. My thought was any of these /10 would not be more then 1 decimal place. in fact they were, and the fusing fixed it. Not sure if that is related but worth mentioning. The other note is prior to this change by flash capacity was 95% and with this change it is 99%. Can running too close to 100$ hang a chip? Can the stacks hang a chip? Thanks in advance for any input. J [b:a7d999655d][color=red:a7d999655d](BASCOM-AVR version : 1.11.9.5 , Latest : 2.0.7.6 )[/b:a7d999655d][/color:a7d999655d]

Viewing all articles
Browse latest Browse all 20558

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>