Hey all,
i want to measure the fuel level of my fuel tank,and wanted to use the Capacitive Sensing Library , so i downloaded it from Arduino Playground - CapacitiveSensor
and as soon i start arduino,this error pops up..
The library CapacitiveSensor-b297f3f cannot be used.
Library names must contain only basic letters and numbers.
(ASCII only and no spaces, and it cannot start with a number).
Can anybody tell me what is happening here and how to troubleshoot it?
ok now..i have written my program, and i am posing it here,because its in reference to the capsense library.
After i press the compile button,it shows an error ,
capSense does not name a type?...i have included the library
#include<CapSense.h>
its saved as a .h file.
i tried changing the brackets to quotes but it didnt work out.
jay2012:
ok now..i have written my program, and i am posing it here,because its in reference to the capsense library.
After i press the compile button,it shows an error ,
capSense does not name a type?...i have included the library
#include<CapSense.h>
its saved as a .h file.
i tried changing the brackets to quotes but it didnt work out.
Using the IDE's sketch menu/import library see if the capsense library is listed in the Contributed section of the list offered. If it is not listed there you did not save the library in the proper directory and/or the proper manner.
ok,here is what i have written now, realizing my mistake with writing the library name,now after i compile it there is an error in the
long value = CS_4_2.CapacitiveSensor(30); line,saying that invalid use of class CapacitiveSensor
i am sorry but i am new to this library.
#include <CapacitiveSensor.h>
CapacitiveSensor CS_4_2 = CapacitiveSensor(4,2); // 10 megohm resistor between pins 4 & 2
void setup()
{
CS_4_2.set_CS_AutocaL_Millis(0xFFFFFFFF); // turn off autocalibrate on channel 1
Serial.begin(9600);
}
void loop()
{
long start = millis();
long value = CS_4_2.CapacitiveSensor(30);
Serial.println(value);
delay(100);
}
Hi there, I am having a similar problem. I have recently downloaded the capacitive sensing library from this link Arduino Playground - HomePage and paste this library in the libraries section in arduino. However when I start up arduino, the following error below pops out :
" The library "arduino-libraries -CapacitiveSensor-3e33f75" cannot be used.
Library names must contain only basic letters and numbers.
(ASCII only and no spaces, and it cannot start with a number)"
So, I have followed the instruction on this page by renaming the folder by removing the "-3e33f75" and still the same error pops out but this time saying " The library "arduino-libraries -CapacitiveSensor" cannot be used.
By the way i am using Arduino Uno and running it on Arduino Version 1.0.5
Is there any other ways to troubleshoot this problem? Your help would be kindly appreciated.
I fail to see what is so difficult to understand about the message. It says you can't use dashes in the name. It doesn't say that you can't use more than two. So, removing one was 1/3rd of what you needed to do.
Manage to get rid of the error by removing the dashes. However when i try to verify the program in the example that came with the library, the following error occur
CapacitiveSensor does not name a type
CapacitiveSensorSketch:12: error: 'CapacitiveSensor' does not name a type
CapacitiveSensorSketch.pde: In function 'void loop()':
CapacitiveSensorSketch:22: error: 'cs_4_2' was not declared in this scope
I have already checked the IDE sketch menu/import library and the capacitivesensor library is listed under the Contributed section so that means that i have save the library in the correct place but why does the error above occur?
CapacitiveSensor does not name a type
CapacitiveSensorSketch:12: error: 'CapacitiveSensor' does not name a type
CapacitiveSensorSketch.pde: In function 'void loop()':
CapacitiveSensorSketch:22: error: 'cs_4_2' was not declared in this scope
That's my issue and there is no solution if I well understand.