I have spent 6 hours with the error: invalid cast from type 'string' to type 'int'. I am trying to convert a string to a long. Mycode: recordeddataR = long(values); I think I need to convert my values to a char string and use "atol" but I don't know how. I tried: recordeddataR = long(toCharArray(values,10)); That gave me: 'toCharArray' was not declared in this scope.
I wish strings in C were just another variable type like strings in Basic. I just want to get my robot working.
I would appreciate any help. Thanks.