OCCRA
Go to Post What makes a man is not the mistakes, but the actions that follow. Andy B. - Andy Baker [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
CD-Media  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 11-14-2018, 12:38 PM
Cappuccino Cappuccino is offline
Registered User
FRC #6902
 
Join Date: Nov 2018
Location: Brazil
Posts: 3
Cappuccino is an unknown quantity at this point
Question Eclipse Problem

Hello, we are from FRC Team #6902 and we´re having a problem with our code.
We've installed all the plugins that First tells you to so you can code with eclipse, but for some reason eclipse doesn't recognise terms from the wpilib. Whenever we try to send our code to the roboRio it suddently generates more errors. We've been attempting to download other plugins to fix it.
This is the code.

/----------------------------------------------------------------------------/
/* Copyright (c) 2017-2018 FIRST. All Rights Reserved. */
/* Open Source Software - may be modified and shared by FRC teams. The code */
/* must be accompanied by the FIRST BSD license file in the root directory of */
/* the project. */
/----------------------------------------------------------------------------/

#include <Drive/DifferentialDrive.h>
#include <IterativeRobot.h>
#include <Joystick.h>
#include <LiveWindow/LiveWindow.h>
#include <Spark.h>
#include <Timer.h>
#include <WPIlib.h>

class Robot : public frc::IterativeRobot {
frc::Spark M1{0};
frc::Spark M2{1};
frc::Spark M3{2};
frc::Spark M4{3};
frc:: DifferentialDrive Motor13 {M1,M3};
frc:: DifferentialDrive Motor24 {M2,M4};
frc::Joystick m_stick {0};

void TeleopInit() override {}

void TeleopPeriodic() override {
Motor13.ArcadeDrive(-m_stick.GetY(), -m_stick.GetX());
Motor24.ArcadeDrive(m_stick.GetY(), m_stick.GetX());
}

void TestPeriodic() override {}

};

START_ROBOT_CLASS(Robot)
Reply With Quote
  #2   Spotlight this post!  
Unread 11-14-2018, 03:54 PM
tekunalogy's Avatar
tekunalogy tekunalogy is offline
Registered User
FRC #3647
 
Join Date: Jul 2018
Location: California
Posts: 7
tekunalogy is an unknown quantity at this point
FIRST has shifted from eclipse to VSCode, so it might be due to that. Personally I would recommend switching unless you have a specific workflow that requires Eclipse. Sorry I can't help you answer your problem.

FRC Team 3647
Reply With Quote
  #3   Spotlight this post!  
Unread 11-21-2018, 02:09 PM
Cappuccino Cappuccino is offline
Registered User
FRC #6902
 
Join Date: Nov 2018
Location: Brazil
Posts: 3
Cappuccino is an unknown quantity at this point
Re: Eclipse Problem

Hi, and thanks for the tip!
But we tried using VScode and there is an error when including anything.
Apparently we should do something called includePath but after searching the matter we still dont know how to do so.

It seems like we should do something in c_cpp_properties.json:
{
"configurations": [
{
"name": "Win32",
"includePath": [
"${workspaceFolder}/**"
],
"defines": [
"_DEBUG",
"UNICODE",
"_UNICODE"
],
"windowsSdkVersion": "10.0.17134.0",
"compilerPath": "C:/Program Files/Microsoft Visual Studio/2017/Community/VC/Tools/MSVC/14.15.26726/bin/Hostx86/x86/cl.exe",
"cStandard": "c11",
"cppStandard": "c++17",
"intelliSenseMode": "msvc-x64",
"configurationProvider": "vscode-wpilib"
}
],
"version": 4
}

We`d be glad if you could help us here, VScode seems like a way better option than eclipse.
Thanks anyway.
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 11:58 PM.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin®
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi