Downloaded new 2.0 version and now code going haywire
eagletalontim
Posts: 1,399
I have been using version 3.2.92h for a long time and have built a project that uses 2 chips that talk to each other. One reads sensors and does calculations, the other runs the LCD display and Reads / Writes to an EEprom. After downloading the 2.0 compiler, I programmed both chips again with the EXACT same code and now nothing loads from the EEprom and it appears as though sometimes the code jumps to random spots and runs them which throws garbage on the LCD. I just tried downloading the old version again, but apparently it has been upgraded as well with the new compiler. I cannot post my code because it is a major project I am working on to be able to sell in the future, but I may be able to post parts of it if needed. Please let me know what I should do!
Comments
What you don't seem to be clear on is that SX/B is called form the IDE; it's not part of it. This lets us upgrade/downgrade SX/B by simply changing the files in the SXB folder. I actually have batch files that allow me to go back and forth between 1.51.03 and 2.00.xx for situations like yours where the compiler changes affect the code; they're usually minor but we'll never know with your program as you can't post it.
@Tim: You could bump to the SX28 and get more code space and RAM. You might even find a clever way to use the counter/timers for you tach input.
a multiply and divide routine can save a lot of codespace.
Also, putting SXB commands that generate lots of code
(not just serin, serout and pause) in a seperate routine
will help.
Using manual banking can also save alot of codespace.
Or move to the sx48 as Jon suggested (as you have
ran out of variable space as well).
regards peter
To get to the first character in a string you multiply your block size by the string number. You then read characters out of the EEPROM until you hit a zero.