kidoman / embd

Embedded Programming Framework in Go
http://embd.kidoman.io
MIT License
1.28k stars 156 forks source link

fix a bug parsing version numbers with a hyphen at the end #7

Closed marcomonteiro closed 10 years ago

marcomonteiro commented 10 years ago

Using the latest Debian BBB image on beagleboard.org and noticed that the library failed to detect the proper version because running uname -r returns "3.8.13-bone47". This is a quick fix to pre-split the version string in order to separate that part out.

kidoman commented 10 years ago

Thanks for this. We need to fix the version detection anyway as it is currently reliant on the hostname (which is wrong on so many levels.)

marcomonteiro commented 10 years ago

Agree, but it seems like the least significant thing overall. I'm still having runtime errors pop up when trying to execute a simple light toggle looping app on the BBB. Not sure if it has something to do with the Debian image. I'm still a Go noob (3 days) so I'll have to dig into the debugging facilities. It's all just fun hacking for now so no big deal. Thanks again for getting this library together in the first place --- huge head start and should really help promote using Go on embedded platforms.

kidoman commented 10 years ago

Welcome :)

Also, I might be able to help, hit me with a gist!

marcomonteiro commented 10 years ago

https://gist.github.com/marcomonteiro/8b3ff6353b0ca51f8f11

kidoman commented 10 years ago

Hey, you have not loaded the drivers.... have a look at the README

marcomonteiro commented 10 years ago

I added that after the fact. The README could be a little more clear. Turns out I needed to re-pull the repo manually with the fix you merged (still learning Go's package management). So that solved the panic's but unfortunately the LED still isn't getting toggled. Not sure what it could be at this point. I'll give it another go this weekend and see if I can track down the issue.

kidoman commented 10 years ago

Awesome… would love to be off help! The sample:

https://github.com/kidoman/embd/blob/master/samples/universalblinker.go

should work out of the box on the BBB!

On 16-May-2014, at 4:04 pm, Marco Monteiro notifications@github.com wrote:

I added that after the fact. The README could be a little more clear. Turns out I needed to re-pull the repo manually with the fix you merged (still learning Go's package management). So that solved the panic's but unfortunately the LED still isn't getting toggled. Not sure what it could be at this point. I'll give it another go this weekend and see if I can track down the issue.

— Reply to this email directly or view it on GitHub.