This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "application.h" | |
| //#include "spark_disable_wlan.h" // For faster local debugging only | |
| #include "neopixel.h" | |
| // IMPORTANT: Set pixel COUNT, PIN and TYPE | |
| #define PIXEL_PIN D2 | |
| #define PIXEL_COUNT 2 | |
| #define PIXEL_TYPE WS2812B | |
| Adafruit_NeoPixel strip = Adafruit_NeoPixel(PIXEL_COUNT, PIXEL_PIN, PIXEL_TYPE); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //This code works. | |
| ofSerial serial; | |
| int sensorPadValue; | |
| void ofApp::setup(){ | |
| //this is the strange line. If I don't explicity call the ofSerial construtor all hell breaks loose. The error is Thread 1: EXC_BAD_ACCESS//(code=1, address 0xffffff4). | |
| serial = new ofSerial(); | |
| serial->listDevices(); | |
| serial->setup(0, 9600); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| This code will give you the bug: | |
| ofSerial serial | |
| void ofApp::setup(){ | |
| //this is the strange line. If I don't explicity call the ofSerial construtor all hell breaks loose. The error is Thread 1: EXC_BAD_ACCESS//(code=1, address 0xffffff4). | |
| serial.listDevices(); | |
| serial. setup(0, 9600); | |
| } | |
| void ofApp::update(){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import java.util.*; | |
| int x = 10; | |
| String s = "2"; | |
| x = Integer.parseInt(s); | |
| println(x); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import java.io.*; | |
| import java.util.Scanner; | |
| String[] stuff; | |
| //this array holds all data bouncing in - I used a file yours will be slightly different | |
| void setup(){ | |
| size(200,200); | |
| stuff = loadStrings("data.txt"); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Undefined symbols for architecture i386: | |
| "ofxAudioUnit::setRenderCallback(AURenderCallbackStruct, int)", referenced from: | |
| ofxAudioUnitDSPNode::connectTo(ofxAudioUnit&, int, int) in ofxAudioUnitDSPNode.o | |
| "ofxAudioUnit::ofxAudioUnit(ofxAudioUnit const&)", referenced from: | |
| std::vector<ofxAudioUnit, std::allocator<ofxAudioUnit> >::_M_fill_insert(__gnu_cxx::__normal_iterator<ofxAudioUnit*, std::vector<ofxAudioUnit, std::allocator<ofxAudioUnit> > >, unsigned long, ofxAudioUnit const&) in Hut.o | |
| void std::_Construct<ofxAudioUnit, ofxAudioUnit>(ofxAudioUnit*, ofxAudioUnit const&) in Hut.o | |
| "ofxAudioUnit::operator=(ofxAudioUnit const&)", referenced from: | |
| ofxAudioUnitFilePlayer::operator=(ofxAudioUnitFilePlayer const&) in Hut.o | |
| void std::__fill<false>::fill<ofxAudioUnit*, ofxAudioUnit>(ofxAudioUnit*, ofxAudioUnit*, ofxAudioUnit const&) in Hut.o | |
| ofxAudioUnit* std::__copy_backward<false, std::random_access_iterator_tag>::__copy_b<ofxAudioUnit*, ofxAudioUnit*>(ofxAudioUnit*, ofxAudi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| f you're vegetarian, don't stay here. They have no meal options that are not a salad and in fact, they'll refuse to let you eat if you do bring in food. We were waiting for our taxi in the lobby and told we had to throw away our to go sandwich and tea if we wanted to stay. That kind of behaviour, unless clearly disclosed, is really wrong when you are paying to stay in a hotel. We had to come across the street to a cafe to drink tea with soy milk. Also, the wifi is really poor in the rooms. I think this is to force you into the wifi where you have to buy food even if you're not in the hotel restaurant area because there's no place to sit otherwise. Normal lobby seats are included in the restaurant part even though they are not marked as such. There is no place to sit at all downstairs they will not bother you and let you work in peace. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /Applications/Processing 2.app/Contents/Resources/Java/modes/java/libraries/serial/library/macosx |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def powersOfTwo(x): | |
| #first check to see if x is a power of two | |
| # proceed to raise it | |
| if x >=512 | |
| break | |
| else | |
| #some logic | |
| print x |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def powersOfTwo(x): | |
| count = 1 #start at the first power of 2, 1 | |
| isAPowerOfTwo = False #have a nice little bool to see if we have a power of two for user output | |
| if(x == 1): #a little test to see if we're dealing with 1, which is a bit of a special case | |
| isAPowerOfTwo = True #filp the boolean so we know we have a power of two | |
| for i in range(9): # we need to go through this 8 times b/c 512 is the 8th bit shift 000000000 | |
| #0000000000 = 0 (first time) | |
| #0000000001 = 1 (time 1 through the loop) |