Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

thread 'main' panicked #63

Open
ghost opened this issue Jun 24, 2018 · 1 comment
Open

thread 'main' panicked #63

ghost opened this issue Jun 24, 2018 · 1 comment

Comments

@ghost
Copy link

ghost commented Jun 24, 2018

Hi,
I'm very new to rust and am bamboozled by this and can't seem to find a solution looking at similar issues.

`
use std::io;
use std::ascii;
use std::time::Duration;
use std::time::Instant;
use std::thread::sleep;
extern crate tessel;
extern crate unix_socket;
extern crate libc;
use tessel::Tessel;
use tessel::Port;
use std::sync::{Arc, Mutex, MutexGuard};
use std::marker::PhantomData;
use std::sync::atomic::Ordering;
use protocol::{Command, reply, PortSocket};
use std::os::unix::net::UnixStream;

pub mod protocol;

fn main(){
    //Create new Tessel
    let mut tessel = Tessel::new();

    loop {
        println!("Step 1");

        sleep(Duration::from_millis(3000));

        println!("Step 2");
        //EnableSpi{ mode: 0x0a, freq: 0xE1, div: 0xE1 };
        sleep(Duration::from_millis(3000));

        println!("Step 3");
        //EnableSpi{ mode: 0x0c, freq: 0xE1, div: 0xE1 };
        sleep(Duration::from_millis(3000));

        println!("Step 4");
        //EnableSpi{ mode: 0x12, freq: 0xE1, div: 0xE1 };
        sleep(Duration::from_millis(3000));
    }
}`

To which gives the error:

thread 'main' panicked at 'called Result::unwrap() on an Err value: Os { code: 2, kind: NotFound, message: "No such file or directory" }', libcore/result.rs:945:5
note: Run with RUST_BACKTRACE=1 for a backtrace.

I'm trying to run the code just to print to see if everything is running before adding the code to accompany all the items in use.

@ghost
Copy link
Author

ghost commented Jul 20, 2018

Update-
Needed to run: rustup override set 1.12.0
And then: cargo tessel sdk install

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants