Go Down

Topic: Newb & lost. Macbook, Teensy 3.1, trying to program ATtiny85 (Read 120 times) previous topic - next topic

billyprefect

HELP.

I'm trying.  And failing all over.  For reasons I don't understand.
Errors pop up all over the place and I think I'm maybe missing something basic but I'm just not getting it.

I've got a Teensy 3.1 - OSHPark version as I had a PCB board series etched from them, seemed easy enough to just order the Teensy thinking I could use that to program the ATtiny 85's needed for the boards.

I was so very wrong.

Also, as stated, I am working from a MacBook. 
I have a Windows 7 64bit VM I can use, as well as just about any VM needed.

I get errors on .h files, errors on includes, warnings on return statements, warnings on not used returns.

I would really appreciate any help at all.

I've googled and youtubed senselessly, and I end up working in circles to get the exact same errors that I started out with.

To finalize this... I'm trying to build an under bed lighting as seen on instructables.

I'm trying to learn... seriously.

Coding Badly


Will need to know what sketch you are trying to compile.


billyprefect

I'm having errors just starting with Examples > ArduinoISP

I've loaded my Teensy board files properly, as the options are there for Teensy under boards.
I change #define RESET SS to #define RESET 10

And further down I change in start_mode() I move spi_init(); to below all the pinMode settings (according to many posts I've read).
The error list is awesome now:


Arduino: 1.6.1 (Mac OS X), TD: 1.21, Board: "Teensy 3.1, Serial, 72 MHz optimized, US English"

In file included from /Applications/Arduino.app/Contents/Java/hardware/teensy/avr/cores/teensy3/wiring.h:33:0,
                 from /Applications/Arduino.app/Contents/Java/hardware/teensy/avr/cores/teensy3/WProgram.h:15,
                 from /Applications/Arduino.app/Contents/Java/hardware/teensy/avr/cores/teensy3/Arduino.h:1,
                 from ArduinoISP.ino:66:
/Applications/Arduino.app/Contents/Java/hardware/teensy/avr/cores/teensy3/core_pins.h: In function 'void digitalWriteFast(uint8_t, uint8_t)':
/Applications/Arduino.app/Contents/Java/hardware/teensy/avr/cores/teensy3/core_pins.h:887:24: error: 'portSetRegister' was not declared in this scope
    *portSetRegister(pin) = digitalPinToBitMask(pin);
                        ^
/Applications/Arduino.app/Contents/Java/hardware/teensy/avr/cores/teensy3/core_pins.h:887:51: error: 'digitalPinToBitMask' was not declared in this scope
    *portSetRegister(pin) = digitalPinToBitMask(pin);
                                                   ^
/Applications/Arduino.app/Contents/Java/hardware/teensy/avr/cores/teensy3/core_pins.h:889:26: error: 'portClearRegister' was not declared in this scope
    *portClearRegister(pin) = digitalPinToBitMask(pin);
                          ^
/Applications/Arduino.app/Contents/Java/hardware/teensy/avr/cores/teensy3/core_pins.h:889:53: error: 'digitalPinToBitMask' was not declared in this scope
    *portClearRegister(pin) = digitalPinToBitMask(pin);
                                                     ^
/Applications/Arduino.app/Contents/Java/hardware/teensy/avr/cores/teensy3/core_pins.h: In function 'uint8_t digitalReadFast(uint8_t)':
/Applications/Arduino.app/Contents/Java/hardware/teensy/avr/cores/teensy3/core_pins.h:976:32: error: 'portInputRegister' was not declared in this scope
   return *portInputRegister(pin);
                                ^
ArduinoISP.ino: In function 'void universal()':
ArduinoISP.ino:280:7: warning: unused variable 'w' [-Wunused-variable]
ArduinoISP.ino: In function 'int avrisp()':
ArduinoISP.ino:552:1: warning: no return statement in function returning non-void [-Wreturn-type]
Error compiling.

  This report would have more information with
  "Show verbose output during compilation"
  enabled in File > Preferences.



If anyone could help removing some of the errors I'd much appreciate it.  This is after running Verify just now.  I have installed and uninstalled version of Arduino.  Knowing I needed Teensy as well as Attiny85 libraries, I started at 1.6.4, then down to 1.6.3 --- I've downloaded various versions of things and have lost track of just about the whole project.
I'm trying to learn... seriously.

billyprefect

To note: I just loaded Blink, edited it to define the LED pin instead of manually setting writing to pin 13, and this worked, so the libraries and connections are set OK. 
I'm trying to learn... seriously.

Coding Badly


Add...

#include <Arduino.h>

...to the top of the sketch...

Code: [Select]
#include <Arduino.h>   // <<<<<<<<<<

// ArduinoISP version 04m3
// Copyright (c) 2008-2011 Randall Bohn
// If you require a license, see

billyprefect

I just tried that, no difference on the output at all. 
Something must be deeply messed up.
I'm going to uninstall everything resembling arduino, with the teensy add on and the avr attiny add on, and am going to start over right from the beginning.
I'm trying to learn... seriously.

Coding Badly


billyprefect

I really want this process to work.  I have so many plans for things, besides the under bed lighting that is now completely frozen until I get my IDE software working again.  Not only can I NOT program any of the five ATtiny85's I've just received, I've reset the Teensy3.1 back to "blink" and its seem like I can't even program that using the arduino software anymore !! 
I'm resetting my whole MacBook.  I am backing up my pictures, music, documents, and am going to nuke my whole OS and restore it.  I don't know where things are messed up, but reseting the damn thing and starting over seems the full meal deal approach that really has to work.

I'm trying to learn... seriously.

Go Up
 


Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

Arduino
via Egeo 16
Torino, 10131
Italy