1.5.8 issues that 1.0.6 doesn't have. Need solutions

I have noticed several bugs in the 1.5.8 IDE that I would like resolved. I can explain all the issues using the code in the attachment

Bug 1: If you uncomment the part Read Temperature

void loop()
{
//Check Light Level
int light_level = analogRead(light_pin);
/*
//Read Temperature
Wire.beginTransmission(temp_address); //Start talking
Wire.send(0); //Ask for Register zero
Wire.endTransmission(); //Complete Transmission
Wire.requestFrom(temp_address, 1); //Request 1 Byte
while(Wire.available() == 0); //wait for response
int temp_c = Wire.receive(); // Get the temp
int temp_f = round(temp_c*9.0/5.0 +32.0); //Convert to stupid American units
*/

using the 1.0.6 IDE you will get the following error message when you try to compile.

//Read Distancesdatalogger:99: error: ‘class TwoWire’ has no member named ‘send’

As of Arduino 1.0, the Wire.send() function was renamed to Wire.write() for consistency with other libraries.

datalogger:103: error: ‘class TwoWire’ has no member named ‘receive’

As of Arduino 1.0, the Wire.receive() function was renamed to Wire.read() for consistency with other libraries.

this is great because it tells you what was changed that you need to address, and why. If you do the same using 1.5.8 IDE you will get the following error message when you try to compile

Build options changed, rebuilding all

datalogger.pde: In function ‘void loop()’:
datalogger.pde:99:8: error: ‘class TwoWire’ has no member named ‘send’
datalogger.pde:103:21: error: ‘class TwoWire’ has no member named ‘receive’
Error compiling.

As you can see, it doesn’t say anything about what to rename the class to, or explain why it works on old examples explained in great detail on youtube, but does not work when trying to implement them. To any new programmer like myself, the 1.0.6 diagnostic which explains this is greatly appreciated.

Bug2: Using the code in attachment"as is" the 1.0.6 IDE will compile the code, and everything will load and work perfectly. Using this exact code on the 1.5.8 IDE the following error message is displayed

C:\Users\ThomasRiley\Desktop\arduino-1.5.8-windows\arduino-1.5.8\libraries\SD\src\utility\Sd2Card.cpp:26:17: fatal error: SPI.h: No such file or directory
#include <SPI.h>
^
compilation terminated.
Error compiling.

Which I can not for the life of me understand. If I only need two libraries using 1.0.6 why would I need to add the SPI.h library using the 1.5.8 for the same code to work?

Bug3: If you have two unos, load code to uno1, unplug it, plug uno2 in and click upload, 1.0.6 will automatically have a window pop up explaining uno1 was not found, with an option to use uno2 instead. In 1.5.8 however, no pop up window will come up, and the error message will only say

avrdude: ser_open(): can’t open device “\.\COM7”: The system cannot find the file specified.

avrdude: ser_drain(): read error: The handle is invalid.

Problem uploading to board. See http://www.arduino.cc/en/Guide/Troubleshooting#upload for suggestions.

which isn’t very clear explaining the problem. Even if you google the troubleshooting link you will spend much time trying to figure out what is going on.

Is it possible to use files from the 1.0.6 IDE and transfer them to the 1.5.8 IDE so that the IDE uses the same programming that addresses these issues? If not, can someone tell me why I need more libraries using the 1.5.8 that I described in bug2? I need 1.5.8 because I need to be able to scroll to see all my library examples, but I don’t want forfeit all the advantages of using the older 1.0.6 IDE.

datalogger2.ino (3.13 KB)

Full marks for documenting these issues. But don't hold your breath. I have never seen any evidence that the Arduino developers read anything on this Forum.

...R

Thomas499: I need 1.5.8 because I need to be able to scroll to see all my library examples, but I don't want forfeit all the advantages of using the older 1.0.6 IDE.

If you just need the scrolling feature, check out eried's enhanced version of 1.0.5:

http://forum.arduino.cc/index.php?topic=118440.0

(The scrolling feature in 1.5.8 was contributed by eried from this code anyway, as I understand it.)

Thomas499: Is it possible to use files from the 1.0.6 IDE and transfer them to the 1.5.8 IDE so that the IDE uses the same programming that addresses these issues?

Not as such, but it should be possible to modify 1.5.8 to give similar behaviour.

If not, can someone tell me why I need more libraries using the 1.5.8 that I described in bug2? I need 1.5.8 because I need to be able to scroll to see all my library examples, but I don't want forfeit all the advantages of using the older 1.0.6 IDE.

In 1.0.6, the SD library has its own routines for handling SPI, in 1.5.8 the SPI routines now have their own library.

There are a lot of code changes and new functionality between 1.0.6 and 1.5.8, so I wouldn't expect it to behave exactly the same.

You can also use my Teensyduino installer to add the scrolling menus and other improvements to the 1.0.6 IDE.

Full marks for documenting these issues. But don't hold your breath. I have never seen any evidence that the Arduino developers read anything on this Forum.

...R

I'm not sure if a Forum Administrator and a Developer is the same thing, but if it is I did find evidence. Post #1 #4 & #7 Now this person only has a a little over 4,000 post and the one I found was from 2008, so maybe they decided to change their policy. I just thought i'd share that.

Thomas499: I'm not sure if a Forum Administrator and a Developer is the same thing, but if it is I did find evidence. Post #1 #4 & #7 Now this person only has a a little over 4,000 post and the one I found was from 2008, so maybe they decided to change their policy. I just thought i'd share that.

Things like this need to be mentioned on GitHub. I know many of you are reluctant to use it, however its your best shot, or at least a combination of the forum and GitHub.

Even then, it still takes time. It took 6 months to fix a serious logic issue I brought up: Drop the boolean data type, its broken. (or fix it)

Change Log

And now the change has even made its way into custom cores/IDE's like the Teensy project.

pYro_65: And now the change has even made its way into custom cores/IDE's like the Teensy project.

I'd just like to say, if anyone reading this does find a bug impacting anything on Teensy, please do report it on the forum for Teensy:

https://forum.pjrc.com/forums/4-Suggestions-amp-Bug-Reports

I absolutely do monitor that forum. I try to keep an eye on this one and a few others too, but I can't catch everything everywhere.

Many times I've developed fixes for bugs on Teensy, which later get incorporated back into Arduino. String, AVR malloc, & SPI transactions would be a few notable ones.

I do maintain a written list of reported issues, across many sites, and many libraries and projects. Sometimes it takes me months to really investigate, but I do eventually follow up and fix stuff. Please, if you find bugs, report them somewhere I can see.