chore: move _embdemo to _demo
This commit is contained in:
16
_demo/embed/esp32/hello/main.go
Normal file
16
_demo/embed/esp32/hello/main.go
Normal file
@@ -0,0 +1,16 @@
|
||||
package main
|
||||
|
||||
import "github.com/goplus/lib/c"
|
||||
|
||||
func myprint(s *c.Char) {
|
||||
for i := 0; i < int(c.Strlen(s)); i++ {
|
||||
WriteByte(byte(c.Index(s, i)))
|
||||
}
|
||||
}
|
||||
|
||||
func main() {
|
||||
for {
|
||||
myprint(c.Str("hello world"))
|
||||
sleep(1)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user