Please post your code. All of it. Read the forum guidelines to see how to properly post code and some good information on making a good post.
Use theIDE autoformat tool (ctrl-t or Tools, Auto format) before posting code in code tags.
Please include the entire error message. It is easy to do. There is a button (lower right of the IDE window) called "copy error message". Copy the error and paste into a post in code tags. Paraphrasing the error message leaves out important information.
fatal error: runtime: bsdthread_register error
runtime stack:
runtime.throw(0x18113e, 0x21)
/home/jenkins/go/src/runtime/panic.go:566 +0x95 fp=0x7ff7bfeff6d0 sp=0x7ff7bfeff6b0
runtime.goenvs()
/home/jenkins/go/src/runtime/os_darwin.go:88 +0xa0 fp=0x7ff7bfeff700 sp=0x7ff7bfeff6d0
runtime.schedinit()
/home/jenkins/go/src/runtime/proc.go:450 +0x9c fp=0x7ff7bfeff740 sp=0x7ff7bfeff700
runtime.rt0_go(0x7ff7bfeff770, 0x17, 0x7ff7bfeff770, 0x1000, 0x17, 0x7ff7bfeff948, 0x7ff7bfeff980, 0x7ff7bfeff98c, 0x7ff7bfeff99c, 0x7ff7bfeff9a6, ...)
/home/jenkins/go/src/runtime/asm_amd64.s:145 +0x14f fp=0x7ff7bfeff748 sp=0x7ff7bfeff740
/Applications/Arduino.app/Contents/Java/arduino-builder returned 2
Error compiling for board Arduino/Genuino Uno.
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
```Preformatted text
IDE 1.8.2
Code is blink sketch.```// the setup function runs once when you press reset or power the board
void setup() {
// initialize digital pin LED_BUILTIN as an output.
pinMode(LED_BUILTIN, OUTPUT);
}
// the loop function runs over and over again forever
void loop() {
digitalWrite(LED_BUILTIN, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(LED_BUILTIN, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
Sketch is the blink sketch
// the setup function runs once when you press reset or power the board
void setup() {
// initialize digital pin LED_BUILTIN as an output.
pinMode(LED_BUILTIN, OUTPUT);
}
// the loop function runs over and over again forever
void loop() {
digitalWrite(LED_BUILTIN, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(LED_BUILTIN, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
void setup() {
// initialize digital pin LED_BUILTIN as an output.
pinMode(LED_BUILTIN, OUTPUT);
}
// the loop function runs over and over again forever
void loop() {
digitalWrite(LED_BUILTIN, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(LED_BUILTIN, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
IED 1.8.2
fatal error: runtime: bsdthread_register error
runtime stack:
runtime.throw(0x18113e, 0x21)
/home/jenkins/go/src/runtime/panic.go:566 +0x95 fp=0x7ff7bfeff6c0 sp=0x7ff7bfeff6a0
runtime.goenvs()
/home/jenkins/go/src/runtime/os_darwin.go:88 +0xa0 fp=0x7ff7bfeff6f0 sp=0x7ff7bfeff6c0
runtime.schedinit()
/home/jenkins/go/src/runtime/proc.go:450 +0x9c fp=0x7ff7bfeff730 sp=0x7ff7bfeff6f0
runtime.rt0_go(0x7ff7bfeff768, 0x17, 0x7ff7bfeff768, 0x0, 0x1000, 0x17, 0x7ff7bfeff940, 0x7ff7bfeff978, 0x7ff7bfeff984, 0x7ff7bfeff994, ...)
/home/jenkins/go/src/runtime/asm_amd64.s:145 +0x14f fp=0x7ff7bfeff738 sp=0x7ff7bfeff730
/Applications/Arduino.app/Contents/Java/arduino-builder returned 2
Error compiling for board Arduino/Genuino Uno.
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
fatal error: runtime: bsdthread_register error
runtime stack:
runtime.throw(0x18113e, 0x21)
/home/jenkins/go/src/runtime/panic.go:566 +0x95 fp=0x7ff7bfeff6c0 sp=0x7ff7bfeff6a0
runtime.goenvs()
/home/jenkins/go/src/runtime/os_darwin.go:88 +0xa0 fp=0x7ff7bfeff6f0 sp=0x7ff7bfeff6c0
runtime.schedinit()
/home/jenkins/go/src/runtime/proc.go:450 +0x9c fp=0x7ff7bfeff730 sp=0x7ff7bfeff6f0
runtime.rt0_go(0x7ff7bfeff768, 0x17, 0x7ff7bfeff768, 0x0, 0x1000, 0x17, 0x7ff7bfeff940, 0x7ff7bfeff978, 0x7ff7bfeff984, 0x7ff7bfeff994, ...)
/home/jenkins/go/src/runtime/asm_amd64.s:145 +0x14f fp=0x7ff7bfeff738 sp=0x7ff7bfeff730
/Applications/Arduino.app/Contents/Java/arduino-builder returned 2
Error compiling for board Arduino/Genuino Uno.
This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.
Sketch is the blink sketch,
void setup() {
// initialize digital pin LED_BUILTIN as an output.
pinMode(LED_BUILTIN, OUTPUT);
}
// the loop function runs over and over again forever
void loop() {
digitalWrite(LED_BUILTIN, HIGH); // turn the LED on (HIGH is the voltage level)
delay(1000); // wait for a second
digitalWrite(LED_BUILTIN, LOW); // turn the LED off by making the voltage LOW
delay(1000); // wait for a second
}
I know absolutely zero about the Mac so my best suggestion is that I second the suggestion from @sterretje to Google "fatal error runtime bsdthread_register error arduino" to see what you can find out. Others have come up with the same error.
That error is from the IDE itself, and has NOTHING to do with the sketch code. There is a problem with the IDE installation. Best chance of fixing it is to uinstall the IDE, and re-install it from scratch with the latest version.